mirror of
git://git.sv.gnu.org/emacs.git
synced 2026-02-04 22:50:59 -08:00
Some global minor modes require initialization. Those that are preloaded currently abuse `custom-initialize-delay` for that, but it's suboptimal and doesn't help those that aren't preloaded. So introduce a new function to fill that need. While at it, make `define-globalized-minor-mode` use it automatically when useful. * lisp/custom.el (custom-initialize-after-file-load): New function. * lisp/tooltip.el (tooltip-mode): * lisp/paren.el (show-paren-mode): * lisp/rfn-eshadow.el (file-name-shadow-mode): * lisp/epa-hook.el (auto-encryption-mode): * lisp/minibuffer.el (minibuffer-regexp-mode, minibuffer-nonselected-mode): * lisp/electric.el (electric-indent-mode): Use it instead of `custom-initialize-delay` since the value does not depend on the runtime context. (electric-quote-mode): Don't use `custom-initialize-delay` since the default value is nil anyway. * lisp/emacs-lisp/easy-mmode.el (define-globalized-minor-mode): Automatically add `:initialize` if needed. * lisp/emacs-lisp/eldoc.el (global-eldoc-mode): Remove `:initialize`, now provided automatically. * doc/lispref/customize.texi (Variable Definitions): * doc/lispref/modes.texi (Defining Minor Modes): Document and Suggest `custom-initialize-after-file-load` instead of `custom-initialize-delay`. |
||
|---|---|---|
| .. | ||
| emacs | ||
| lispintro | ||
| lispref | ||
| man | ||
| misc | ||
| translations | ||