Make Electric Pair mode smarter/more useful:
* lisp/electric.el: Pairing/skipping helps preserve balance. Autobackspacing behaviour. Opens extra newlines between pairs. Skip whitespace before closing delimiters. * lisp/emacs-lisp/lisp-mode.el (lisp-mode-variables): Use new features. * test/automated/electric-tests.lisp: New file. * doc/emacs/programs.texi: Describe new features. * lisp/simple.el: Pass non-nil interactive arg to newline call inside newline-and-indent.
This commit is contained in:
parent
fbcc63a317
commit
3b8d5131a3
10 changed files with 1126 additions and 97 deletions
|
@ -472,7 +472,13 @@ font-lock keywords will not be case sensitive."
|
|||
(font-lock-mark-block-function . mark-defun)
|
||||
(font-lock-syntactic-face-function
|
||||
. lisp-font-lock-syntactic-face-function)))
|
||||
(setq-local prettify-symbols-alist lisp--prettify-symbols-alist))
|
||||
(setq-local prettify-symbols-alist lisp--prettify-symbols-alist)
|
||||
;; electric
|
||||
(when elisp
|
||||
(setq-local electric-pair-text-pairs
|
||||
(cons '(?\` . ?\') electric-pair-text-pairs)))
|
||||
(setq-local electric-pair-skip-whitespace 'chomp)
|
||||
(setq-local electric-pair-open-newline-between-pairs nil))
|
||||
|
||||
(defun lisp-outline-level ()
|
||||
"Lisp mode `outline-level' function."
|
||||
|
|
Loading…
Add table
Add a link
Reference in a new issue