commit 296ef2e99b7cd83ad236230ddc941c7dbc8766e6 (HEAD, refs/remotes/origin/master) Author: Daniel Mendler Date: Mon Apr 19 22:13:55 2021 +0200 (completion-all-sorted-completions): Additional alphabetical sorting Even in the cases where it does not make much visible difference, it brings the benefit of making the result deterministic. * minibuffer.el (minibuffer--sort-by-length-alpha): New function. (minibuffer--sort-by-position): New function extracted from `completion-all-sorted-completions`. (completion-all-sorted-completions): Use use them. diff --git a/lisp/minibuffer.el b/lisp/minibuffer.el index c19f909629..4ed596430c 100644 --- a/lisp/minibuffer.el +++ b/lisp/minibuffer.el @@ -1362,6 +1362,25 @@ KEYFUN takes an element of ELEMS and should return a numerical value." (sort (mapcar (lambda (x) (cons (funcall keyfun x) x)) elems) #'car-less-than-car))) +(defun minibuffer--sort-by-position (hist elems) + "Sort ELEMS by their position in HIST." + (let ((hash (make-hash-table :test #'equal :size (length hist))) + (index 0)) + ;; Record positions in hash + (dolist (c hist) + (unless (gethash c hash) + (puthash c index hash)) + (cl-incf index)) + (minibuffer--sort-by-key + elems (lambda (x) (gethash x hash most-positive-fixnum))))) + +(defun minibuffer--sort-by-length-alpha (elems) + "Sort ELEMS first by length, then alphabetically." + (sort elems (lambda (c1 c2) + (or (< (length c1) (length c2)) + (and (= (length c1) (length c2)) + (string< c1 c2)))))) + (defun completion-all-sorted-completions (&optional start end) (or completion-all-sorted-completions (let* ((start (or start (minibuffer-prompt-end))) @@ -1395,25 +1414,17 @@ KEYFUN takes an element of ELEMS and should return a numerical value." (sort-fun (setq all (funcall sort-fun all))) (t - ;; Prefer shorter completions, by default. - (setq all (sort all (lambda (c1 c2) (< (length c1) (length c2))))) - (if (and (minibufferp) (not (eq minibuffer-history-variable t))) - ;; Prefer recently used completions and put the default, if - ;; it exists, on top. - (let* ((hist (symbol-value minibuffer-history-variable)) - (hash (make-hash-table :test #'equal :size (length hist))) - (index 0) - (def (car-safe minibuffer-default))) - ;; Record history positions in hash - (dolist (c hist) - (unless (gethash c hash) - (puthash c index hash)) - (cl-incf index)) - (when (stringp def) - (puthash def -1 hash)) - (setq all (minibuffer--sort-by-key - all (lambda (x) - (gethash x hash most-positive-fixnum)))))))) + ;; Sort first by length and alphabetically. + (setq all (minibuffer--sort-by-length-alpha all)) + + ;; Sort by history position, put the default, if it + ;; exists, on top. + (when (and (minibufferp) (not (eq minibuffer-history-variable t))) + (let ((def (car-safe minibuffer-default)) + (hist (symbol-value minibuffer-history-variable))) + (setq all (minibuffer--sort-by-position + (if def (cons def hist) hist) + all)))))) ;; Cache the result. This is not just for speed, but also so that ;; repeated calls to minibuffer-force-complete can cycle through commit 9216e1818a6f8dd33f98d435fc4927f6dd361d5c Author: Daniel Mendler Date: Mon Apr 19 15:40:00 2021 +0200 minibuffer.el: Use completion--message instead of minibuffer-message * minibuffer.el: Use completion--message consistently for the messages "Incomplete", "Sole completion" and "No completions". diff --git a/lisp/minibuffer.el b/lisp/minibuffer.el index 4a414aef4e..c19f909629 100644 --- a/lisp/minibuffer.el +++ b/lisp/minibuffer.el @@ -1437,7 +1437,7 @@ KEYFUN takes an element of ELEMS and should return a numerical value." ;; test-completion, then we shouldn't exit, but that should be rare. (lambda () (if minibuffer--require-match - (minibuffer-message "Incomplete") + (completion--message "Incomplete") ;; If a match is not required, exit after all. (exit-minibuffer))))) @@ -2022,7 +2022,7 @@ variables.") ;; the sole completion, then hide (previous&stale) completions. (minibuffer-hide-completions) (ding) - (minibuffer-message + (completion--message (if completions "Sole completion" "No completions"))) (let* ((last (last completions)) commit 27af0a3dc8b6b45879904bbc5d54b0677f84a5ff Author: Philipp Stephani Date: Mon Apr 19 21:10:20 2021 +0200 Seccomp filter: deal with arch_prctl(ARCH_CET_STATUS, ...). The dynamic loader of GNU libc 2.28 uses this system call to initialize CPU information, see https://sourceware.org/git/?p=glibc.git;a=blob;f=sysdeps/unix/sysv/linux/x86/cpu-features.c;hb=glibc-2.28#l28. Simulating an older kernel by returning EINVAL should be the most harmless rule here. The ARCH_CET_STATUS symbol isn't yet exposed by the kernel headers; see the FIXME at the top of https://sourceware.org/git/?p=glibc.git;a=blob;f=sysdeps/unix/sysv/linux/x86/include/asm/prctl.h;hb=glibc-2.28. * lib-src/seccomp-filter.c (ARCH_CET_STATUS): Define if not already present. Inline the value because there doesn't seem to be a header file exporting this constant yet. (main): Make ARCH_CET_STATUS subfunction of arch_prctl return EINVAL. diff --git a/lib-src/seccomp-filter.c b/lib-src/seccomp-filter.c index 8f8a990661..31d0809f8f 100644 --- a/lib-src/seccomp-filter.c +++ b/lib-src/seccomp-filter.c @@ -60,6 +60,10 @@ variants of those files that can be used to sandbox Emacs before #include "verify.h" +#ifndef ARCH_CET_STATUS +#define ARCH_CET_STATUS 0x3001 +#endif + static ATTRIBUTE_FORMAT_PRINTF (2, 3) _Noreturn void fail (int error, const char *format, ...) { @@ -345,6 +349,8 @@ main (int argc, char **argv) RULE (SCMP_ACT_ALLOW, SCMP_SYS (set_tid_address)); RULE (SCMP_ACT_ALLOW, SCMP_SYS (arch_prctl), SCMP_A0_32 (SCMP_CMP_EQ, ARCH_SET_FS)); + RULE (SCMP_ACT_ERRNO (EINVAL), SCMP_SYS (arch_prctl), + SCMP_A0_32 (SCMP_CMP_EQ, ARCH_CET_STATUS)); RULE (SCMP_ACT_ALLOW, SCMP_SYS (statfs)); /* We want to allow starting the Emacs binary itself with the commit ab287a148fc274d79fb13004aa7ab76fe1058450 Author: Stefan Monnier Date: Mon Apr 19 15:10:05 2021 -0400 * lisp/minibuffer.el (completion-all-sorted-completions): Fix last change diff --git a/lisp/minibuffer.el b/lisp/minibuffer.el index b98bc6a2b6..4a414aef4e 100644 --- a/lisp/minibuffer.el +++ b/lisp/minibuffer.el @@ -1411,8 +1411,9 @@ KEYFUN takes an element of ELEMS and should return a numerical value." (cl-incf index)) (when (stringp def) (puthash def -1 hash)) - (minibuffer--sort-by-key - all (lambda (x) (gethash x hash most-positive-fixnum))))))) + (setq all (minibuffer--sort-by-key + all (lambda (x) + (gethash x hash most-positive-fixnum)))))))) ;; Cache the result. This is not just for speed, but also so that ;; repeated calls to minibuffer-force-complete can cycle through commit 14633fbc097f61ebf548d5304e51031196304e4f Author: Stefan Monnier Date: Mon Apr 19 14:57:41 2021 -0400 * lisp/minibuffer.el (minibuffer--sort-by-key): New function (completion-all-sorted-completions): Use it. diff --git a/lisp/minibuffer.el b/lisp/minibuffer.el index dde700fcf6..b98bc6a2b6 100644 --- a/lisp/minibuffer.el +++ b/lisp/minibuffer.el @@ -1355,6 +1355,13 @@ scroll the window of possible completions." (if (eq (car bounds) base) md-at-point (completion-metadata (substring string 0 base) table pred)))) +(defun minibuffer--sort-by-key (elems keyfun) + "Return ELEMS sorted by increasing value of their KEYFUN. +KEYFUN takes an element of ELEMS and should return a numerical value." + (mapcar #'cdr + (sort (mapcar (lambda (x) (cons (funcall keyfun x) x)) elems) + #'car-less-than-car))) + (defun completion-all-sorted-completions (&optional start end) (or completion-all-sorted-completions (let* ((start (or start (minibuffer-prompt-end))) @@ -1404,19 +1411,8 @@ scroll the window of possible completions." (cl-incf index)) (when (stringp def) (puthash def -1 hash)) - ;; Decorate elements with history position - (let ((c all)) - (while c - (setcar c (cons (gethash (car c) hash - most-positive-fixnum) - (car c))) - (pop c))) - (setq all (sort all #'car-less-than-car)) - ;; Drop decoration from the elements - (let ((c all)) - (while c - (setcar c (cdar c)) - (pop c))))))) + (minibuffer--sort-by-key + all (lambda (x) (gethash x hash most-positive-fixnum))))))) ;; Cache the result. This is not just for speed, but also so that ;; repeated calls to minibuffer-force-complete can cycle through commit 18d0ef9d597c1a78a0063b5c04642bf4c448dd19 Author: Daniel Mendler Date: Mon Apr 19 08:43:41 2021 +0200 completion-all-sorted-completions: Fix sorting performance bug * lisp/minibuffer.el (completion-all-sorted-completions): Use hash table for sorting by history position, O(m+n*log(n)) instead of O(m*n*log(n)) with history length `m` and candidate length `n`. diff --git a/lisp/minibuffer.el b/lisp/minibuffer.el index 06a5e1e988..dde700fcf6 100644 --- a/lisp/minibuffer.el +++ b/lisp/minibuffer.el @@ -1393,14 +1393,31 @@ scroll the window of possible completions." (if (and (minibufferp) (not (eq minibuffer-history-variable t))) ;; Prefer recently used completions and put the default, if ;; it exists, on top. - (let ((hist (symbol-value minibuffer-history-variable))) - (setq all - (sort all - (lambda (c1 c2) - (cond ((equal c1 minibuffer-default) t) - ((equal c2 minibuffer-default) nil) - (t (> (length (member c1 hist)) - (length (member c2 hist)))))))))))) + (let* ((hist (symbol-value minibuffer-history-variable)) + (hash (make-hash-table :test #'equal :size (length hist))) + (index 0) + (def (car-safe minibuffer-default))) + ;; Record history positions in hash + (dolist (c hist) + (unless (gethash c hash) + (puthash c index hash)) + (cl-incf index)) + (when (stringp def) + (puthash def -1 hash)) + ;; Decorate elements with history position + (let ((c all)) + (while c + (setcar c (cons (gethash (car c) hash + most-positive-fixnum) + (car c))) + (pop c))) + (setq all (sort all #'car-less-than-car)) + ;; Drop decoration from the elements + (let ((c all)) + (while c + (setcar c (cdar c)) + (pop c))))))) + ;; Cache the result. This is not just for speed, but also so that ;; repeated calls to minibuffer-force-complete can cycle through ;; all possibilities. commit 077dae3b4ca6a534a0c8061f7b5cf81639e39c3b Author: Daniel Mendler Date: Mon Apr 19 08:20:50 2021 +0200 completing-read: If HIST is the symbol `t', history is not recorded. * lisp/minibuffer.el (completion-all-sorted-completions): Check if `minibuffer-history-variable` is `t` * src/minibuf.c (completing-read): Update docstring * doc/lispref/minibuf.texi: Update documentation of `read-from-minibuffer` and `completing-read` diff --git a/doc/lispref/minibuf.texi b/doc/lispref/minibuf.texi index d16409d6c8..e922f1836b 100644 --- a/doc/lispref/minibuf.texi +++ b/doc/lispref/minibuf.texi @@ -167,8 +167,10 @@ various applications such as completion. The argument @var{history} specifies a history list variable to use for saving the input and for history commands used in the minibuffer. -It defaults to @code{minibuffer-history}. You can optionally specify -a starting position in the history list as well. @xref{Minibuffer History}. +It defaults to @code{minibuffer-history}. If @var{history} is the +symbol @code{t}, history is not recorded. You can optionally specify +a starting position in the history list as well. @xref{Minibuffer +History}. If the variable @code{minibuffer-allow-text-properties} is non-@code{nil}, then the string that is returned includes whatever text @@ -1107,9 +1109,10 @@ The function @code{completing-read} uses @code{minibuffer-local-must-match-map} if @var{require-match} is non-@code{nil}. @xref{Completion Commands}. -The argument @var{history} specifies which history list variable to use for -saving the input and for minibuffer history commands. It defaults to -@code{minibuffer-history}. @xref{Minibuffer History}. +The argument @var{history} specifies which history list variable to +use for saving the input and for minibuffer history commands. It +defaults to @code{minibuffer-history}. If @var{history} is the symbol +@code{t}, history is not recorded. @xref{Minibuffer History}. The argument @var{initial} is mostly deprecated; we recommend using a non-@code{nil} value only in conjunction with specifying a cons cell diff --git a/lisp/minibuffer.el b/lisp/minibuffer.el index c900b0d7ce..06a5e1e988 100644 --- a/lisp/minibuffer.el +++ b/lisp/minibuffer.el @@ -1390,7 +1390,7 @@ scroll the window of possible completions." (t ;; Prefer shorter completions, by default. (setq all (sort all (lambda (c1 c2) (< (length c1) (length c2))))) - (if (minibufferp) + (if (and (minibufferp) (not (eq minibuffer-history-variable t))) ;; Prefer recently used completions and put the default, if ;; it exists, on top. (let ((hist (symbol-value minibuffer-history-variable))) diff --git a/src/minibuf.c b/src/minibuf.c index a3c1b99bf3..f025817276 100644 --- a/src/minibuf.c +++ b/src/minibuf.c @@ -2023,7 +2023,8 @@ HIST, if non-nil, specifies a history list and optionally the initial (This is the only case in which you should use INITIAL-INPUT instead of DEF.) Positions are counted starting from 1 at the beginning of the list. The variable `history-length' controls the maximum length - of a history list. + of a history list. If HIST is the symbol `t', history is not + recorded. DEF, if non-nil, is the default value or the list of default values. commit 0a4dc70830f5e8286b47120cabc750cca07a75c1 Author: Stefan Kangas Date: Mon Apr 19 12:21:01 2021 +0200 ; Normalize and add missing first and last lines diff --git a/admin/charsets/eucjp-ms.awk b/admin/charsets/eucjp-ms.awk index ca9a317611..033b37f5ed 100644 --- a/admin/charsets/eucjp-ms.awk +++ b/admin/charsets/eucjp-ms.awk @@ -38,7 +38,7 @@ BEGIN { JISX0208_FROM2 = "/xf5/xa1"; JISX0212_FROM = "/x8f/xf3/xf3"; - print ";;; eucjp-ms.el -- translation table for eucJP-ms -*- lexical-binding:t -*-"; + print ";;; eucjp-ms.el --- translation table for eucJP-ms -*- lexical-binding:t -*-"; print ";;; Automatically generated from /usr/share/i18n/charmaps/EUC-JP-MS.gz"; print "(let ((map"; print " '(;JISEXT<->UNICODE"; diff --git a/admin/charsets/mule-charsets.el b/admin/charsets/mule-charsets.el index 99a8c60d88..7bcceb39b2 100644 --- a/admin/charsets/mule-charsets.el +++ b/admin/charsets/mule-charsets.el @@ -1,4 +1,4 @@ -;; mule-charsets.el -- Generate Mule-original charset maps. -*- lexical-binding: t -*- +;;; mule-charsets.el --- Generate Mule-original charset maps. -*- lexical-binding: t -*- ;; Copyright (C) 2003, 2004, 2005, 2006, 2007, 2008, 2009, 2010, 2011 ;; National Institute of Advanced Industrial Science and Technology (AIST) ;; Registration Number H13PRO009 diff --git a/admin/unidata/unidata-gen.el b/admin/unidata/unidata-gen.el index 221c9b104e..abd41e34a4 100644 --- a/admin/unidata/unidata-gen.el +++ b/admin/unidata/unidata-gen.el @@ -1,4 +1,4 @@ -;; unidata-gen.el -- Create files containing character property data -*- lexical-binding:t -*- +;;; unidata-gen.el --- Create files containing character property data -*- lexical-binding:t -*- ;; Copyright (C) 2008-2021 Free Software Foundation, Inc. @@ -1446,7 +1446,7 @@ Property value is a symbol `o' (Open), `c' (Close), or `n' (None)." ";; no-byte-compile: t\n" ";; no-update-autoloads: t\n" ";; End:\n\n" - (format ";; %s ends here\n" basename))))) + (format ";;; %s ends here\n" basename))))) (or noninteractive (message "Generating %s...done" file))) (defun unidata-gen-charprop (&optional charprop-file) @@ -1470,7 +1470,7 @@ Property value is a symbol `o' (Open), `c' (Close), or `n' (None)." ";; no-byte-compile: t\n" ";; no-update-autoloads: t\n" ";; End:\n\n" - (format ";; %s ends here\n" + (format ";;; %s ends here\n" (file-name-nondirectory charprop-file))))) diff --git a/etc/themes/manoj-dark-theme.el b/etc/themes/manoj-dark-theme.el index 1f4891c316..5a527111d3 100644 --- a/etc/themes/manoj-dark-theme.el +++ b/etc/themes/manoj-dark-theme.el @@ -1,4 +1,4 @@ -;;; manoj-dark.el --- A dark theme from Manoj -*- lexical-binding:t -*- +;;; manoj-dark-theme.el --- A dark theme from Manoj -*- lexical-binding:t -*- ;; Copyright (C) 2011-2021 Free Software Foundation, Inc. diff --git a/leim/leim-ext.el b/leim/leim-ext.el index 687379db9f..904675c0c5 100644 --- a/leim/leim-ext.el +++ b/leim/leim-ext.el @@ -1,4 +1,4 @@ -;; leim-ext.el -- extra leim configuration -*- lexical-binding: t; -*- +;;; leim-ext.el --- extra leim configuration -*- lexical-binding: t; -*- ;; Copyright (C) 2004-2021 Free Software Foundation, Inc. ;; Copyright (C) 2004, 2005, 2006, 2007, 2008, 2009, 2010, 2011 diff --git a/lisp/allout-widgets.el b/lisp/allout-widgets.el index 90f3f61b36..0e12704088 100644 --- a/lisp/allout-widgets.el +++ b/lisp/allout-widgets.el @@ -1,4 +1,4 @@ -;; allout-widgets.el --- Visually highlight allout outline structure. -*- lexical-binding: t; -*- +;;; allout-widgets.el --- Visually highlight allout outline structure. -*- lexical-binding: t; -*- ;; Copyright (C) 2005-2021 Free Software Foundation, Inc. @@ -2296,3 +2296,5 @@ The elements of LIST are not copied, just the list structure itself." ;;;_ , Local variables: ;;;_ , allout-layout: (-1 : 0) ;;;_ , End: + +;;; allout-widgets.el ends here diff --git a/lisp/calc/calc-menu.el b/lisp/calc/calc-menu.el index ac14e36c63..516f62d7b6 100644 --- a/lisp/calc/calc-menu.el +++ b/lisp/calc/calc-menu.el @@ -1669,3 +1669,5 @@ ["Quit" calc-quit])) (provide 'calc-menu) + +;;; calc-menu.el ends here diff --git a/lisp/calc/calc-nlfit.el b/lisp/calc/calc-nlfit.el index 11867f15e5..f676b098e5 100644 --- a/lisp/calc/calc-nlfit.el +++ b/lisp/calc/calc-nlfit.el @@ -819,3 +819,5 @@ (calc-record traillist "parm"))))) (provide 'calc-nlfit) + +;;; calc-nlfit.el ends here diff --git a/lisp/cus-theme.el b/lisp/cus-theme.el index a702fedd24..13fb9f34fa 100644 --- a/lisp/cus-theme.el +++ b/lisp/cus-theme.el @@ -1,7 +1,7 @@ -;;; cus-theme.el -- custom theme creation user interface -*- lexical-binding: t -*- -;; +;;; cus-theme.el --- custom theme creation user interface -*- lexical-binding: t -*- + ;; Copyright (C) 2001-2021 Free Software Foundation, Inc. -;; + ;; Author: Alex Schroeder ;; Maintainer: emacs-devel@gnu.org ;; Keywords: help, faces diff --git a/lisp/dframe.el b/lisp/dframe.el index f4208f3755..1ddf11a8aa 100644 --- a/lisp/dframe.el +++ b/lisp/dframe.el @@ -1,4 +1,4 @@ -;;; dframe --- dedicate frame support modes -*- lexical-binding:t -*- +;;; dframe.el --- dedicate frame support modes -*- lexical-binding:t -*- ;; Copyright (C) 1996-2021 Free Software Foundation, Inc. diff --git a/lisp/dos-w32.el b/lisp/dos-w32.el index cf75321462..45daaad8ef 100644 --- a/lisp/dos-w32.el +++ b/lisp/dos-w32.el @@ -1,4 +1,4 @@ -;; dos-w32.el --- Functions shared among MS-DOS and W32 (NT/95) platforms -*- lexical-binding: t; -*- +;;; dos-w32.el --- Functions shared among MS-DOS and W32 (NT/95) platforms -*- lexical-binding: t; -*- ;; Copyright (C) 1996, 2001-2021 Free Software Foundation, Inc. diff --git a/lisp/emacs-lisp/check-declare.el b/lisp/emacs-lisp/check-declare.el index 7c2b23b4ec..bec4ad9250 100644 --- a/lisp/emacs-lisp/check-declare.el +++ b/lisp/emacs-lisp/check-declare.el @@ -328,4 +328,4 @@ Returns non-nil if any false statements are found." (provide 'check-declare) -;;; check-declare.el ends here. +;;; check-declare.el ends here diff --git a/lisp/emacs-lisp/eieio-custom.el b/lisp/emacs-lisp/eieio-custom.el index 184b99fdac..8257f7a4ba 100644 --- a/lisp/emacs-lisp/eieio-custom.el +++ b/lisp/emacs-lisp/eieio-custom.el @@ -1,4 +1,4 @@ -;;; eieio-custom.el -- eieio object customization -*- lexical-binding:t -*- +;;; eieio-custom.el --- eieio object customization -*- lexical-binding:t -*- ;; Copyright (C) 1999-2001, 2005, 2007-2021 Free Software Foundation, ;; Inc. diff --git a/lisp/emacs-lisp/eieio-opt.el b/lisp/emacs-lisp/eieio-opt.el index e65f424cba..08a6debc20 100644 --- a/lisp/emacs-lisp/eieio-opt.el +++ b/lisp/emacs-lisp/eieio-opt.el @@ -1,4 +1,4 @@ -;;; eieio-opt.el -- eieio optional functions (debug, printing, speedbar) -*- lexical-binding: t; -*- +;;; eieio-opt.el --- eieio optional functions (debug, printing, speedbar) -*- lexical-binding: t; -*- ;; Copyright (C) 1996, 1998-2003, 2005, 2008-2021 Free Software ;; Foundation, Inc. diff --git a/lisp/emacs-lisp/eieio-speedbar.el b/lisp/emacs-lisp/eieio-speedbar.el index 8bf77e20df..c25ea8acee 100644 --- a/lisp/emacs-lisp/eieio-speedbar.el +++ b/lisp/emacs-lisp/eieio-speedbar.el @@ -1,4 +1,4 @@ -;;; eieio-speedbar.el -- Classes for managing speedbar displays. -*- lexical-binding:t -*- +;;; eieio-speedbar.el --- Classes for managing speedbar displays. -*- lexical-binding:t -*- ;; Copyright (C) 1999-2002, 2005, 2007-2021 Free Software Foundation, ;; Inc. diff --git a/lisp/emacs-lisp/eieio.el b/lisp/emacs-lisp/eieio.el index 910023b841..31b6b0945b 100644 --- a/lisp/emacs-lisp/eieio.el +++ b/lisp/emacs-lisp/eieio.el @@ -981,4 +981,4 @@ of `eq'." (provide 'eieio) -;;; eieio ends here +;;; eieio.el ends here diff --git a/lisp/emacs-lisp/tcover-ses.el b/lisp/emacs-lisp/tcover-ses.el index d9db1d3cdc..4460fef97b 100644 --- a/lisp/emacs-lisp/tcover-ses.el +++ b/lisp/emacs-lisp/tcover-ses.el @@ -1,4 +1,4 @@ -;;;; testcover-ses.el -- Example use of `testcover' to test "SES" -*- lexical-binding: t; -*- +;;; tcover-ses.el --- Example use of `testcover' to test "SES" -*- lexical-binding: t; -*- ;; Copyright (C) 2002-2021 Free Software Foundation, Inc. @@ -716,4 +716,4 @@ spreadsheet files with invalid formatting." ;;Could do this here: (testcover-end "ses.el") (message "Done")) -;;; testcover-ses.el ends here. +;;; tcover-ses.el ends here diff --git a/lisp/emacs-lisp/testcover.el b/lisp/emacs-lisp/testcover.el index 75b27d08e5..e75f15140a 100644 --- a/lisp/emacs-lisp/testcover.el +++ b/lisp/emacs-lisp/testcover.el @@ -1,4 +1,4 @@ -;;;; testcover.el -- Visual code-coverage tool -*- lexical-binding:t -*- +;;; testcover.el --- Visual code-coverage tool -*- lexical-binding:t -*- ;; Copyright (C) 2002-2021 Free Software Foundation, Inc. @@ -675,4 +675,4 @@ The list is 1valued if all of its constituent elements are also 1valued." (testcover-analyze-coverage (cadr form))) (t (testcover-analyze-coverage-backquote form)))) -;; testcover.el ends here. +;;; testcover.el ends here diff --git a/lisp/emacs-lisp/text-property-search.el b/lisp/emacs-lisp/text-property-search.el index e909e4bf76..69943a83f1 100644 --- a/lisp/emacs-lisp/text-property-search.el +++ b/lisp/emacs-lisp/text-property-search.el @@ -214,3 +214,5 @@ and if a matching region is found, place point at its end." (funcall predicate value prop-value)) (provide 'text-property-search) + +;;; text-property-search.el ends here diff --git a/lisp/emacs-lisp/unsafep.el b/lisp/emacs-lisp/unsafep.el index d52a6c796d..fa4e0583ed 100644 --- a/lisp/emacs-lisp/unsafep.el +++ b/lisp/emacs-lisp/unsafep.el @@ -1,4 +1,4 @@ -;;;; unsafep.el -- Determine whether a Lisp form is safe to evaluate -*- lexical-binding: t; -*- +;;; unsafep.el --- Determine whether a Lisp form is safe to evaluate -*- lexical-binding: t; -*- ;; Copyright (C) 2002-2021 Free Software Foundation, Inc. diff --git a/lisp/erc/erc-button.el b/lisp/erc/erc-button.el index 044776c236..cb9af92ba1 100644 --- a/lisp/erc/erc-button.el +++ b/lisp/erc/erc-button.el @@ -1,4 +1,4 @@ -;; erc-button.el --- A way of buttonizing certain things in ERC buffers -*- lexical-binding:t -*- +;;; erc-button.el --- A way of buttonizing certain things in ERC buffers -*- lexical-binding:t -*- ;; Copyright (C) 1996-2004, 2006-2021 Free Software Foundation, Inc. diff --git a/lisp/erc/erc-desktop-notifications.el b/lisp/erc/erc-desktop-notifications.el index 990f013cd2..9838b23953 100644 --- a/lisp/erc/erc-desktop-notifications.el +++ b/lisp/erc/erc-desktop-notifications.el @@ -1,4 +1,4 @@ -;; erc-desktop-notifications.el -- Send notification on PRIVMSG or mentions -*- lexical-binding:t -*- +;;; erc-desktop-notifications.el --- Send notification on PRIVMSG or mentions -*- lexical-binding:t -*- ;; Copyright (C) 2012-2021 Free Software Foundation, Inc. diff --git a/lisp/erc/erc-goodies.el b/lisp/erc/erc-goodies.el index 1143faa1e2..fc9a8d39ef 100644 --- a/lisp/erc/erc-goodies.el +++ b/lisp/erc/erc-goodies.el @@ -1,4 +1,4 @@ -;; erc-goodies.el --- Collection of ERC modules -*- lexical-binding: t; -*- +;;; erc-goodies.el --- Collection of ERC modules -*- lexical-binding: t; -*- ;; Copyright (C) 2001-2021 Free Software Foundation, Inc. diff --git a/lisp/erc/erc-imenu.el b/lisp/erc/erc-imenu.el index b2a2dc588e..dcf6db7407 100644 --- a/lisp/erc/erc-imenu.el +++ b/lisp/erc/erc-imenu.el @@ -1,4 +1,4 @@ -;;; erc-imenu.el -- Imenu support for ERC -*- lexical-binding: t; -*- +;;; erc-imenu.el --- Imenu support for ERC -*- lexical-binding: t; -*- ;; Copyright (C) 2001-2002, 2004, 2006-2021 Free Software Foundation, ;; Inc. diff --git a/lisp/erc/erc-menu.el b/lisp/erc/erc-menu.el index 0dc819fbbb..1bee6ff2a6 100644 --- a/lisp/erc/erc-menu.el +++ b/lisp/erc/erc-menu.el @@ -1,4 +1,4 @@ -;; erc-menu.el -- Menu-bar definitions for ERC -*- lexical-binding: t; -*- +;;; erc-menu.el --- Menu-bar definitions for ERC -*- lexical-binding: t; -*- ;; Copyright (C) 2001-2002, 2004-2021 Free Software Foundation, Inc. diff --git a/lisp/erc/erc-page.el b/lisp/erc/erc-page.el index 4c244b7984..457e8cd468 100644 --- a/lisp/erc/erc-page.el +++ b/lisp/erc/erc-page.el @@ -1,4 +1,4 @@ -;; erc-page.el - CTCP PAGE support for ERC -*- lexical-binding: t; -*- +;;; erc-page.el --- CTCP PAGE support for ERC -*- lexical-binding: t; -*- ;; Copyright (C) 2002, 2004, 2006-2021 Free Software Foundation, Inc. diff --git a/lisp/erc/erc-replace.el b/lisp/erc/erc-replace.el index d08d9850c1..3f69c4cb9c 100644 --- a/lisp/erc/erc-replace.el +++ b/lisp/erc/erc-replace.el @@ -1,4 +1,4 @@ -;; erc-replace.el -- wash and massage messages inserted into the buffer -*- lexical-binding: t; -*- +;;; erc-replace.el --- wash and massage messages inserted into the buffer -*- lexical-binding: t; -*- ;; Copyright (C) 2001-2002, 2004, 2006-2021 Free Software Foundation, ;; Inc. diff --git a/lisp/erc/erc-ring.el b/lisp/erc/erc-ring.el index 28299ae46c..666fd58592 100644 --- a/lisp/erc/erc-ring.el +++ b/lisp/erc/erc-ring.el @@ -1,4 +1,4 @@ -;; erc-ring.el -- Command history handling for erc using ring.el -*- lexical-binding: t; -*- +;;; erc-ring.el --- Command history handling for erc using ring.el -*- lexical-binding: t; -*- ;; Copyright (C) 2001-2004, 2006-2021 Free Software Foundation, Inc. diff --git a/lisp/gnus/gnus-notifications.el b/lisp/gnus/gnus-notifications.el index a4d198b46e..8646904637 100644 --- a/lisp/gnus/gnus-notifications.el +++ b/lisp/gnus/gnus-notifications.el @@ -1,4 +1,4 @@ -;; gnus-notifications.el -- Send notification on new message in Gnus -*- lexical-binding: t; -*- +;;; gnus-notifications.el --- Send notification on new message in Gnus -*- lexical-binding: t; -*- ;; Copyright (C) 2012-2021 Free Software Foundation, Inc. diff --git a/lisp/gnus/legacy-gnus-agent.el b/lisp/gnus/legacy-gnus-agent.el index 091e3899c2..4f800891b2 100644 --- a/lisp/gnus/legacy-gnus-agent.el +++ b/lisp/gnus/legacy-gnus-agent.el @@ -1,4 +1,4 @@ -;;; gnus-agent.el --- Legacy unplugged support for Gnus -*- lexical-binding: t; -*- +;;; legacy-gnus-agent.el --- Legacy unplugged support for Gnus -*- lexical-binding: t; -*- ;; Copyright (C) 2004-2021 Free Software Foundation, Inc. diff --git a/lisp/gnus/mm-archive.el b/lisp/gnus/mm-archive.el index 1ecceeedeb..fdc83e1de6 100644 --- a/lisp/gnus/mm-archive.el +++ b/lisp/gnus/mm-archive.el @@ -108,4 +108,4 @@ (provide 'mm-archive) -;; mm-archive.el ends here +;;; mm-archive.el ends here diff --git a/lisp/gnus/spam-report.el b/lisp/gnus/spam-report.el index 7d93f8a555..a4234f8400 100644 --- a/lisp/gnus/spam-report.el +++ b/lisp/gnus/spam-report.el @@ -378,4 +378,4 @@ Process queued spam reports." (provide 'spam-report) -;;; spam-report.el ends here. +;;; spam-report.el ends here diff --git a/lisp/info.el b/lisp/info.el index dd7e16f870..5efac6f25f 100644 --- a/lisp/info.el +++ b/lisp/info.el @@ -1,4 +1,4 @@ -;; info.el --- Info package for Emacs -*- lexical-binding:t -*- +;;; info.el --- Info package for Emacs -*- lexical-binding:t -*- ;; Copyright (C) 1985-1986, 1992-2021 Free Software Foundation, Inc. diff --git a/lisp/language/burmese.el b/lisp/language/burmese.el index 373f25ac5c..ade3566717 100644 --- a/lisp/language/burmese.el +++ b/lisp/language/burmese.el @@ -55,3 +55,5 @@ (vector "." 0 #'font-shape-gstring)))) (set-char-table-range composition-function-table '(#x1000 . #x107F) elt) (set-char-table-range composition-function-table '(#xAA60 . #xAA7B) elt)) + +;;; burmese.el ends here diff --git a/lisp/language/cham.el b/lisp/language/cham.el index 3aac986b43..cbb35565af 100644 --- a/lisp/language/cham.el +++ b/lisp/language/cham.el @@ -43,3 +43,5 @@ an Austronesian language spoken by some 245,000 Chams in Vietnam and Cambodia."))) (provide 'cham) + +;;; cham.el ends here diff --git a/lisp/language/khmer.el b/lisp/language/khmer.el index 6f08e60d60..471af40165 100644 --- a/lisp/language/khmer.el +++ b/lisp/language/khmer.el @@ -35,4 +35,4 @@ (set-char-table-range composition-function-table '(#x1780 . #x17FF) val) (set-char-table-range composition-function-table '(#x19E0 . #x19FF) val)) -;; khmer.el ends here +;;; khmer.el ends here diff --git a/lisp/language/sinhala.el b/lisp/language/sinhala.el index 99a104ec33..89392ad6c5 100644 --- a/lisp/language/sinhala.el +++ b/lisp/language/sinhala.el @@ -45,4 +45,4 @@ "[\u0D80-\u0DFF]") 0 #'font-shape-gstring))) -;; sinhala.el ends here +;;; sinhala.el ends here diff --git a/lisp/language/tai-viet.el b/lisp/language/tai-viet.el index 4549b111a3..366c39202d 100644 --- a/lisp/language/tai-viet.el +++ b/lisp/language/tai-viet.el @@ -56,3 +56,5 @@ The language name is spelled as \"ꪁꪫꪱꪣ ꪼꪕ\", and the script name is spelled as \"ꪎꪳ ꪼꪕ\"."))) (provide 'tai-viet) + +;;; tai-viet.el ends here diff --git a/lisp/language/thai-word.el b/lisp/language/thai-word.el index 7a09bc3a24..5d0389c28d 100644 --- a/lisp/language/thai-word.el +++ b/lisp/language/thai-word.el @@ -1,4 +1,4 @@ -;;; thai-word.el -- find Thai word boundaries -*- lexical-binding: t; -*- +;;; thai-word.el --- find Thai word boundaries -*- lexical-binding: t; -*- ;; Copyright (C) 2000, 2001, 2002, 2003, 2004, 2005, 2006, 2007, 2008, 2009, 2010, 2011 ;; National Institute of Advanced Industrial Science and Technology (AIST) @@ -11074,4 +11074,4 @@ With argument, do this that many times." ;; coding: utf-8 ;; End: -;; thai-word.el ends here +;;; thai-word.el ends here diff --git a/lisp/language/tv-util.el b/lisp/language/tv-util.el index 1a530d350f..207d76f47c 100644 --- a/lisp/language/tv-util.el +++ b/lisp/language/tv-util.el @@ -136,5 +136,6 @@ (if (looking-at tai-viet-re) (tai-viet-compose-region from (match-end 0))))) -;; (provide 'tai-viet-util) + +;;; tv-util.el ends here diff --git a/lisp/leim/quail/croatian.el b/lisp/leim/quail/croatian.el index 08f1e47b6f..7402b81a8c 100644 --- a/lisp/leim/quail/croatian.el +++ b/lisp/leim/quail/croatian.el @@ -1,4 +1,4 @@ -;;; croatian.el -- Quail package for inputting Croatian -*-coding: utf-8; lexical-binding:t -*- +;;; croatian.el --- Quail package for inputting Croatian -*-coding: utf-8; lexical-binding:t -*- ;; Copyright (C) 2003-2021 Free Software Foundation, Inc. diff --git a/lisp/leim/quail/hebrew.el b/lisp/leim/quail/hebrew.el index fc6bb80596..28b2eb3436 100644 --- a/lisp/leim/quail/hebrew.el +++ b/lisp/leim/quail/hebrew.el @@ -1,4 +1,4 @@ -;; hebrew.el --- Quail package for inputting Hebrew characters -*- coding: utf-8; lexical-binding: t -*- +;;; hebrew.el --- Quail package for inputting Hebrew characters -*- coding: utf-8; lexical-binding: t -*- ;; Copyright (C) 1999, 2000, 2001, 2002, 2003, 2004, 2005, 2006, 2007, ;; 2008, 2009, 2010, 2011 diff --git a/lisp/leim/quail/persian.el b/lisp/leim/quail/persian.el index 4157f88670..cb1f6e3c78 100644 --- a/lisp/leim/quail/persian.el +++ b/lisp/leim/quail/persian.el @@ -1,4 +1,4 @@ -;;; persian.el --- Quail package for inputting Persian/Farsi keyboard -*- coding: utf-8; lexical-binding: t -*- +;;; persian.el --- Quail package for inputting Persian/Farsi keyboard -*- coding: utf-8; lexical-binding: t -*- ;; Copyright (C) 2011-2021 Free Software Foundation, Inc. diff --git a/lisp/mail/rmail-spam-filter.el b/lisp/mail/rmail-spam-filter.el index d833685a8d..fbac9e0cc0 100644 --- a/lisp/mail/rmail-spam-filter.el +++ b/lisp/mail/rmail-spam-filter.el @@ -555,4 +555,4 @@ checks to see if the old format is used, and updates it if necessary." (provide 'rmail-spam-filter) -;;; rmail-spam-filter ends here +;;; rmail-spam-filter.el ends here diff --git a/lisp/mail/uudecode.el b/lisp/mail/uudecode.el index fdd402e0fa..026356efe9 100644 --- a/lisp/mail/uudecode.el +++ b/lisp/mail/uudecode.el @@ -1,4 +1,4 @@ -;;; uudecode.el -- elisp native uudecode -*- lexical-binding:t -*- +;;; uudecode.el --- elisp native uudecode -*- lexical-binding:t -*- ;; Copyright (C) 1998-2021 Free Software Foundation, Inc. diff --git a/lisp/mh-e/mh-search.el b/lisp/mh-e/mh-search.el index 9df7c32656..b3a250bf13 100644 --- a/lisp/mh-e/mh-search.el +++ b/lisp/mh-e/mh-search.el @@ -1,4 +1,4 @@ -;;; mh-search --- MH-Search mode -*- lexical-binding: t; -*- +;;; mh-search.el --- MH-Search mode -*- lexical-binding: t; -*- ;; Copyright (C) 1993, 1995, 2001-2021 Free Software Foundation, Inc. @@ -1943,4 +1943,4 @@ folder buffer." ;; sentence-end-double-space: nil ;; End: -;;; mh-search ends here +;;; mh-search.el ends here diff --git a/lisp/net/newst-ticker.el b/lisp/net/newst-ticker.el index 2f76470870..8cfafb5bfe 100644 --- a/lisp/net/newst-ticker.el +++ b/lisp/net/newst-ticker.el @@ -1,4 +1,4 @@ -;; newst-ticker.el --- mode line ticker for newsticker. -*- lexical-binding: t; -*- +;;; newst-ticker.el --- mode line ticker for newsticker. -*- lexical-binding: t; -*- ;; Copyright (C) 2003-2021 Free Software Foundation, Inc. diff --git a/lisp/net/secrets.el b/lisp/net/secrets.el index 94db318c1b..4102b9d322 100644 --- a/lisp/net/secrets.el +++ b/lisp/net/secrets.el @@ -957,3 +957,5 @@ to their attributes." ;; * Check, whether the dh-ietf1024-aes128-cbc-pkcs7 algorithm can be ;; used for the transfer of the secrets. Currently, we use the ;; plain algorithm. + +;;; secrets.el ends here diff --git a/lisp/net/sieve-manage.el b/lisp/net/sieve-manage.el index c4d6ec4b6c..5dad5f446a 100644 --- a/lisp/net/sieve-manage.el +++ b/lisp/net/sieve-manage.el @@ -580,4 +580,4 @@ to local variable `sieve-manage-capability'." (provide 'sieve-manage) -;; sieve-manage.el ends here +;;; sieve-manage.el ends here diff --git a/lisp/net/sieve-mode.el b/lisp/net/sieve-mode.el index 966f0f056b..0e8fdc0a90 100644 --- a/lisp/net/sieve-mode.el +++ b/lisp/net/sieve-mode.el @@ -206,4 +206,4 @@ Turning on Sieve mode runs `sieve-mode-hook'." (provide 'sieve-mode) -;; sieve-mode.el ends here +;;; sieve-mode.el ends here diff --git a/lisp/net/sieve.el b/lisp/net/sieve.el index 595d63331a..6d571a0a30 100644 --- a/lisp/net/sieve.el +++ b/lisp/net/sieve.el @@ -379,4 +379,4 @@ Used to bracket operations which move point in the sieve-buffer." (provide 'sieve) -;; sieve.el ends here +;;; sieve.el ends here diff --git a/lisp/notifications.el b/lisp/notifications.el index b439d82231..ebd74dd3ef 100644 --- a/lisp/notifications.el +++ b/lisp/notifications.el @@ -420,3 +420,5 @@ version this library is compliant with." notifications-get-server-information-method))) (provide 'notifications) + +;;; notifications.el ends here diff --git a/lisp/nxml/rng-cmpct.el b/lisp/nxml/rng-cmpct.el index 3d4b9f8741..1314ade9e3 100644 --- a/lisp/nxml/rng-cmpct.el +++ b/lisp/nxml/rng-cmpct.el @@ -922,4 +922,4 @@ Current token after parse is token following ]." (provide 'rng-cmpct) -;;; rng-cmpct.el +;;; rng-cmpct.el ends here diff --git a/lisp/obsolete/info-edit.el b/lisp/obsolete/info-edit.el index c53616d80e..19958979a8 100644 --- a/lisp/obsolete/info-edit.el +++ b/lisp/obsolete/info-edit.el @@ -1,4 +1,4 @@ -;; info-edit.el --- Editing info files -*- lexical-binding:t -*- +;;; info-edit.el --- Editing info files -*- lexical-binding:t -*- ;; Copyright (C) 1985-1986, 1992-2021 Free Software Foundation, Inc. diff --git a/lisp/obsolete/old-emacs-lock.el b/lisp/obsolete/old-emacs-lock.el index 90ff93e03b..ce4c60e6a1 100644 --- a/lisp/obsolete/old-emacs-lock.el +++ b/lisp/obsolete/old-emacs-lock.el @@ -1,4 +1,4 @@ -;;; emacs-lock.el --- prevents you from exiting Emacs if a buffer is locked -*- lexical-binding: t; -*- +;;; old-emacs-lock.el --- prevents you from exiting Emacs if a buffer is locked -*- lexical-binding: t; -*- ;; Copyright (C) 1994, 1997, 2001-2021 Free Software Foundation, Inc. @@ -99,4 +99,4 @@ If the buffer is locked, signal error and display its name." (provide 'emacs-lock) -;;; emacs-lock.el ends here +;;; old-emacs-lock.el ends here diff --git a/lisp/obsolete/otodo-mode.el b/lisp/obsolete/otodo-mode.el index add17b265b..47f5089452 100644 --- a/lisp/obsolete/otodo-mode.el +++ b/lisp/obsolete/otodo-mode.el @@ -1,4 +1,4 @@ -;;; todo-mode.el --- major mode for editing TODO list files -*- lexical-binding: t; -*- +;;; otodo-mode.el --- major mode for editing TODO list files -*- lexical-binding: t; -*- ;; Copyright (C) 1997, 1999, 2001-2021 Free Software Foundation, Inc. @@ -963,4 +963,4 @@ If INCLUDE-SEP is non-nil, return point after the separator." (provide 'todo-mode) -;;; todo-mode.el ends here +;;; otodo-mode.el ends here diff --git a/lisp/obsolete/sb-image.el b/lisp/obsolete/sb-image.el index e9a507f008..fc9e03eae6 100644 --- a/lisp/obsolete/sb-image.el +++ b/lisp/obsolete/sb-image.el @@ -1,4 +1,4 @@ -;;; sb-image --- Image management for speedbar -*- lexical-binding: t; -*- +;;; sb-image.el --- Image management for speedbar -*- lexical-binding: t; -*- ;; Copyright (C) 1999-2003, 2005-2019, 2021 Free Software Foundation, ;; Inc. diff --git a/lisp/org/ob-hledger.el b/lisp/org/ob-hledger.el index 3d2f46cdce..48dcb8cea1 100644 --- a/lisp/org/ob-hledger.el +++ b/lisp/org/ob-hledger.el @@ -1,4 +1,4 @@ -;; ob-hledger.el --- Babel Functions for hledger -*- lexical-binding: t; -*- +;;; ob-hledger.el --- Babel Functions for hledger -*- lexical-binding: t; -*- ;; Copyright (C) 2010-2021 Free Software Foundation, Inc. diff --git a/lisp/org/ob-mscgen.el b/lisp/org/ob-mscgen.el index 999d4f4140..79c9f8702e 100644 --- a/lisp/org/ob-mscgen.el +++ b/lisp/org/ob-mscgen.el @@ -1,4 +1,4 @@ -;;; ob-msc.el --- Babel Functions for Mscgen -*- lexical-binding: t; -*- +;;; ob-mscgen.el --- Babel Functions for Mscgen -*- lexical-binding: t; -*- ;; Copyright (C) 2010-2021 Free Software Foundation, Inc. @@ -78,4 +78,4 @@ mscgen supported formats." (provide 'ob-mscgen) -;;; ob-msc.el ends here +;;; ob-mscgen.el ends here diff --git a/lisp/org/ol-eshell.el b/lisp/org/ol-eshell.el index 769e7ee522..8920e0afb0 100644 --- a/lisp/org/ol-eshell.el +++ b/lisp/org/ol-eshell.el @@ -1,4 +1,4 @@ -;;; ol-eshell.el - Links to Working Directories in Eshell -*- lexical-binding: t; -*- +;;; ol-eshell.el --- Links to Working Directories in Eshell -*- lexical-binding: t; -*- ;; Copyright (C) 2011-2021 Free Software Foundation, Inc. diff --git a/lisp/org/org-ctags.el b/lisp/org/org-ctags.el index 1fca873c15..dc2b3be632 100644 --- a/lisp/org/org-ctags.el +++ b/lisp/org/org-ctags.el @@ -1,5 +1,5 @@ -;;; org-ctags.el - Integrate Emacs "tags" Facility with Org -*- lexical-binding: t; -*- -;; +;;; org-ctags.el --- Integrate Emacs "tags" Facility with Org -*- lexical-binding: t; -*- + ;; Copyright (C) 2007-2021 Free Software Foundation, Inc. ;; Author: Paul Sexton diff --git a/lisp/org/ox-man.el b/lisp/org/ox-man.el index 6cace7e698..27d2dedb8e 100644 --- a/lisp/org/ox-man.el +++ b/lisp/org/ox-man.el @@ -1,4 +1,4 @@ -;; ox-man.el --- Man Back-End for Org Export Engine -*- lexical-binding: t; -*- +;;; ox-man.el --- Man Back-End for Org Export Engine -*- lexical-binding: t; -*- ;; Copyright (C) 2011-2021 Free Software Foundation, Inc. diff --git a/lisp/progmodes/bug-reference.el b/lisp/progmodes/bug-reference.el index e467d98303..0c5837cae7 100644 --- a/lisp/progmodes/bug-reference.el +++ b/lisp/progmodes/bug-reference.el @@ -1,4 +1,4 @@ -;; bug-reference.el --- buttonize bug references -*- lexical-binding: t; -*- +;;; bug-reference.el --- buttonize bug references -*- lexical-binding: t; -*- ;; Copyright (C) 2008-2021 Free Software Foundation, Inc. diff --git a/lisp/progmodes/cc-awk.el b/lisp/progmodes/cc-awk.el index 84cc5b115e..334e82114f 100644 --- a/lisp/progmodes/cc-awk.el +++ b/lisp/progmodes/cc-awk.el @@ -1227,4 +1227,4 @@ comment at the start of cc-engine.el for more info." ;; indent-tabs-mode: t ;; tab-width: 8 ;; End: -;;; awk-mode.el ends here +;;; cc-awk.el ends here diff --git a/lisp/progmodes/idlw-shell.el b/lisp/progmodes/idlw-shell.el index 134a6c6e49..ad8feb988f 100644 --- a/lisp/progmodes/idlw-shell.el +++ b/lisp/progmodes/idlw-shell.el @@ -1,4 +1,4 @@ -;; idlw-shell.el --- run IDL as an inferior process of Emacs. -*- lexical-binding:t -*- +;;; idlw-shell.el --- run IDL as an inferior process of Emacs. -*- lexical-binding:t -*- ;; Copyright (C) 1999-2021 Free Software Foundation, Inc. diff --git a/lisp/progmodes/idlwave.el b/lisp/progmodes/idlwave.el index 75f2016fc2..b55a98af0b 100644 --- a/lisp/progmodes/idlwave.el +++ b/lisp/progmodes/idlwave.el @@ -1,4 +1,4 @@ -;; idlwave.el --- IDL editing mode for GNU Emacs -*- lexical-binding: t; -*- +;;; idlwave.el --- IDL editing mode for GNU Emacs -*- lexical-binding: t; -*- ;; Copyright (C) 1999-2021 Free Software Foundation, Inc. diff --git a/lisp/progmodes/js.el b/lisp/progmodes/js.el index 6d6063d783..a942235f47 100644 --- a/lisp/progmodes/js.el +++ b/lisp/progmodes/js.el @@ -4655,4 +4655,4 @@ one of the aforementioned options instead of using this mode." (provide 'js) -;; js.el ends here +;;; js.el ends here diff --git a/lisp/progmodes/sql.el b/lisp/progmodes/sql.el index 6e53a04f72..65a4094d70 100644 --- a/lisp/progmodes/sql.el +++ b/lisp/progmodes/sql.el @@ -5606,7 +5606,7 @@ The default value disables the internal pager." (provide 'sql) -;;; sql.el ends here - ; LocalWords: sql SQL SQLite sqlite Sybase Informix MySQL ; LocalWords: Postgres SQLServer SQLi + +;;; sql.el ends here diff --git a/lisp/ses.el b/lisp/ses.el index 6058d48ed1..98785b6b93 100644 --- a/lisp/ses.el +++ b/lisp/ses.el @@ -1,4 +1,4 @@ -;;; ses.el -- Simple Emacs Spreadsheet -*- lexical-binding:t -*- +;;; ses.el --- Simple Emacs Spreadsheet -*- lexical-binding:t -*- ;; Copyright (C) 2002-2021 Free Software Foundation, Inc. diff --git a/lisp/speedbar.el b/lisp/speedbar.el index 118c726076..4666026f35 100644 --- a/lisp/speedbar.el +++ b/lisp/speedbar.el @@ -1,4 +1,4 @@ -;;; speedbar --- quick access to files and tags in a frame -*- lexical-binding: t; -*- +;;; speedbar.el --- quick access to files and tags in a frame -*- lexical-binding: t; -*- ;; Copyright (C) 1996-2021 Free Software Foundation, Inc. @@ -4057,4 +4057,4 @@ this version is not backward compatible to 0.14 or earlier.") (run-hooks 'speedbar-load-hook) -;;; speedbar ends here +;;; speedbar.el ends here diff --git a/lisp/term/konsole.el b/lisp/term/konsole.el index e38a5d34e7..1f65a46011 100644 --- a/lisp/term/konsole.el +++ b/lisp/term/konsole.el @@ -9,4 +9,4 @@ (provide 'term/konsole) -;; konsole.el ends here +;;; konsole.el ends here diff --git a/lisp/term/linux.el b/lisp/term/linux.el index 35bd3ac0ac..c6d84ab96c 100644 --- a/lisp/term/linux.el +++ b/lisp/term/linux.el @@ -1,4 +1,6 @@ -;; The Linux console handles Latin-1 by default. -*- lexical-binding:t -*- +;;; linux.el -*- lexical-binding:t -*- + +;; The Linux console handles Latin-1 by default. (declare-function gpm-mouse-enable "t-mouse" ()) diff --git a/lisp/term/lk201.el b/lisp/term/lk201.el index 3bcaa2ecd1..c280247767 100644 --- a/lisp/term/lk201.el +++ b/lisp/term/lk201.el @@ -1,4 +1,4 @@ -;; Define function key sequences for DEC terminals. -*- lexical-binding: t -*- +;;; lk201.el --- Define function key sequences for DEC terminals. -*- lexical-binding: t -*- (defvar lk201-function-map (let ((map (make-sparse-keymap))) diff --git a/lisp/term/screen.el b/lisp/term/screen.el index 04481e8358..9655f41b6c 100644 --- a/lisp/term/screen.el +++ b/lisp/term/screen.el @@ -22,4 +22,4 @@ it runs, which can change when the screen session is moved to another tty." (provide 'term/screen) -;; screen.el ends here +;;; screen.el ends here diff --git a/lisp/term/st.el b/lisp/term/st.el index 08432c414a..9a1c0646f8 100644 --- a/lisp/term/st.el +++ b/lisp/term/st.el @@ -17,4 +17,4 @@ (provide 'term/st) -;; st.el ends here +;;; st.el ends here diff --git a/lisp/term/tmux.el b/lisp/term/tmux.el index aa0c98364f..4ea6f416c8 100644 --- a/lisp/term/tmux.el +++ b/lisp/term/tmux.el @@ -22,4 +22,4 @@ it runs, which can change when the tmux session is moved to another tty." (provide 'term/tmux) -;; tmux.el ends here +;;; tmux.el ends here diff --git a/lisp/term/w32console.el b/lisp/term/w32console.el index 4a925cd84c..1a5dc05783 100644 --- a/lisp/term/w32console.el +++ b/lisp/term/w32console.el @@ -1,4 +1,4 @@ -;;; w32console.el -- Setup w32 console keys and colors. -*- lexical-binding: t; -*- +;;; w32console.el --- Setup w32 console keys and colors. -*- lexical-binding: t; -*- ;; Copyright (C) 2007-2021 Free Software Foundation, Inc. diff --git a/lisp/textmodes/remember.el b/lisp/textmodes/remember.el index 8a0436afc6..4acdc9f4d8 100644 --- a/lisp/textmodes/remember.el +++ b/lisp/textmodes/remember.el @@ -1,4 +1,4 @@ -;;; remember --- a mode for quickly jotting down things to remember -*- lexical-binding: t; -*- +;;; remember.el --- a mode for quickly jotting down things to remember -*- lexical-binding: t; -*- ;; Copyright (C) 1999-2001, 2003-2021 Free Software Foundation, Inc. diff --git a/lisp/url/url-mailto.el b/lisp/url/url-mailto.el index c6901d9920..29c2780121 100644 --- a/lisp/url/url-mailto.el +++ b/lisp/url/url-mailto.el @@ -1,4 +1,4 @@ -;;; url-mail.el --- Mail Uniform Resource Locator retrieval code -*- lexical-binding: t; -*- +;;; url-mailto.el --- Mail Uniform Resource Locator retrieval code -*- lexical-binding: t; -*- ;; Copyright (C) 1996-1999, 2004-2021 Free Software Foundation, Inc. diff --git a/lisp/vc/vc-dispatcher.el b/lisp/vc/vc-dispatcher.el index 2b477dff0a..87ca542f1c 100644 --- a/lisp/vc/vc-dispatcher.el +++ b/lisp/vc/vc-dispatcher.el @@ -1,4 +1,4 @@ -;;; vc-dispatcher.el -- generic command-dispatcher facility. -*- lexical-binding: t -*- +;;; vc-dispatcher.el --- generic command-dispatcher facility. -*- lexical-binding: t -*- ;; Copyright (C) 2008-2021 Free Software Foundation, Inc. diff --git a/lisp/vc/vc-filewise.el b/lisp/vc/vc-filewise.el index e1b042a742..254e47933d 100644 --- a/lisp/vc/vc-filewise.el +++ b/lisp/vc/vc-filewise.el @@ -82,3 +82,5 @@ If the file is not registered, or the master name is not known, return nil." nil)))) ; Not registered (provide 'vc-filewise) + +;;; vc-filewise.el ends here diff --git a/test/lisp/autorevert-tests.el b/test/lisp/autorevert-tests.el index 5f27c2e38a..3e97e9cfa5 100644 --- a/test/lisp/autorevert-tests.el +++ b/test/lisp/autorevert-tests.el @@ -1,4 +1,4 @@ -;;; auto-revert-tests.el --- Tests of auto-revert -*- lexical-binding: t -*- +;;; autorevert-tests.el --- Tests of auto-revert -*- lexical-binding: t -*- ;; Copyright (C) 2015-2021 Free Software Foundation, Inc. diff --git a/test/lisp/calendar/icalendar-tests.el b/test/lisp/calendar/icalendar-tests.el index 61d3c11f6d..6973f7e5c9 100644 --- a/test/lisp/calendar/icalendar-tests.el +++ b/test/lisp/calendar/icalendar-tests.el @@ -1,4 +1,4 @@ -;; icalendar-tests.el --- Test suite for icalendar.el -*- lexical-binding:t -*- +;;; icalendar-tests.el --- Test suite for icalendar.el -*- lexical-binding:t -*- ;; Copyright (C) 2005, 2008-2021 Free Software Foundation, Inc. diff --git a/test/lisp/calendar/parse-time-tests.el b/test/lisp/calendar/parse-time-tests.el index b90fe0bd85..b706b73570 100644 --- a/test/lisp/calendar/parse-time-tests.el +++ b/test/lisp/calendar/parse-time-tests.el @@ -1,4 +1,4 @@ -;; parse-time-tests.el --- Test suite for parse-time.el -*- lexical-binding:t -*- +;;; parse-time-tests.el --- Test suite for parse-time.el -*- lexical-binding:t -*- ;; Copyright (C) 2016-2021 Free Software Foundation, Inc. diff --git a/test/lisp/cedet/srecode-utest-template.el b/test/lisp/cedet/srecode-utest-template.el index f97ff18320..087dcfd899 100644 --- a/test/lisp/cedet/srecode-utest-template.el +++ b/test/lisp/cedet/srecode-utest-template.el @@ -1,4 +1,4 @@ -;;; srecode/test.el --- SRecode Core Template tests. -*- lexical-binding:t -*- +;;; srecode-utest-template.el --- SRecode Core Template tests. -*- lexical-binding:t -*- ;; Copyright (C) 2008-2021 Free Software Foundation, Inc. diff --git a/test/lisp/custom-resources/custom--test-theme.el b/test/lisp/custom-resources/custom--test-theme.el index 4ced98a50b..122bd79569 100644 --- a/test/lisp/custom-resources/custom--test-theme.el +++ b/test/lisp/custom-resources/custom--test-theme.el @@ -1,4 +1,4 @@ -;;; custom--test-theme.el -- A test theme. -*- lexical-binding:t -*- +;;; custom--test-theme.el --- A test theme. -*- lexical-binding:t -*- (deftheme custom--test "A test theme.") diff --git a/test/lisp/descr-text-tests.el b/test/lisp/descr-text-tests.el index 6ba455b50d..2052dc0e38 100644 --- a/test/lisp/descr-text-tests.el +++ b/test/lisp/descr-text-tests.el @@ -1,4 +1,4 @@ -;;; descr-text-test.el --- ERT tests for descr-text.el -*- lexical-binding: t -*- +;;; descr-text-tests.el --- ERT tests for descr-text.el -*- lexical-binding: t -*- ;; Copyright (C) 2014, 2016-2021 Free Software Foundation, Inc. diff --git a/test/lisp/emacs-lisp/eieio-tests/eieio-test-methodinvoke.el b/test/lisp/emacs-lisp/eieio-tests/eieio-test-methodinvoke.el index 285616a780..9f9bb73133 100644 --- a/test/lisp/emacs-lisp/eieio-tests/eieio-test-methodinvoke.el +++ b/test/lisp/emacs-lisp/eieio-tests/eieio-test-methodinvoke.el @@ -1,4 +1,4 @@ -;;; eieio-testsinvoke.el -- eieio tests for method invocation -*- lexical-binding:t -*- +;;; eieio-test-methodinvoke.el --- eieio tests for method invocation -*- lexical-binding:t -*- ;; Copyright (C) 2005, 2008, 2010, 2013-2021 Free Software Foundation, ;; Inc. diff --git a/test/lisp/emacs-lisp/eieio-tests/eieio-tests.el b/test/lisp/emacs-lisp/eieio-tests/eieio-tests.el index a47fb8053b..11ffc115f7 100644 --- a/test/lisp/emacs-lisp/eieio-tests/eieio-tests.el +++ b/test/lisp/emacs-lisp/eieio-tests/eieio-tests.el @@ -1,4 +1,4 @@ -;;; eieio-tests.el -- eieio test routines -*- lexical-binding: t -*- +;;; eieio-tests.el --- eieio test routines -*- lexical-binding: t -*- ;; Copyright (C) 1999-2003, 2005-2010, 2012-2021 Free Software ;; Foundation, Inc. diff --git a/test/lisp/eshell/em-hist-tests.el b/test/lisp/eshell/em-hist-tests.el index ec65397fd6..31967a61c3 100644 --- a/test/lisp/eshell/em-hist-tests.el +++ b/test/lisp/eshell/em-hist-tests.el @@ -1,4 +1,4 @@ -;;; tests/em-hist-tests.el --- em-hist test suite -*- lexical-binding:t -*- +;;; em-hist-tests.el --- em-hist test suite -*- lexical-binding:t -*- ;; Copyright (C) 2017-2021 Free Software Foundation, Inc. diff --git a/test/lisp/eshell/em-ls-tests.el b/test/lisp/eshell/em-ls-tests.el index fc2cd9c8e1..5d1742b76f 100644 --- a/test/lisp/eshell/em-ls-tests.el +++ b/test/lisp/eshell/em-ls-tests.el @@ -1,4 +1,4 @@ -;;; tests/em-ls-tests.el --- em-ls test suite -*- lexical-binding:t -*- +;;; em-ls-tests.el --- em-ls test suite -*- lexical-binding:t -*- ;; Copyright (C) 2017-2021 Free Software Foundation, Inc. diff --git a/test/lisp/eshell/esh-opt-tests.el b/test/lisp/eshell/esh-opt-tests.el index 0c99da64b2..e2a0ea59d1 100644 --- a/test/lisp/eshell/esh-opt-tests.el +++ b/test/lisp/eshell/esh-opt-tests.el @@ -1,4 +1,4 @@ -;;; tests/esh-opt-tests.el --- esh-opt test suite -*- lexical-binding:t -*- +;;; esh-opt-tests.el --- esh-opt test suite -*- lexical-binding:t -*- ;; Copyright (C) 2018-2021 Free Software Foundation, Inc. diff --git a/test/lisp/eshell/eshell-tests.el b/test/lisp/eshell/eshell-tests.el index 4dac7024f4..4f0cc9b678 100644 --- a/test/lisp/eshell/eshell-tests.el +++ b/test/lisp/eshell/eshell-tests.el @@ -1,4 +1,4 @@ -;;; tests/eshell-tests.el --- Eshell test suite -*- lexical-binding:t -*- +;;; eshell-tests.el --- Eshell test suite -*- lexical-binding:t -*- ;; Copyright (C) 1999-2021 Free Software Foundation, Inc. diff --git a/test/lisp/gnus/message-tests.el b/test/lisp/gnus/message-tests.el index 8650053b68..36ec8c51d1 100644 --- a/test/lisp/gnus/message-tests.el +++ b/test/lisp/gnus/message-tests.el @@ -1,4 +1,4 @@ -;;; message-mode-tests.el --- Tests for message-mode -*- lexical-binding: t; -*- +;;; message-tests.el --- Tests for message-mode -*- lexical-binding: t; -*- ;; Copyright (C) 2015-2021 Free Software Foundation, Inc. diff --git a/test/lisp/info-xref-tests.el b/test/lisp/info-xref-tests.el index 95af21fb59..ecba86146f 100644 --- a/test/lisp/info-xref-tests.el +++ b/test/lisp/info-xref-tests.el @@ -1,4 +1,4 @@ -;;; info-xref.el --- tests for info-xref.el -*- lexical-binding:t -*- +;;; info-xref-tests.el --- tests for info-xref.el -*- lexical-binding:t -*- ;; Copyright (C) 2013-2021 Free Software Foundation, Inc. diff --git a/test/lisp/international/ucs-normalize-tests.el b/test/lisp/international/ucs-normalize-tests.el index a2da73767b..51f4ed3a80 100644 --- a/test/lisp/international/ucs-normalize-tests.el +++ b/test/lisp/international/ucs-normalize-tests.el @@ -1,4 +1,4 @@ -;;; ucs-normalize --- tests for international/ucs-normalize.el -*- lexical-binding: t -*- +;;; ucs-normalize-tests.el --- tests for international/ucs-normalize.el -*- lexical-binding: t -*- ;; Copyright (C) 2002-2021 Free Software Foundation, Inc. diff --git a/test/lisp/net/nsm-tests.el b/test/lisp/net/nsm-tests.el index ff453319b3..1a35ec34cb 100644 --- a/test/lisp/net/nsm-tests.el +++ b/test/lisp/net/nsm-tests.el @@ -1,4 +1,4 @@ -;;; network-stream-tests.el --- tests for network security manager -*- lexical-binding: t; -*- +;;; nsm-tests.el --- tests for network security manager -*- lexical-binding: t; -*- ;; Copyright (C) 2019-2021 Free Software Foundation, Inc. diff --git a/test/lisp/net/shr-tests.el b/test/lisp/net/shr-tests.el index a06e31a4f8..ed532af657 100644 --- a/test/lisp/net/shr-tests.el +++ b/test/lisp/net/shr-tests.el @@ -1,4 +1,4 @@ -;;; network-stream-tests.el --- tests for network processes -*- lexical-binding: t; -*- +;;; shr-tests.el --- tests for shr.el -*- lexical-binding: t; -*- ;; Copyright (C) 2016-2021 Free Software Foundation, Inc. diff --git a/test/lisp/play/cookie1-tests.el b/test/lisp/play/cookie1-tests.el index d63ecb972a..75dea4e5ef 100644 --- a/test/lisp/play/cookie1-tests.el +++ b/test/lisp/play/cookie1-tests.el @@ -1,4 +1,4 @@ -;;; fortune-tests.el --- Tests for fortune.el -*- lexical-binding: t -*- +;;; cookie1-tests.el --- Tests for cookie1.el -*- lexical-binding: t -*- ;; Copyright (C) 2021 Free Software Foundation, Inc. diff --git a/test/lisp/progmodes/cperl-mode-tests.el b/test/lisp/progmodes/cperl-mode-tests.el index 14bc48b92f..107b359dc3 100644 --- a/test/lisp/progmodes/cperl-mode-tests.el +++ b/test/lisp/progmodes/cperl-mode-tests.el @@ -1,4 +1,4 @@ -;;; cperl-mode-tests --- Test for cperl-mode -*- lexical-binding: t -*- +;;; cperl-mode-tests.el --- Test for cperl-mode -*- lexical-binding: t -*- ;; Copyright (C) 2020-2021 Free Software Foundation, Inc. diff --git a/test/lisp/progmodes/perl-mode-tests.el b/test/lisp/progmodes/perl-mode-tests.el index 9f6800ccd6..f63f8ad725 100644 --- a/test/lisp/progmodes/perl-mode-tests.el +++ b/test/lisp/progmodes/perl-mode-tests.el @@ -1,4 +1,4 @@ -;;; perl-mode-tests --- Test for perl-mode -*- lexical-binding: t -*- +;;; perl-mode-tests.el --- Test for perl-mode -*- lexical-binding: t -*- ;; Copyright (C) 2020-2021 Free Software Foundation, Inc. diff --git a/test/lisp/simple-tests.el b/test/lisp/simple-tests.el index 601eca6cd4..4b153d117f 100644 --- a/test/lisp/simple-tests.el +++ b/test/lisp/simple-tests.el @@ -1,4 +1,4 @@ -;;; simple-test.el --- Tests for simple.el -*- lexical-binding: t; -*- +;;; simple-tests.el --- Tests for simple.el -*- lexical-binding: t; -*- ;; Copyright (C) 2015-2021 Free Software Foundation, Inc. diff --git a/test/lisp/textmodes/fill-tests.el b/test/lisp/textmodes/fill-tests.el index 21efe62099..a4c7f447b5 100644 --- a/test/lisp/textmodes/fill-tests.el +++ b/test/lisp/textmodes/fill-tests.el @@ -1,4 +1,4 @@ -;;; fill-test.el --- ERT tests for fill.el -*- lexical-binding: t -*- +;;; fill-tests.el --- ERT tests for fill.el -*- lexical-binding: t -*- ;; Copyright (C) 2017-2021 Free Software Foundation, Inc. diff --git a/test/lisp/textmodes/tildify-tests.el b/test/lisp/textmodes/tildify-tests.el index 59c2394330..3ee3cd6fb1 100644 --- a/test/lisp/textmodes/tildify-tests.el +++ b/test/lisp/textmodes/tildify-tests.el @@ -1,4 +1,4 @@ -;;; tildify-test.el --- ERT tests for tildify.el -*- lexical-binding: t -*- +;;; tildify-tests.el --- ERT tests for tildify.el -*- lexical-binding: t -*- ;; Copyright (C) 2014-2021 Free Software Foundation, Inc. diff --git a/test/lisp/thingatpt-tests.el b/test/lisp/thingatpt-tests.el index 62a27f09cb..07eb8bb250 100644 --- a/test/lisp/thingatpt-tests.el +++ b/test/lisp/thingatpt-tests.el @@ -1,4 +1,4 @@ -;;; thingatpt.el --- tests for thing-at-point. -*- lexical-binding:t -*- +;;; thingatpt-tests.el --- tests for thing-at-point. -*- lexical-binding:t -*- ;; Copyright (C) 2013-2021 Free Software Foundation, Inc. diff --git a/test/lisp/vc/vc-bzr-tests.el b/test/lisp/vc/vc-bzr-tests.el index aeab51ec26..b02dce8f70 100644 --- a/test/lisp/vc/vc-bzr-tests.el +++ b/test/lisp/vc/vc-bzr-tests.el @@ -1,4 +1,4 @@ -;;; vc-bzr.el --- tests for vc/vc-bzr.el -*- lexical-binding: t -*- +;;; vc-bzr-tests.el --- tests for vc/vc-bzr.el -*- lexical-binding: t -*- ;; Copyright (C) 2011-2021 Free Software Foundation, Inc. diff --git a/test/lisp/xml-tests.el b/test/lisp/xml-tests.el index cd3e1138f4..b00b58acfc 100644 --- a/test/lisp/xml-tests.el +++ b/test/lisp/xml-tests.el @@ -1,4 +1,4 @@ -;;; xml-parse-tests.el --- Test suite for XML parsing. -*- lexical-binding:t -*- +;;; xml-tests.el --- Test suite for XML parsing. -*- lexical-binding:t -*- ;; Copyright (C) 2012-2021 Free Software Foundation, Inc. diff --git a/test/manual/cedet/semantic-tests.el b/test/manual/cedet/semantic-tests.el index 7169c78bea..1561c18dd6 100644 --- a/test/manual/cedet/semantic-tests.el +++ b/test/manual/cedet/semantic-tests.el @@ -1,4 +1,4 @@ -;;; semantic-utest.el --- Miscellaneous Semantic tests. -*- lexical-binding: t; -*- +;;; semantic-tests.el --- Miscellaneous Semantic tests. -*- lexical-binding: t; -*- ;; Copyright (C) 2003-2021 Free Software Foundation, Inc. diff --git a/test/manual/image-size-tests.el b/test/manual/image-size-tests.el index f7c2bf7fc0..44846a7a67 100644 --- a/test/manual/image-size-tests.el +++ b/test/manual/image-size-tests.el @@ -1,4 +1,4 @@ -;;; image-size-tests.el -- tests for image scaling -*- lexical-binding: t; -*- +;;; image-size-tests.el --- tests for image scaling -*- lexical-binding: t; -*- ;; Copyright (C) 2017-2021 Free Software Foundation, Inc. diff --git a/test/manual/image-transforms-tests.el b/test/manual/image-transforms-tests.el index 5342b5edca..debb74f2ed 100644 --- a/test/manual/image-transforms-tests.el +++ b/test/manual/image-transforms-tests.el @@ -1,4 +1,4 @@ -;;; image-transform-tests.el --- Test suite for image transforms. -*- lexical-binding: t -*- +;;; image-transforms-tests.el --- Test suite for image transforms. -*- lexical-binding: t -*- ;; Copyright (C) 2019-2021 Free Software Foundation, Inc. diff --git a/test/manual/scroll-tests.el b/test/manual/scroll-tests.el index 2f40b2bb69..dd15d54fa8 100644 --- a/test/manual/scroll-tests.el +++ b/test/manual/scroll-tests.el @@ -1,4 +1,4 @@ -;;; scroll-tests.el -- tests for scrolling -*- lexical-binding: t -*- +;;; scroll-tests.el --- tests for scrolling -*- lexical-binding: t -*- ;; Copyright (C) 2017-2021 Free Software Foundation, Inc. diff --git a/test/misc/test-custom-noloads.el b/test/misc/test-custom-noloads.el index 6fa6a6c90d..5e95e7d774 100644 --- a/test/misc/test-custom-noloads.el +++ b/test/misc/test-custom-noloads.el @@ -1,4 +1,4 @@ -;;; test-custom-deps.el --- Test custom noloads -*- lexical-binding:t -*- +;;; test-custom-noloads.el --- Test custom noloads -*- lexical-binding:t -*- ;; Copyright (C) 2021 Free Software Foundation, Inc. @@ -42,4 +42,4 @@ (cus-test-noloads) (should-not cus-test-vars-not-cus-loaded)) -;;; test-custom-deps.el ends here +;;; test-custom-noloads.el ends here diff --git a/test/src/character-tests.el b/test/src/character-tests.el index 10fc4dbf35..f630b32a5e 100644 --- a/test/src/character-tests.el +++ b/test/src/character-tests.el @@ -1,4 +1,4 @@ -;;; character-tests.el -- tests for character.c -*- lexical-binding:t -*- +;;; character-tests.el --- tests for character.c -*- lexical-binding:t -*- ;; Copyright (C) 2021 Free Software Foundation, Inc. diff --git a/test/src/editfns-tests.el b/test/src/editfns-tests.el index ea80da4819..a731a95ccf 100644 --- a/test/src/editfns-tests.el +++ b/test/src/editfns-tests.el @@ -1,4 +1,4 @@ -;;; editfns-tests.el -- tests for editfns.c -*- lexical-binding:t -*- +;;; editfns-tests.el --- tests for editfns.c -*- lexical-binding:t -*- ;; Copyright (C) 2016-2021 Free Software Foundation, Inc. diff --git a/test/src/emacs-module-tests.el b/test/src/emacs-module-tests.el index af5bc2a0ba..0a68d51e3e 100644 --- a/test/src/emacs-module-tests.el +++ b/test/src/emacs-module-tests.el @@ -1,4 +1,4 @@ -;;; emacs-module-tests --- Test GNU Emacs modules. -*- lexical-binding: t; -*- +;;; emacs-module-tests.el --- Test GNU Emacs modules. -*- lexical-binding: t; -*- ;; Copyright 2015-2021 Free Software Foundation, Inc. diff --git a/test/src/fileio-tests.el b/test/src/fileio-tests.el index 7f193d4eea..b989c97fe6 100644 --- a/test/src/fileio-tests.el +++ b/test/src/fileio-tests.el @@ -1,4 +1,4 @@ -;;; unit tests for src/fileio.c -*- lexical-binding: t; -*- +;;; fileio-tests.el --- unit tests for src/fileio.c -*- lexical-binding: t; -*- ;; Copyright 2017-2021 Free Software Foundation, Inc. diff --git a/test/src/thread-tests.el b/test/src/thread-tests.el index 0e1ca76fd9..fc7bc7441b 100644 --- a/test/src/thread-tests.el +++ b/test/src/thread-tests.el @@ -1,4 +1,4 @@ -;;; threads.el --- tests for threads. -*- lexical-binding: t -*- +;;; thread-tests.el --- tests for threads. -*- lexical-binding: t -*- ;; Copyright (C) 2012-2021 Free Software Foundation, Inc. diff --git a/test/src/timefns-tests.el b/test/src/timefns-tests.el index e55bd1eb4e..0a450a7573 100644 --- a/test/src/timefns-tests.el +++ b/test/src/timefns-tests.el @@ -1,4 +1,4 @@ -;;; timefns-tests.el -- tests for timefns.c -*- lexical-binding: t -*- +;;; timefns-tests.el --- tests for timefns.c -*- lexical-binding: t -*- ;; Copyright (C) 2016-2021 Free Software Foundation, Inc. commit 518312346d9440d18e224231cb645cb3aaf373ba Author: Michael Albinus Date: Mon Apr 19 11:52:48 2021 +0200 Add Tramp recompilation * doc/misc/tramp.texi (Frequently Asked Questions): Refer to GNU ELPA Tramp README. * lisp/net/tramp-cmds.el (tramp-recompile-elpa-command-completion-p) (tramp-recompile-elpa): New defuns. Add property `completion-predicate'. diff --git a/doc/misc/tramp.texi b/doc/misc/tramp.texi index 40245acb8e..e0f648fbd9 100644 --- a/doc/misc/tramp.texi +++ b/doc/misc/tramp.texi @@ -5095,34 +5095,20 @@ two forms in your @file{~/.emacs} after loading the @code{tramp} and @item I get a warning @samp{Tramp has been compiled with Emacs a.b, this is Emacs c.d} +@item +I get an error @samp{tramp-file-name-handler: Invalid function: +tramp-compat-with-mutex} @value{tramp} comes with compatibility code for different Emacs versions. When you see this warning, you don't use the Emacs built-in version of @value{tramp}. In case you have installed @value{tramp} -from GNU ELPA, you must delete and reinstall it. +from GNU ELPA, see the package README file for instructions how to +recompile it. @ifset installchapter In case you have installed it from its Git repository, @ref{Recompilation}. @end ifset -@item -I get an error @samp{tramp-file-name-handler: Invalid function: -tramp-compat-with-mutex} - -Likely, you have a running Emacs session with loaded @value{tramp}, -and you try to upgrade it to another version from GNU ELPA. Since -@value{tramp} is not forward compatible, you must unload / reload it. -Try the following steps: - -@example -@kbd{M-x tramp-unload-tramp @key{RET}} -@kbd{M-x load-library @key{RET} tramp @key{RET}} -@end example - -If this doesn't work, you must restart Emacs with proper -@code{load-path} for the new @value{tramp} version. - - @item I get an error @samp{Remote file error: Forbidden reentrant call of Tramp} diff --git a/lisp/net/tramp-cmds.el b/lisp/net/tramp-cmds.el index d208f0e044..6342cf5287 100644 --- a/lisp/net/tramp-cmds.el +++ b/lisp/net/tramp-cmds.el @@ -472,6 +472,48 @@ For details, see `tramp-rename-files'." (function-put #'tramp-rename-these-files 'completion-predicate #'tramp-command-completion-p) +;; This function takes action since Emacs 28.1, when +;; `read-extended-command-predicate' is set to +;; `command-completion-default-include-p'. +;;;###tramp-autoload +(defun tramp-recompile-elpa-command-completion-p (_symbol _buffer) + "A predicate for `tramp-recompile-elpa'. +It is completed by \"M-x TAB\" only if package.el is loaded, and +Tramp is an installed ELPA package." + ;; We cannot apply `package-installed-p', this would also return the + ;; builtin package. + (tramp-compat-funcall 'package--user-installed-p 'tramp)) + +;;;###tramp-autoload +(defun tramp-recompile-elpa () + "Recompile the installed Tramp ELPA package. +This is needed if there are compatibility problems." + ;; (declare (completion tramp-recompile-elpa-command-completion-p)) + (interactive) + ;; We expect just one Tramp package is installed. + (when-let + ((dir (tramp-compat-funcall + 'package-desc-dir + (car (alist-get 'tramp (bound-and-true-p package-alist)))))) + (dolist (elc (directory-files dir 'full "\\.elc$")) + (delete-file elc)) + (with-current-buffer (get-buffer-create byte-compile-log-buffer) + (let ((inhibit-read-only t)) + (compilation-mode) + (goto-char (point-max)) + (insert "\f\n") + (call-process + (expand-file-name invocation-name invocation-directory) nil t t + "-Q" "-batch" "-L" dir + "--eval" (format "(byte-recompile-directory %S 0 t)" dir)) + (message "Package `tramp' recompiled."))))) + +;; Starting with Emacs 28.1, this can be replaced by the "(declare ...)" form. +;;;###tramp-autoload +(function-put + #'tramp-recompile-elpa 'completion-predicate + #'tramp-recompile-elpa-command-completion-p) + ;; Tramp version is useful in a number of situations. ;;;###tramp-autoload commit 07bb2cbf5558d3ec048ab02be95060aa6efceff5 Author: Stefan Kangas Date: Mon Apr 19 09:50:13 2021 +0200 Don't hard-code "~/.emacs.d/" in two more places * lisp/gnus/gnus-group.el (gnus-read-ephemeral-bug-group): * lisp/progmodes/js.el (js-js-tmpdir): Don't hard-code "~/.emacs.d/". diff --git a/lisp/gnus/gnus-group.el b/lisp/gnus/gnus-group.el index 423b180408..8c62c9424d 100644 --- a/lisp/gnus/gnus-group.el +++ b/lisp/gnus/gnus-group.el @@ -2462,7 +2462,8 @@ the ephemeral group." (with-temp-file tmpfile (mm-disable-multibyte) (dolist (id ids) - (let ((file (concat "~/.emacs.d/debbugs-cache/" id))) + (let ((file (expand-file-name id (locate-user-emacs-file + "debbugs-cache")))) (if (and (not gnus-plugged) (file-exists-p file)) (insert-file-contents file) diff --git a/lisp/progmodes/js.el b/lisp/progmodes/js.el index eb690a72f6..6d6063d783 100644 --- a/lisp/progmodes/js.el +++ b/lisp/progmodes/js.el @@ -494,10 +494,11 @@ for preventing Firefox from stealing the keyboard focus." :type 'boolean) (defcustom js-js-tmpdir - "~/.emacs.d/js/js" + (locate-user-emacs-file "js/js") "Temporary directory used by `js-mode' to communicate with Mozilla. This directory must be readable and writable by both Mozilla and Emacs." - :type 'directory) + :type 'directory + :version "28.1") (defcustom js-js-timeout 5 "Reply timeout for executing commands in Mozilla via `js-mode'. commit 869e437c10e001c865a4d7e3d79deffb76456539 Author: Philip K Date: Sun Apr 18 20:41:37 2021 +0200 Don't hard-code "~/.emacs.d/" in rcirc.el * lisp/net/rcirc.el (rcirc-log-directory): Use locate-user-emacs-file. (Bug#47880) diff --git a/lisp/net/rcirc.el b/lisp/net/rcirc.el index 7bb8ca671c..7251640bf2 100644 --- a/lisp/net/rcirc.el +++ b/lisp/net/rcirc.el @@ -1166,9 +1166,10 @@ If ALL is non-nil, update prompts in all IRC buffers." (or (eq (aref target 0) ?#) (eq (aref target 0) ?&)))) -(defcustom rcirc-log-directory "~/.emacs.d/rcirc-log" +(defcustom rcirc-log-directory (locate-user-emacs-file "rcirc-log") "Directory to keep IRC logfiles." - :type 'directory) + :type 'directory + :version "28.1") (defcustom rcirc-log-flag nil "Non-nil means log IRC activity to disk. commit 454fd3978203447937a16dd65af21c831f4713e6 Author: Philipp Stephani Date: Sun Apr 18 22:05:59 2021 +0200 ; * test/lisp/progmodes/xref-tests.el: Add footer. diff --git a/test/lisp/progmodes/xref-tests.el b/test/lisp/progmodes/xref-tests.el index c25bbd9477..66099dc110 100644 --- a/test/lisp/progmodes/xref-tests.el +++ b/test/lisp/progmodes/xref-tests.el @@ -156,3 +156,5 @@ (cl-every (lambda (e1 e2) (string-match-p e1 e2)) expected actual))))) + +;;; xref-tests.el ends here commit 652b0f4c7453e6d440fec767336ca85aec13e33d Author: Philipp Stephani Date: Sun Apr 18 21:57:59 2021 +0200 Factor out a helper macro to create a temporary directory. This is a useful abstraction, and saves a few levels of indentation in the test body. * test/lisp/progmodes/project-tests.el (project-tests--with-temporary-directory): New helper macro. (project/quoted-directory): Use it. diff --git a/test/lisp/progmodes/project-tests.el b/test/lisp/progmodes/project-tests.el index bb58f80d18..c8c03aa257 100644 --- a/test/lisp/progmodes/project-tests.el +++ b/test/lisp/progmodes/project-tests.el @@ -27,49 +27,59 @@ (require 'project) +(require 'cl-lib) (require 'ert) (require 'grep) (require 'xref) +(defmacro project-tests--with-temporary-directory (var &rest body) + "Create a new temporary directory. +Bind VAR to the name of the directory, and evaluate BODY. Delete +the directory after BODY exits." + (declare (debug (symbolp body)) (indent 1)) + (cl-check-type var symbol) + (let ((directory (make-symbol "directory"))) + `(let ((,directory (make-temp-file "project-tests-" :directory))) + (unwind-protect + (let ((,var ,directory)) + ,@body) + (delete-directory ,directory :recursive))))) + (ert-deftest project/quoted-directory () "Check that `project-files' and `project-find-regexp' deal with quoted directory names (Bug#47799)." (skip-unless (executable-find find-program)) (skip-unless (executable-find "xargs")) (skip-unless (executable-find "grep")) - (let ((directory (make-temp-file "project-tests-" :directory))) - (unwind-protect - (let ((default-directory directory) - (project-current-inhibit-prompt t) - (project-find-functions nil) - (project-list-file - (expand-file-name "projects" directory)) - (project (cons 'transient (file-name-quote directory))) - (file (expand-file-name "file" directory))) - (add-hook 'project-find-functions (lambda (_dir) project)) - (should (eq (project-current) project)) - (write-region "contents" nil file nil nil nil 'excl) - (should (equal (project-files project) - (list (file-name-quote file)))) - (let* ((references nil) - (xref-search-program 'grep) - (xref-show-xrefs-function - (lambda (fetcher _display) - (push (funcall fetcher) references)))) - (project-find-regexp "tent") - (pcase references - (`((,item)) - (should - ;; FIXME: Shouldn't `xref-match-item' be a subclass of - ;; `xref-item'? - (cl-typep item '(or xref-item xref-match-item))) - (should - (file-equal-p - (xref-location-group (xref-item-location item)) - file))) - (otherwise - (ert-fail (format-message "Unexpected references: %S" - otherwise)))))) - (delete-directory directory :recursive)))) + (project-tests--with-temporary-directory directory + (let ((default-directory directory) + (project-current-inhibit-prompt t) + (project-find-functions nil) + (project-list-file + (expand-file-name "projects" directory)) + (project (cons 'transient (file-name-quote directory))) + (file (expand-file-name "file" directory))) + (add-hook 'project-find-functions (lambda (_dir) project)) + (should (eq (project-current) project)) + (write-region "contents" nil file nil nil nil 'excl) + (should (equal (project-files project) + (list (file-name-quote file)))) + (let* ((references nil) + (xref-search-program 'grep) + (xref-show-xrefs-function + (lambda (fetcher _display) + (push (funcall fetcher) references)))) + (project-find-regexp "tent") + (pcase references + (`((,item)) + ;; FIXME: Shouldn't `xref-match-item' be a subclass of + ;; `xref-item'? + (should (cl-typep item '(or xref-item xref-match-item))) + (should (file-equal-p + (xref-location-group (xref-item-location item)) + file))) + (otherwise + (ert-fail (format-message "Unexpected references: %S" + otherwise)))))))) ;;; project-tests.el ends here commit 6ebc6e12cfa8909655e3c0e722d3c5727ea418d8 Author: Philipp Stephani Date: Sun Apr 18 21:47:53 2021 +0200 Add quoted filename support to 'project-find-regexp' (Bug#47799). This is only a band-aid; it would be better to fix xref.el to work with quoted filenames as well. * lisp/progmodes/project.el (project--find-regexp-in-files): Unquote filenames before passing them to 'xref-matches-in-files'. * test/lisp/progmodes/project-tests.el (project/quoted-directory): Also test 'project-find-regexp'. diff --git a/lisp/progmodes/project.el b/lisp/progmodes/project.el index 1023b75e66..1d0d1bc58a 100644 --- a/lisp/progmodes/project.el +++ b/lisp/progmodes/project.el @@ -787,7 +787,11 @@ pattern to search for." (defun project--find-regexp-in-files (regexp files) (unless files (user-error "Empty file list")) - (let ((xrefs (xref-matches-in-files regexp files))) + (let ((xrefs (xref-matches-in-files + regexp + ;; FIXME: `xref-matches-in-files' should work with + ;; quoted filenames. + (mapcar #'file-name-unquote files)))) (unless xrefs (user-error "No matches for: %s" regexp)) xrefs)) diff --git a/test/lisp/progmodes/project-tests.el b/test/lisp/progmodes/project-tests.el index 829f52adec..bb58f80d18 100644 --- a/test/lisp/progmodes/project-tests.el +++ b/test/lisp/progmodes/project-tests.el @@ -28,11 +28,15 @@ (require 'project) (require 'ert) +(require 'grep) +(require 'xref) (ert-deftest project/quoted-directory () - "Check that `project-files' deals with quoted directory -names (Bug#47799)." + "Check that `project-files' and `project-find-regexp' deal with +quoted directory names (Bug#47799)." (skip-unless (executable-find find-program)) + (skip-unless (executable-find "xargs")) + (skip-unless (executable-find "grep")) (let ((directory (make-temp-file "project-tests-" :directory))) (unwind-protect (let ((default-directory directory) @@ -42,11 +46,30 @@ names (Bug#47799)." (expand-file-name "projects" directory)) (project (cons 'transient (file-name-quote directory))) (file (expand-file-name "file" directory))) - (make-empty-file file) (add-hook 'project-find-functions (lambda (_dir) project)) (should (eq (project-current) project)) + (write-region "contents" nil file nil nil nil 'excl) (should (equal (project-files project) - (list (file-name-quote file))))) + (list (file-name-quote file)))) + (let* ((references nil) + (xref-search-program 'grep) + (xref-show-xrefs-function + (lambda (fetcher _display) + (push (funcall fetcher) references)))) + (project-find-regexp "tent") + (pcase references + (`((,item)) + (should + ;; FIXME: Shouldn't `xref-match-item' be a subclass of + ;; `xref-item'? + (cl-typep item '(or xref-item xref-match-item))) + (should + (file-equal-p + (xref-location-group (xref-item-location item)) + file))) + (otherwise + (ert-fail (format-message "Unexpected references: %S" + otherwise)))))) (delete-directory directory :recursive)))) ;;; project-tests.el ends here commit 55b22bff6d5fc573c2d1e5b05faa12bed5ee4156 Author: Philipp Stephani Date: Sun Apr 18 21:46:10 2021 +0200 Extend project test so that 'project-current' works. * test/lisp/progmodes/project-tests.el (project/quoted-directory): Verify that 'project-current' returns the right project. diff --git a/test/lisp/progmodes/project-tests.el b/test/lisp/progmodes/project-tests.el index 6e71948477..829f52adec 100644 --- a/test/lisp/progmodes/project-tests.el +++ b/test/lisp/progmodes/project-tests.el @@ -35,9 +35,16 @@ names (Bug#47799)." (skip-unless (executable-find find-program)) (let ((directory (make-temp-file "project-tests-" :directory))) (unwind-protect - (let ((project (cons 'transient (file-name-quote directory))) + (let ((default-directory directory) + (project-current-inhibit-prompt t) + (project-find-functions nil) + (project-list-file + (expand-file-name "projects" directory)) + (project (cons 'transient (file-name-quote directory))) (file (expand-file-name "file" directory))) (make-empty-file file) + (add-hook 'project-find-functions (lambda (_dir) project)) + (should (eq (project-current) project)) (should (equal (project-files project) (list (file-name-quote file))))) (delete-directory directory :recursive)))) commit d91e1a5701860b39ccf7fb081a48d90c450ab283 Author: Philipp Stephani Date: Sun Apr 18 21:43:17 2021 +0200 Skip a unit test that requires an external program if necessary. * test/lisp/progmodes/project-tests.el (project/quoted-directory): Skip if the 'find' program isn't available. The 'project-files' function uses 'find' to obtain the list of project files. diff --git a/test/lisp/progmodes/project-tests.el b/test/lisp/progmodes/project-tests.el index 23e68541b3..6e71948477 100644 --- a/test/lisp/progmodes/project-tests.el +++ b/test/lisp/progmodes/project-tests.el @@ -32,6 +32,7 @@ (ert-deftest project/quoted-directory () "Check that `project-files' deals with quoted directory names (Bug#47799)." + (skip-unless (executable-find find-program)) (let ((directory (make-temp-file "project-tests-" :directory))) (unwind-protect (let ((project (cons 'transient (file-name-quote directory))) commit dc9b0dc4616e63fb0e30a4fd79ffc196ebcac73b Author: Protesilaos Stavrou Date: Sun Apr 18 06:30:12 2021 +0300 Update modus-themes to version 1.3.2 * doc/misc/modus-themes.org (COPYING): Reword to match the phrasing of other manuals that are distributed with Emacs. (Install from the archives) (Sample configuration for use-package) (Option for more bold constructs) (Option for more slanted constructs) (Option for syntax highlighting) (Option for no font mixing) (Option for links) (Option for command prompt styles) (Option for completion framework aesthetics) (Option for fringe visibility) (Option for language checkers) (Option for org-habit graph styles) (Option for line numbers (display-line-numbers-mode)) (Option for parenthesis matching (show-paren-mode)) (Option for diff buffer looks) (Option for scaled headings) (Option for variable-pitch font in UI elements) (Option for variable-pitch font in headings) (Case-by-case face specs using the themes' palette (DIY)) (Face specs at scale using the themes' palette (DIY)) (Font configurations for Org and others (DIY)) (Load theme depending on time of day): Minor markup changes for better texi output. (Option for mode line presentation): Document new possible values for 'modus-themes-mode-line'. (Option for line highlighting (hl-line-mode)): Document new 'modus-themes-hl-line' variable, which supersedes 'modus-themes-intense-hl-line'. (Option for active region): Document new possible values for 'modus-themes-region'. (Option for org-mode block styles): Cite variables that affect fontification. (Option for the headings' overall style): Include the option of a per-level nil value. (Remap face with local value (DIY)) (Override colors (DIY)): Add sections. (Full support for packages or face groups): Document newly supported packages (Note for dimmer.el) (Note for EWW and Elfeed fonts (SHR fonts)): Add notes. (Acknowledgements): Add names of new contributors. (GNU Free Documentation License): Add tags for html export. * etc/themes/modus-operandi-theme.el (File) * etc/themes/modus-vivendi-theme.el (File): Update to version 1.3.1 * etc/themes/modus-themes.el (modus-themes-operandi-colors) (modus-themes-vivendi-colors) (modus-theme-subtle-red) (modus-themes-subtle-red) (modus-theme-subtle-green) (modus-themes-subtle-green) (modus-theme-subtle-yellow) (modus-themes-subtle-yellow) (modus-theme-subtle-blue) (modus-themes-subtle-blue) (modus-theme-subtle-magenta) (modus-themes-subtle-magenta) (modus-theme-subtle-cyan) (modus-themes-subtle-cyan) (modus-theme-subtle-neutral) (modus-themes-subtle-neutral) (modus-theme-intense-red) (modus-themes-intense-red) (modus-theme-intense-green) (modus-themes-intense-green) (modus-theme-intense-yellow) (modus-themes-intense-yellow) (modus-theme-intense-blue) (modus-themes-intense-blue) (modus-theme-intense-magenta) (modus-themes-intense-magenta) (modus-theme-intense-cyan) (modus-themes-intense-cyan) (modus-theme-intense-neutral) (modus-themes-intense-neutral) (modus-theme-refine-red) (modus-themes-refine-red) (modus-theme-refine-green) (modus-themes-refine-green) (modus-theme-refine-yellow) (modus-themes-refine-yellow) (modus-theme-refine-blue) (modus-themes-refine-blue) (modus-theme-refine-magenta) (modus-themes-refine-magenta) (modus-theme-refine-cyan) (modus-themes-refine-cyan) (modus-theme-active-red) (modus-themes-active-red) (modus-theme-active-green) (modus-themes-active-green) (modus-theme-active-yellow) (modus-themes-active-yellow) (modus-theme-active-blue) (modus-themes-active-blue) (modus-theme-active-magenta) (modus-themes-active-magenta) (modus-theme-active-cyan) (modus-themes-active-cyan) (modus-theme-fringe-red) (modus-themes-fringe-red) (modus-theme-fringe-green) (modus-themes-fringe-green) (modus-theme-fringe-yellow) (modus-themes-fringe-yellow) (modus-theme-fringe-blue) (modus-themes-fringe-blue) (modus-theme-fringe-magenta) (modus-themes-fringe-magenta) (modus-theme-fringe-cyan) (modus-themes-fringe-cyan) (modus-theme-nuanced-red) (modus-theme-nuanced-green) (modus-theme-nuanced-yellow) (modus-theme-nuanced-blue) (modus-theme-nuanced-magenta) (modus-theme-nuanced-cyan) (modus-theme-special-cold) (modus-theme-special-mild) (modus-theme-special-warm) (modus-theme-special-calm) (modus-theme-diff-added) (modus-theme-diff-changed) (modus-theme-diff-removed) (modus-theme-diff-refine-added) (modus-theme-diff-refine-changed) (modus-theme-diff-refine-removed) (modus-theme-diff-focus-added) (modus-theme-diff-focus-changed) (modus-theme-diff-focus-removed) (modus-theme-diff-heading) (modus-theme-pseudo-header) (modus-theme-mark-alt) (modus-theme-mark-del) (modus-theme-mark-sel) (modus-theme-mark-symbol) (modus-theme-heading-1) (modus-theme-heading-2) (modus-theme-heading-3) (modus-theme-heading-4) (modus-theme-heading-5) (modus-theme-heading-6) (modus-theme-heading-7) (modus-theme-heading-8) (modus-theme-hl-line) (modus-theme-bold) (modus-theme-slant) (modus-theme-variable-pitch) (modus-theme-graph-red-0) (modus-theme-graph-red-1) (modus-theme-graph-green-0) (modus-theme-graph-green-1) (modus-theme-graph-yellow-0) (modus-theme-graph-yellow-1) (modus-theme-graph-blue-0) (modus-theme-graph-blue-1) (modus-theme-graph-magenta-0) (modus-theme-graph-magenta-1) (modus-theme-graph-cyan-0) (modus-theme-graph-cyan-1) (modus-theme-lang-note) (modus-theme-lang-warning) (modus-theme-lang-error): Rename all internal faces. (modus-themes-headings) (modus-themes-fringes) (modus-themes-lang-checkers) (modus-themes-org-blocks) (modus-themes-org-habit) (modus-themes-mode-line) (modus-themes-diffs) (modus-themes-completions) (modus-themes-prompts) (modus-themes-intense-hl-line) (modus-themes-hl-line) (modus-themes-paren-match) (modus-themes-syntax) (modus-themes-links) (modus-themes-region): Update defcustom. (modus-themes--fringe): (modus-themes--headings-choice): (modus-themes--prompt): (modus-themes--org-block-delim): (modus-themes--mode-line-attrs): (modus-themes--link): (modus-themes--region): (modus-themes--hl-line): Adjustments to internal functions. (modus-themes-faces): Update faces. (modus-themes-custom-variables): Update custom variables. diff --git a/doc/misc/modus-themes.org b/doc/misc/modus-themes.org index 9764a3467f..001ed57218 100644 --- a/doc/misc/modus-themes.org +++ b/doc/misc/modus-themes.org @@ -4,9 +4,9 @@ #+language: en #+options: ':t toc:nil author:t email:t -#+macro: stable-version 1.2.3 -#+macro: release-date 2021-03-05 -#+macro: development-version 1.3.0-dev +#+macro: stable-version 1.3.2 +#+macro: release-date 2021-04-18 +#+macro: development-version 1.4.0-dev #+macro: export-date (eval (format-time-string "%F %R %z" (current-time))) #+macro: file @@texinfo:@file{@@$1@@texinfo:}@@ #+macro: space @@texinfo:@: @@ @@ -46,11 +46,15 @@ built on {{{export-date}}}. Copyright (C) 2020-2021 Free Software Foundation, Inc. #+begin_quote -Permission is granted to copy, distribute and/or modify this -document under the terms of the GNU Free Documentation License, -Version 1.3 or any later version published by the Free Software -Foundation; with no Invariant Sections, with no Front-Cover Texts, -and with no Back-Cover Texts. +Permission is granted to copy, distribute and/or modify this document +under the terms of the GNU Free Documentation License, Version 1.3 or +any later version published by the Free Software Foundation; with no +Invariant Sections, with the Front-Cover Texts being “A GNU Manual,” and +with the Back-Cover Texts as in (a) below. A copy of the license is +included in the section entitled “GNU Free Documentation License.” + +(a) The FSF’s Back-Cover Text is: “You have the freedom to copy and +modify this GNU manual.” #+end_quote * Overview @@ -141,7 +145,7 @@ The themes are now ready to be used: [[#h:3f3c3728-1b34-437d-9d0c-b110f5b161a9][ :custom_id: h:c4b10085-149f-43e2-bd4d-347f33aee054 :end: -The =modus-themes= package is available from the GNU ELPA archive, which +The ~modus-themes~ package is available from the GNU ELPA archive, which is configured by default. Prior to querying any package archive, make sure to have updated the @@ -287,7 +291,8 @@ package configurations in their setup. We use this as an example: :init ;; Add all your customizations prior to loading the themes (setq modus-themes-slanted-constructs t - modus-themes-bold-constructs nil) + modus-themes-bold-constructs nil + modus-themes-region 'no-extend) ;; Load the theme files before enabling a theme (else you get an error). (modus-themes-load-themes) @@ -374,13 +379,13 @@ Symbol: ~modus-themes-bold-constructs~ Possible values: -1. =nil= (default) -2. =t= +1. ~nil~ (default) +2. ~t~ The default is to use a bold typographic weight only when it is required. -With a non-nil value (=t=) display several syntactic constructs in bold +With a non-nil value (~t~) display several syntactic constructs in bold weight. This concerns keywords and other important aspects of code syntax. It also affects certain mode line indicators and command-line prompts. @@ -397,13 +402,13 @@ Symbol: ~modus-themes-slanted-constructs~ Possible values: -1. =nil= (default) -2. =t= +1. ~nil~ (default) +2. ~t~ The default is to not use slanted text (italics) unless it is absolutely necessary. -With a non-nil value (=t=) choose to render more faces in slanted text. +With a non-nil value (~t~) choose to render more faces in slanted text. This typically affects documentation strings and code comments. ** Option for syntax highlighting @@ -418,7 +423,7 @@ Symbol: ~modus-themes-syntax~ Possible values: -1. =nil= (default) +1. ~nil~ (default) 2. ~faint~ 3. ~yellow-comments~ 4. ~green-strings~ @@ -467,8 +472,8 @@ Symbol: ~modus-themes-no-mixed-fonts~ Possible values: -1. =nil= (default) -2. =t= +1. ~nil~ (default) +2. ~t~ By default, the themes configure some spacing-sensitive faces like Org tables and code blocks to always inherit from the ~fixed-pitch~ face. @@ -476,14 +481,14 @@ This is to ensure that those constructs remain monospaced even when users opt for a mode that remaps typeface families, such as the built-in {{{kbd(M-x variable-pitch-mode)}}}. Otherwise the layout would appear broken, due to how spacing is done. To disable this behaviour, set the -option to =t=. +option to ~t~. Users may prefer to use another package for handling mixed typeface configurations, rather than letting the theme do it, perhaps because a purpose-specific package has extra functionality. Two possible options are ~org-variable-pitch~ and ~mixed-pitch~. -[[#h:defcf4fc-8fa8-4c29-b12e-7119582cc929][Font configurations for Org (and others)]]. +[[#h:defcf4fc-8fa8-4c29-b12e-7119582cc929][Font configurations for Org and others]]. ** Option for links :properties: @@ -497,7 +502,7 @@ Symbol: ~modus-themes-links~ Possible values: -1. =nil= (default) +1. ~nil~ (default) 2. ~faint~ 3. ~neutral-underline~ 4. ~faint-neutral-underline~ @@ -545,7 +550,7 @@ Symbol: ~modus-themes-prompts~ Possible values: -1. =nil= (default) +1. ~nil~ (default) 2. ~subtle-accented~ (~subtle~ exists for backward compatibility) 3. ~intense-accented~ (~intense~ exists for backward compatibility) 4. ~subtle-gray~ @@ -577,12 +582,15 @@ Symbol: ~modus-themes-mode-line~ Possible values: -1. =nil= (default) +1. ~nil~ (default) 2. ~3d~ 3. ~moody~ 4. ~borderless~ 5. ~borderless-3d~ 6. ~borderless-moody~ +7. ~accented~ +8. ~accented-3d~ +9. ~accented-moody~ The default produces a two-dimensional effect both for the active and inactive modelines. The differences between the two are limited to @@ -612,6 +620,11 @@ that the inactive modelines remain visible, they apply a slightly more prominent background to them than what their counterparts do (same inactive background as with the default). +Similarly, ~accented~, ~accented-3d~, and ~accented-moody~ correspond to the +default (~nil~), ~3d~, and ~moody~ styles respectively, except that the active +mode line uses a colored background instead of the standard shade of +gray. + Note that Moody does not expose any faces that the themes could style directly. Instead it re-purposes existing ones to render its tabs and ribbons. As such, there may be cases where the contrast ratio falls @@ -624,10 +637,11 @@ is activated when Emacs determines that the background and foreground of the given construct are too close to each other in terms of color distance. In effect, users would need to experiment with the variable ~face-near-same-color-threshold~ to trigger the effect. We find that a -value of =45000= will suffice, contrary to the default =30000=. Do not set -the value too high, because that would have the adverse effect of always -overriding the default color (which has been carefully designed to be -highly accessible). +value of =45000= will suffice, contrary to the default =30000=. Though for +the ~accented-moody~ value mentioned above, that should be raised up to +=70000=. Do not set it too high, because it has the adverse effect of +always overriding the default colors (which have been carefully designed +to be highly accessible). Furthermore, because Moody expects an underline and overline instead of a box style, it is advised you include this in your setup: @@ -648,7 +662,7 @@ Symbol: ~modus-themes-completions~ Possible values: -1. =nil= (default) +1. ~nil~ (default) 2. ~moderate~ 3. ~opinionated~ @@ -661,7 +675,7 @@ The former category encompasses Icomplete, Ido, Selectrum as well as pattern matching styles like Orderless and Flx. The latter covers Helm, Ivy, and similar. -A value of =nil= will respect the metaphors of each completion framework. +A value of ~nil~ will respect the metaphors of each completion framework. Option ~moderate~ applies a combination of background and foreground that is fairly subtle. For Icomplete and friends this constitutes a @@ -677,7 +691,7 @@ packages will revert to an even more nuanced aesthetic with some additional changes to the choice of hues. To appreciate the scope of this customization option, you should spend -some time with every one of the =nil= (default), ~moderate~, and ~opinionated~ +some time with every one of the ~nil~ (default), ~moderate~, and ~opinionated~ possibilities. ** Option for fringe visibility @@ -692,7 +706,7 @@ Symbol: ~modus-themes-fringes~ Possible values: -1. =nil= (default) +1. ~nil~ (default) 2. ~subtle~ 3. ~intense~ @@ -716,7 +730,7 @@ Symbol: ~modus-themes-lang-checkers~ Possible values: -1. =nil= (default) +1. ~nil~ (default) 2. ~subtle-foreground~ 3. ~intense-foreground~ 4. ~straight-underline~ @@ -755,25 +769,50 @@ refer to their documentation strings. ** Option for line highlighting (hl-line-mode) :properties: :alt_title: Line highlighting -:description: Toggle intense style for current line highlighting +:description: Choose style of current line (hl-line-mode) :custom_id: h:1dba1cfe-d079-4c13-a810-f768e8789177 :end: -#+vindex: modus-themes-intense-hl-line +#+vindex: modus-themes-hl-line -Symbol: ~modus-themes-intense-hl-line~ +Symbol: ~modus-themes-hl-line~ Possible values: -1. =nil= (default) -2. =t= +1. ~nil~ (default) +2. ~intense-background~ +3. ~accented-background~ +4. ~underline-neutral~ +5. ~underline-accented~ +6. ~underline-only-neutral~ +7. ~underline-only-accented~ + +The default is to use a subtle gray background for the current line when +~hl-line-mode~ is enabled. + +The ~intense-background~ applies a more prominent gray to the background +of the current line. + +With ~accented-background~ the default's subtle aesthetic is retained, but +the background has a more colored hint. + +The ~underline-neutral~ combines the default subtle neutral background +with a gray underline. -The default is to use a subtle gray background for ~hl-line-mode~ and its -global equivalent. +Similarly, the ~underline-accented~ renders the background of the current +line in a subtle colored background, while it also draws an accented +underline. -With a non-nil value (=t=) use a more prominent background color instead. +Option ~underline-only-neutral~ produces a neutral underline, but does not +use any background. -This affects several packages that enable ~hl-line-mode~, such as =elfeed= -and =mu4e=. +While ~underline-only-accented~ also uses just an underline, only this one +is colored. + +Consider setting the variable ~x-underline-at-descent-line~ to a non-nil +value for better results with underlines. + +This style affects several packages that enable ~hl-line-mode~, such as +=elfeed= and =mu4e=. ** Option for line numbers (display-line-numbers-mode) :properties: @@ -787,8 +826,8 @@ Symbol: ~modus-themes-subtle-line-numbers~ Possible value: -1. =nil= (default) -2. =t= +1. ~nil~ (default) +2. ~t~ The default style for ~display-line-numbers-mode~ and its global variant is to apply a subtle gray background to the line numbers. The current @@ -799,7 +838,7 @@ Similarly, the faces for ~display-line-numbers-major-tick~ and its counterpart ~display-line-numbers-minor-tick~ use appropriate styles that involve a bespoke background and foreground combination. -With a non-nil value (=t=), line numbers have no background of their own. +With a non-nil value (~t~), line numbers have no background of their own. Instead they retain the primary background of the theme, blending with the rest of the buffer. Foreground values for all relevant faces are updated to accommodate this aesthetic. @@ -816,7 +855,7 @@ Symbol: ~modus-themes-paren-match~ Possible values: -1. =nil= (default) +1. ~nil~ (default) 2. ~subtle-bold~ 3. ~intense~ 4. ~intense-bold~ @@ -847,10 +886,12 @@ Symbol: ~modus-themes-region~ Possible values: -1. =nil= (default) +1. ~nil~ (default) 2. ~no-extend~ 3. ~bg-only~ 4. ~bg-only-no-extend~ +5. ~accent~ +6. ~accent-no-extend~ Nil means to only use a prominent gray background with a neutral foreground. The foreground overrides all syntax highlighting. The @@ -866,6 +907,11 @@ colors. It extends to the edge of the window. Option ~bg-only-no-extend~ is a combination of the ~bg-only~ and ~no-extend~ options. +Option ~accent~ is like the default, though it uses a more colorful +background, while ~accent-no-extend~ is the same except it draws the +region only up to the end of each line instead of extending to the edge +of the window. + ** Option for diff buffer looks :properties: :alt_title: Diffs @@ -878,7 +924,7 @@ Symbol: ~modus-themes-diffs~ Possible values: -1. =nil= (default) +1. ~nil~ (default) 2. ~desaturated~ 3. ~fg-only~ 4. ~bg-only~ @@ -935,7 +981,7 @@ Symbol: ~modus-themes-org-blocks~ Possible values: -1. =nil= (default) +1. ~nil~ (default) 2. ~grayscale~ 3. ~rainbow~ @@ -960,6 +1006,9 @@ major-mode so that the colors are applied consistently throughout: use Or start typing in each code block (inefficient at scale, but it still works). +The extent of Org block delimiter lines is controlled by the variable +~org-fontify-whole-block-delimiter-line~. + ** Option for org-habit graph styles :properties: :alt_title: Org agenda habits @@ -972,7 +1021,7 @@ Symbol: ~modus-themes-org-habit~ Possible values: -1. =nil= (default) +1. ~nil~ (default) 2. ~simplified~ 3. ~traffic-light~ @@ -1014,11 +1063,10 @@ than other customization options documented in this manual. Symbol: ~modus-themes-headings~ -Possible values, which can be specified for each heading level (examples -further below): +Possible values, which can be specified for each heading level N +(examples further below): -+ nil (default fallback option---covers all heading levels) -+ =t= (default style for a single heading, when the fallback differs) ++ ~nil~ (~t~ is also available for backward compatibility) + ~no-bold~ + ~line~ + ~line-no-bold~ @@ -1058,19 +1106,19 @@ To set a uniform value for all heading levels, use this pattern: '((t . section))) ;; Default aesthetic for every heading -(setq modus-themes-headings - '()) +(setq modus-themes-headings nil) #+end_src The default style for headings uses a fairly desaturated foreground -value in combination with bold typographic weight. To specify this +color in combination with bold typographic weight. To specify this style for a given level N, assuming you wish to have another fallback -option, just specify the value =t= like this: +option, just assign the value ~nil~ like this: #+begin_src emacs-lisp (setq modus-themes-headings - '((1 . t) + '((1 . nil) (2 . line) + (3) ; same as nil (t . rainbow-line-no-bold))) #+end_src @@ -1122,6 +1170,9 @@ A description of all other possible styles beyond the default: + ~no-color-no-bold~ is like ~no-color~ but without the bold weight. +Remember to also inspect relevant variables that Org provides, such as: +~org-fontify-whole-heading-line~ and ~org-fontify-done-headline~. + ** Option for scaled headings :properties: :alt_title: Scaled headings @@ -1134,12 +1185,12 @@ Symbol: ~modus-themes-scale-headings~ Possible values: -1. =nil= (default) -2. =t= +1. ~nil~ (default) +2. ~t~ The default is to use the same size for headings and paragraph text. -With a non-nil value (=t=) make headings larger in height relative to the +With a non-nil value (~t~) make headings larger in height relative to the main text. This is noticeable in modes like Org, Markdown, and Info. *** Control the scale of headings @@ -1217,8 +1268,8 @@ Symbol: ~modus-themes-variable-pitch-ui~ Possible values: -1. =nil= (default) -2. =t= +1. ~nil~ (default) +2. ~t~ This option concerns User Interface elements that are under the direct control of Emacs. In particular: the mode line, header line, tab bar, @@ -1227,7 +1278,7 @@ and tab line. The default is to use the same font as the rest of Emacs, which usually is a monospaced family. -With a non-nil value (=t=) apply a proportionately spaced typeface. This +With a non-nil value (~t~) apply a proportionately spaced typeface. This is done by assigning the ~variable-pitch~ face to the relevant items. [[#h:defcf4fc-8fa8-4c29-b12e-7119582cc929][Font configurations for Org and others]]. @@ -1244,13 +1295,13 @@ Symbol: ~modus-themes-variable-pitch-headings~ Possible values: -1. =nil= (default) -2. =t= +1. ~nil~ (default) +2. ~t~ The default is to use the main font family, which typically is monospaced. -With a non-nil value (=t=) apply a proportionately spaced typeface, else +With a non-nil value (~t~) apply a proportionately spaced typeface, else "variable-pitch", to headings (such as in Org mode). [[#h:defcf4fc-8fa8-4c29-b12e-7119582cc929][Font configurations for Org and others]]. @@ -1357,7 +1408,7 @@ With that granted, let us expand the example to actually change the If you evaluate this form, your cursor will become blue. But if you change themes, such as with ~modus-themes-toggle~, your edits will be -lost, because the newly loaded theme will override the =:background= +lost, because the newly loaded theme will override the ~:background~ attribute you had assigned to that face. For such changes to persist, we need to make them after loading the @@ -1458,7 +1509,7 @@ Getting a list of colors may have its applications, though what you are most likely interested in is how to use those variables to configure several faces at once. To do so we can rely on the built-in ~custom-set-faces~ function, which sets face specifications for the -special =user= theme. That "theme" gets applied on top of regular themes +special ~user~ theme. That "theme" gets applied on top of regular themes like ~modus-operandi~ and ~modus-vivendi~. This is how it works: @@ -1502,7 +1553,7 @@ Thus: [[#h:86f6906b-f090-46cc-9816-1fe8aeb38776][A theme-agnostic hook for theme loading]]. To discover the faces defined by all loaded libraries, you may do -{{{kbd(M-x list-faces-display)}}}. Be warned that when you =:inherit= a face +{{{kbd(M-x list-faces-display)}}}. Be warned that when you ~:inherit~ a face you are introducing an implicit dependency, so try to avoid doing so for libraries other than the built-in {{{file(faces.el)}}} (or at least understand that things may break if you inherit from a yet-to-be-loaded face). @@ -1524,6 +1575,68 @@ the previous section. Adapt the above example like this: ...)) #+end_src +** Remap face with local value (DIY) +:properties: +:custom_id: h:7a93cb6f-4eca-4d56-a85c-9dcd813d6b0f +:end: +#+cindex: Remapping faces + +There are cases where we need to change the buffer-local attributes of a +face. This might be because we have our own minor mode that re-uses a +face for a particular purpose, such as a line selection tool that +activates ~hl-line-mode~, but we wish to keep it distinct from other +buffers. This is where ~face-remap-add-relative~ can be applied and may +be combined with ~modus-themes-with-colors~ to deliver consistent results. + +[[#h:51ba3547-b8c8-40d6-ba5a-4586477fd4ae][Face specs at scale using the themes' palette (DIY)]]. + +In this example we will write a simple interactive function that adjusts +the background color of the ~region~ face. This is the sample code: + +#+begin_src emacs-lisp +(defvar my-rainbow-region-colors + (modus-themes-with-colors + `((red . ,red-subtle-bg) + (green . ,green-subtle-bg) + (yellow . ,yellow-subtle-bg) + (blue . ,blue-subtle-bg) + (magenta . ,magenta-subtle-bg) + (cyan . ,cyan-subtle-bg))) + "Sample list of color values for `my-rainbow-region'.") + +(defun my-rainbow-region (color) + "Remap buffer-local attribute of `region' using COLOR." + (interactive + (list + (completing-read "Pick a color: " my-rainbow-region-colors))) + (face-remap-add-relative + 'region + `( :background ,(alist-get (intern color) my-rainbow-region-colors) + :foreground ,(face-attribute 'default :foreground)))) +#+end_src + +When ~my-rainbow-region~ is called interactively, it prompts for a color +to use. The list of candidates is drawn from the car of each +association in ~my-rainbow-region-colors~ (so "red", "green", etc.). + +To extend this principle, we may write wrapper functions that pass a +color directly. Those can be useful in tandem with hooks. Consider +this example: + +#+begin_src emacs-lisp +(defun my-rainbow-region-magenta () + (my-rainbow-region 'magenta)) + +(add-hook 'diff-mode-hook #'my-rainbow-region-magenta) +#+end_src + +Whenever we enter a ~diff-mode~ buffer, we now get a magenta-colored +region. + +Perhaps you may wish to generalise those findings in to a set of +functions that also accept an arbitrary face. We shall leave the +experimentation up to you. + ** Override colors (DIY) :properties: :custom_id: h:307d95dd-8dbd-4ece-a543-10ae86f155a6 @@ -1627,16 +1740,89 @@ with {{{kbd(M-x modus-themes-toggle)}}} will also use the overrides. Given that this is a user-level customisation, one is free to implement whatever color values they desire, even if the possible combinations fall below the minimum 7:1 contrast ratio that governs the design of the -themes (the WCAG AAA legibility standard). Preferences aside, it is -advised to inspect the source code of ~modus-themes-operandi-colors~ and -~modus-themes-vivendi-colors~ to read the inline commentary: it explains -what the intended use of each palette subset is. +themes (the WCAG AAA legibility standard). Alternatively, this can also +be done programmatically ([[#h:4589acdc-2505-41fc-9f5e-699cfc45ab00][Override color saturation]]). + +For manual interventions it is advised to inspect the source code of +~modus-themes-operandi-colors~ and ~modus-themes-vivendi-colors~ for the +inline commentary: it explains what the intended use of each palette +subset is. Furthermore, users may benefit from the ~modus-themes-contrast~ function that we provide: [[#h:02e25930-e71a-493d-828a-8907fc80f874][test color combinations]]. It measures the contrast ratio between two color values, so it can help in overriding the palette (or a subset thereof) without making the end result inaccessible. +** Override color saturation (DIY) +:properties: +:custom_id: h:4589acdc-2505-41fc-9f5e-699cfc45ab00 +:end: +#+cindex: Change a theme's color saturation + +In the previous section we documented how one can override color values +manually ([[#h:307d95dd-8dbd-4ece-a543-10ae86f155a6][Override colors]]). Here we use a programmatic approach which +leverages the built-in ~color-saturate-name~ function to adjust the +saturation of all color values used by the active Modus theme. Our goal +is to prepare a counterpart of the active theme's palette that holds +modified color values, adjusted for a percent change in saturation. A +positive number amplifies the effect, while a negative one will move +towards a grayscale spectrum. + +We start with a function that can be either called from Lisp or invoked +interactively. In the former scenario, we pass to it the rate of change +we want. While in the latter, a minibuffer prompt asks for a number to +apply the desired effect. In either case, we intend to assign anew the +value of ~modus-themes-operandi-color-overrides~ (light theme) and the +same for ~modus-themes-vivendi-color-overrides~ (dark theme). + +#+begin_src emacs-lisp +(defun my-modus-themes-saturate (percent) + "Saturate current Modus theme palette overrides by PERCENT." + (interactive + (list (read-number "Saturation by percent: "))) + (let* ((theme (modus-themes--current-theme)) + (palette (pcase theme + ('modus-operandi modus-themes-operandi-colors) + ('modus-vivendi modus-themes-vivendi-colors) + (_ (error "No Modus theme is active")))) + (overrides (pcase theme + ('modus-operandi 'modus-themes-operandi-color-overrides) + ('modus-vivendi 'modus-themes-vivendi-color-overrides) + (_ (error "No Modus theme is active"))))) + (let (name cons colors) + (dolist (cons palette) + (setq name (color-saturate-name (cdr cons) percent)) + (setq name (format "%s" name)) + (setq cons `(,(car cons) . ,name)) + (push cons colors)) + (set overrides colors)) + (pcase theme + ('modus-operandi (modus-themes-load-operandi)) + ('modus-vivendi (modus-themes-load-vivendi))))) + +;; sample Elisp calls (or call `my-modus-themes-saturate' interactively) +(my-modus-themes-saturate 50) +(my-modus-themes-saturate -75) +#+end_src + +Using the above has an immediate effect, as it reloads the active Modus +theme. + +To disable the effect, one must reset the aforementioned variables to +~nil~. Or specify a command for it, such as by taking inspiration from +the ~modus-themes-toggle~ we already provide: + +#+begin_src emacs-lisp +(defun my-modus-themes-revert-overrides () + "Reset palette overrides and reload active Modus theme." + (interactive) + (setq modus-themes-operandi-color-overrides nil + modus-themes-vivendi-color-overrides nil) + (pcase (modus-themes--current-theme) + ('modus-operandi (modus-themes-load-operandi)) + ('modus-vivendi (modus-themes-load-vivendi)))) +#+end_src + ** Font configurations for Org and others (DIY) :properties: :custom_id: h:defcf4fc-8fa8-4c29-b12e-7119582cc929 @@ -1677,9 +1863,9 @@ reading the doc string of ~set-face-attribute~): (set-face-attribute 'fixed-pitch nil :family "DejaVu Sans Mono" :height 1.0) #+end_src -Note the differences in the =:height= property. The =default= face must +Note the differences in the ~:height~ property. The ~default~ face must specify an absolute value, which is the point size × 10. So if you want -to use a font at point size =11=, you set the height to =110=.[fn:: =:height= +to use a font at point size =11=, you set the height to =110=.[fn:: ~:height~ values do not need to be rounded to multiples of ten: the likes of =115= are perfectly valid—some typefaces will change to account for those finer increments.] Whereas every other face must have a value that is @@ -1689,6 +1875,8 @@ importance: it ensures that all fonts can scale gracefully when using something like the ~text-scale-adjust~ command which only operates on the base font size (i.e. the ~default~ face's absolute height). +[[#h:e6c5451f-6763-4be7-8fdb-b4706a422a4c][Note for EWW and Elfeed fonts (SHR fonts)]]. + ** Custom Org user faces (DIY) :properties: :custom_id: h:89f0678d-c5c3-4a57-a526-668b2bb2d7ad @@ -1871,6 +2059,68 @@ package: (circadian-setup)) #+end_src +** Backdrop for pdf-tools (DIY) +:properties: +:custom_id: h:ff69dfe1-29c0-447a-915c-b5ff7c5509cd +:end: +#+cindex: Remapping pdf-tools backdrop + +Most PDF files use a white background for their page, making it +impossible to discern the file's boundaries in the buffer while using +the Modus Operandi theme. To introduce a distinction between the +buffer's backdrop and the PDF page's background, the former must be +rendered as some shade of gray. Ideally, ~pdf-tools~ would provide a face +that the themes could support directly, though this does not seem to be +the case for the time being. We must thus employ the face remapping +technique that is documented elsewhere in this document to change the +buffer-local value of the ~default~ face. + +[[#h:7a93cb6f-4eca-4d56-a85c-9dcd813d6b0f][Remap face with local value (DIY)]]. + +To remap the buffer's backdrop, we start with a function like this one: + +#+begin_src emacs-lisp +(defun my-pdf-tools-backdrop () + (face-remap-add-relative + 'default + `(:background ,(modus-themes-color 'bg-alt)))) + +(add-hook 'pdf-tools-enabled-hook #'my-pdf-tools-backdrop) +#+end_src + +The idea is to assign that function to a hook that gets called when +~pdf-tools~ renders the document: ~pdf-tools-enabled-hook~. This is enough +when you only use one theme. However it has the downside of setting the +background color value only at render time. In other words, the face +remapping function does not get evaluated anew whenever the theme +changes, such as upon invoking {{{kbd(M-x modus-themes-toggle)}}}. + +To have our face remapping adapt gracefully while switching between the +Modus themes, we need to also account for the current theme and control +the activation of ~pdf-view-midnight-minor-mode~. To which end we arrive +at something like the following, which builds on the above example: + +#+begin_src emacs-lisp +(defun my-pdf-tools-backdrop () + (face-remap-add-relative + 'default + `(:background ,(modus-themes-color 'bg-alt)))) + +(defun my-pdf-tools-midnight-mode-toggle () + (when (derived-mode-p 'pdf-view-mode) + (if (eq (car custom-enabled-themes) 'modus-vivendi) + (pdf-view-midnight-minor-mode 1) + (pdf-view-midnight-minor-mode -1)) + (my-pdf-tools-backdrop))) + +(add-hook 'pdf-tools-enabled-hook #'my-pdf-tools-midnight-mode-toggle) +(add-hook 'modus-themes-after-load-theme-hook #'my-pdf-tools-midnight-mode-toggle) +#+end_src + +With those in place, PDFs have a distinct backdrop for their page, while +they automatically switch to their dark mode when ~modus-themes-toggle~ is +called from inside a buffer whose major-mode is ~pdf-view-mode~. + ** A theme-agnostic hook for theme loading (DIY) :properties: :custom_id: h:86f6906b-f090-46cc-9816-1fe8aeb38776 @@ -1976,6 +2226,7 @@ have lots of extensions, so the "full support" may not be 100% true… + compilation-mode + completions + consult ++ corfu + counsel* + counsel-css + counsel-notmuch @@ -2018,8 +2269,9 @@ have lots of extensions, so the "full support" may not be 100% true… + eldoc-box + elfeed + elfeed-score ++ embark + emms -+ enhanced-ruby-mode ++ enh-ruby-mode (enhanced-ruby-mode) + epa + equake + erc @@ -2149,6 +2401,7 @@ have lots of extensions, so the "full support" may not be 100% true… + outline-minor-faces + package (what you get with {{{kbd(M-x list-packages)}}}) + page-break-lines ++ pandoc-mode + paradox + paren-face + parrot @@ -2206,7 +2459,11 @@ have lots of extensions, so the "full support" may not be 100% true… + sx + symbol-overlay + syslog-mode ++ tab-bar-groups ++ tab-bar-mode ++ tab-line-mode + table (built-in table.el) ++ telega + telephone-line + terraform-mode + term @@ -2221,6 +2478,7 @@ have lots of extensions, so the "full support" may not be 100% true… + vc (built-in mode line status for version control) + vc-annotate (the out put of {{{kbd(C-x v g)}}}) + vdiff ++ vertico + vimish-fold + visible-mark + visual-regexp @@ -2274,6 +2532,42 @@ inherit from some basic faces. Please confirm. This section covers information that may be of interest to users of individual packages. +** Note for dimmer.el +:properties: +:custom_id: h:8eb4b758-d318-4480-9ead-357a571beb93 +:end: + +The {{{file(dimmer.el)}}} library by Neil Okamoto can be configured to +automatically dim the colors of inactive Emacs windows. To guarantee +consistent results with the Modus themes, we suggest some tweaks to the +default styles, such as in this minimal setup: + +#+begin_src emacs-lisp +(use-package dimmer + :config + (setq dimmer-fraction 0.3) + (setq dimmer-adjustment-mode :foreground) + (setq dimmer-use-colorspace :rgb) + + (dimmer-mode 1)) +#+end_src + +Of the above, we strongly recommend the RGB color space because it is +the one that remains faithful to the hueness of the colors used by the +themes. Whereas the default CIELAB space has a tendency to distort +colors in addition to applying the dim effect, which can be somewhat +disorienting. + +The value of the ~dimmer-fraction~ has been selected empirically. Users +might prefer to tweak it further (increasing it makes the dim effect +more pronounced). + +Changing the ~dimmer-adjustment-mode~ is a matter of preference. Though +because the Modus themes use black and white as their base colors, any +other value for that variable will turn the main background gray. This +inadvertently leads to the opposite of the intended utility of this +package: it draws too much attention to unfocused windows. + ** Note for display-fill-column-indicator-mode :properties: :custom_id: h:2a602816-bc1b-45bf-9675-4cbbd7bf6cab @@ -2521,6 +2815,21 @@ specifications the webpage provides. Consult {{{kbd(C-h v shr-use-colors)}}}. + +** Note for EWW and Elfeed fonts (SHR fonts) +:properties: +:custom_id: h:e6c5451f-6763-4be7-8fdb-b4706a422a4c +:end: + +EWW and Elfeed rely on the Simple HTML Renderer to display their +content. The {{{file(shr.el)}}} library contains the variable ~shr-use-fonts~ +that controls whether the text in the buffer is set to a ~variable-pitch~ +typeface (proportionately spaced) or if just retains whatever the +default font family is. Its default value is non-nil, which means that +~variable-pitch~ is applied. + +[[#h:defcf4fc-8fa8-4c29-b12e-7119582cc929][Font configurations for Org and others]]. + ** Note for Helm grep :properties: :custom_id: h:d28879a2-8e4b-4525-986e-14c0f873d229 @@ -2748,26 +3057,28 @@ The Modus themes are a collective effort. Every bit of work matters. + Contributions to code or documentation :: Anders Johansson, Basil L.{{{space()}}} Contovounesios, Carlo Zancanaro, Eli Zaretskii, Kostadin - Ninev, Madhavan Krishnan, Markus Beppler, Matthew Stevenson, Nicolas - De Jaeghere, Shreyas Ragavan, Stefan Kangas, Vincent Murphy, Xinglu - Chen. + Ninev, Madhavan Krishnan, Markus Beppler, Matthew Stevenson, Mauro + Aranda, Nicolas De Jaeghere, Shreyas Ragavan, Stefan Kangas, Vincent + Murphy, Xinglu Chen. + Ideas and user feedback :: Aaron Jensen, Adam Spiers, Adrian Manea, Alex Griffin, Alex Peitsinis, Alexey Shmalko, Alok Singh, Anders Johansson, André Alexandre Gomes, Arif Rezai, Basil L.{{{space()}}} Contovounesios, Burgess Chang, Christian Tietze, Christopher Dimech, Damien Cassou, Daniel Mendler, Dario Gjorgjevski, David Edmondson, - Davor Rotim, Divan Santana, Gerry Agbobada, Gianluca Recchia, Gustavo - Barros, Hörmetjan Yiltiz, Ilja Kocken, Iris Garcia, Jeremy Friesen, - John Haman, Joshua O'Connor, Kevin Fleming, Kostadin Ninev, Len Trigg, - Manuel Uberti, Mark Burton, Markus Beppler, Michael Goldenberg, Morgan - Smith, Murilo Pereira, Nicolas De Jaeghere, Paul Poloskov, Pete - Kazmier, Peter Wu, Philip K., Pierre Téchoueyres, Roman Rudakov, Ryan - Phillips, Sam Kleinman, Shreyas Ragavan, Simon Pugnet, Tassilo Horn, - Thibaut Verron, Trey Merkley, Togan Muftuoglu, Toon Claes, Uri Sharf, - Utkarsh Singh, Vincent Foley. As well as users: Ben, CsBigDataHub1, - Emacs Contrib, Eugene, Fourchaux, Fredrik, Moesasji, Nick, TheBlob42, - bepolymathe, doolio, fleimgruber, iSeeU, jixiuf, okamsn. + Davor Rotim, Divan Santana, Emanuele Michele Alberto Monterosso, + Farasha Euker, Gerry Agbobada, Gianluca Recchia, Gustavo Barros, + Hörmetjan Yiltiz, Ilja Kocken, Iris Garcia, Jeremy Friesen, John + Haman, Joshua O'Connor, Kevin Fleming, Kévin Le Gouguec, Kostadin + Ninev, Len Trigg, Manuel Uberti, Mark Burton, Markus Beppler, Mauro + Aranda, Michael Goldenberg, Morgan Smith, Murilo Pereira, Nicky van + Foreest, Nicolas De Jaeghere, Paul Poloskov, Pete Kazmier, Peter Wu, + Philip K., Pierre Téchoueyres, Roman Rudakov, Ryan Phillips, Sam + Kleinman, Shreyas Ragavan, Simon Pugnet, Tassilo Horn, Thibaut Verron, + Trey Merkley, Togan Muftuoglu, Toon Claes, Uri Sharf, Utkarsh Singh, + Vincent Foley. As well as users: Ben, CsBigDataHub1, Emacs Contrib, + Eugene, Fourchaux, Fredrik, Moesasji, Nick, TheBlob42, Trey, + bepolymathe, doolio, fleimgruber, iSeeU, jixiuf, okamsn, pRot0ta1p. + Packaging :: Basil L.{{{space()}}} Contovounesios, Eli Zaretskii, Glenn Morris, Mauro Aranda, Richard Stallman, Stefan Kangas (core Emacs), @@ -2819,6 +3130,7 @@ And here are the canonical sources of this project's documentation: #+texinfo: @include doclicense.texi #+begin_export html +
 
                 GNU Free Documentation License
                  Version 1.3, 3 November 2008
@@ -3270,6 +3582,7 @@ If your document contains nontrivial examples of program code, we
 recommend releasing these examples in parallel under your choice of
 free software license, such as the GNU General Public License,
 to permit their use in free software.
+
#+end_export #+html: