xtodo emacs tutorial site
lexical-binding, lexical scope vs dynamic scope
- add a emacs tutorial
;; dynamic scope (setq yy 'xx) (let (xx) (setq xx 3) (print (format "%s" yy))) ;; xx ;; dynamic scope (setq yy 'xx) (let (xx) (setq xx 3) (print (format "%s" (eval yy)))) "3"
;; -*- lexical-binding: t; -*- ;; lexical scope (setq yy 'xx) (let (xx) (setq xx 3) (print (format "%s" yy))) ;; xx ;; HHHH------------------------------ ;; lexical scope (setq yy 'xx) (let (xx) (setq xx 3) (print (format "%s" (eval yy)))) ;; Debugger entered--Lisp error: (void-variable xx)
- finish adding a tutorial for map- functions
- emacs lisp add
flatten-tree
to tutorial - add
mapcan
to tutorial
- 2023-09-01
- write about
identity
ignore
always
- Elisp: Apply Function (List to Args)
- Calling Functions (ELISP Manual)
put to tutorial
(defun xah-random-int (Min Max) "version 2022-08-26" (+ Min (random (- (1+ Max) Min))))
merge Emacs Lisp Examples to Xah Emacs Commands
looking-back
is slow.
here's a typical usage:
(looking-back "[ \t\n]" (1- (point)) )
you can change it to:
;; warning. error if at point min (prog2 (backward-char) (looking-at "[ \t\n]") (forward-char))
- need add reason
- Emacs, Why You Should Not Use the Package Dash (2020)
things in Emacs 28 (date 2022) and Emacs 29 (date 2023) that i suggested to change some 10 plus years ago.
- consistent key notation of e.g. change
<C-f11>
toC-<f11>
- use intuitive key notation when binding keys. that is, always use
the syntax used by
kbd
. In emacs 29, a whole set of functions starting withkeymap-
do this.

describe-mode
not show minor modes at top- help mode show consistant key notation
- adding a link to the manual in the output of
describe-function
(in emacs 29, you can press i)
review
- 2021-10-27 review Emacs calc sucks
- 2022-01-18 review Emacs Flaw: Problems of grep
- 2021-08-09 review Emacs: Uncolor Region/Buffer
- 2021-02-19 review vim, 3 Decades Pile of History
- review Emacs 27.1 Features (released 2020-08)
- 2022-12-11 Emacs: Master Tips
- 2022-12-11 Elisp: Find String Inside HTML Tag
- 2021-05-16 need review. Emacs: Indentation Commands
- 2021-08-20 orphan Elisp: String Match in List 📜
- 2021-08-20 Emacs Lisp Misc
- 2021-08-20 Elisp Misc Technical Essays
- old review Emacs HTML history
- Emacs: Why You Should Not Swap CapsLock and Control
- Vim: Remap Escape Key
- Emacs: Why I Don't Use paredit
- Emacs Flaw: AutoHotkey Mode
- Emacs Flaw: Meta Key Notation
- Emacs Flaw: Simple Changes Emacs Should Adopt
- Lisp-1 vs Lisp-2 (single-value-space vs multi-value-space)
- Emergency vim
- Emacs: Turn Off Backup
- Emacs: Reformat Lines for Source Code
- Emacs: Auto Save
(let ((current-time-list t)) (current-time)) ;; (26617 34607 948241 0) (let ((current-time-list nil)) (current-time)) ;; (1744406324012224000 . 1000000000) (current-time-string) ;; "Fri Apr 11 14:14:42 2025"
- emacs. review
- Emacs: Graphical Menu
- Emacs: Terminal vs Graphical User Interface
- Emacs: Key Macro Example: Insert All Unicode Bullets
- Why Emacs is Still so Useful Today
- vim, 3 Decades Pile of History
- The Sigil War, Syntactic Indicator for Types of Function and Variable (2016)
- Language Server Protocol (LSP) Kills Emacs
- Xah Emacs Blog Archive 2012-04
- Xah Emacs Blog Archive 2012-11
- Xah Emacs Blog Archive 2014-09
- Xah Emacs Blog Archive 2017-04
- Xah Emacs Blog Archive 2018-02
- Xah Emacs Blog Archive 2018-08
- Xah Emacs Blog Archive 2018-11
- Xah Emacs Blog Archive 2019-05
- Xah Emacs Blog Archive 2021-01
- Emacs: Master Tips
- Elisp: Batch Find Replace