commit 27490cec4e258d344c3e192301a18e36c52576a6 (HEAD, refs/remotes/origin/master) Author: Lars Ingebrigtsen Date: Sun Oct 20 10:28:44 2019 +0200 Revert "Add an edebug-cancel-debug-on-entry alias" This reverts commit cea9577b7d6fcf01599afd48078f8ff1defb1297. cancel-edebug-on-entry and cancel-debug-on-entry are not the same functions. diff --git a/lisp/emacs-lisp/debug.el b/lisp/emacs-lisp/debug.el index 65e02b5eef..f711971c18 100644 --- a/lisp/emacs-lisp/debug.el +++ b/lisp/emacs-lisp/debug.el @@ -683,8 +683,6 @@ Redefining FUNCTION also cancels it." (push s funs)))) funs)) -(defalias 'edebug-cancel-debug-on-entry #'cancel-debug-on-entry) - ;;;###autoload (defun cancel-debug-on-entry (&optional function) "Undo effect of \\[debug-on-entry] on FUNCTION. commit cea9577b7d6fcf01599afd48078f8ff1defb1297 Author: Lars Ingebrigtsen Date: Sun Oct 20 09:48:28 2019 +0200 Add an edebug-cancel-debug-on-entry alias * lisp/emacs-lisp/debug.el (edebug-cancel-debug-on-entry): Add an alias for easier discoverability (bug#10806). diff --git a/lisp/emacs-lisp/debug.el b/lisp/emacs-lisp/debug.el index f711971c18..65e02b5eef 100644 --- a/lisp/emacs-lisp/debug.el +++ b/lisp/emacs-lisp/debug.el @@ -683,6 +683,8 @@ Redefining FUNCTION also cancels it." (push s funs)))) funs)) +(defalias 'edebug-cancel-debug-on-entry #'cancel-debug-on-entry) + ;;;###autoload (defun cancel-debug-on-entry (&optional function) "Undo effect of \\[debug-on-entry] on FUNCTION. commit 19f72110fc448e58dcd2d867d1db1fc547b790f2 Author: Lars Ingebrigtsen Date: Sun Oct 20 09:40:11 2019 +0200 Protect against invalid punycode * lisp/net/puny.el (puny-decode-string): Protect against invalid punycode. diff --git a/lisp/net/puny.el b/lisp/net/puny.el index 23c7af8061..729076ddbd 100644 --- a/lisp/net/puny.el +++ b/lisp/net/puny.el @@ -63,7 +63,10 @@ For instance, \"xn--ff-2sa.org\" => \"fśf.org\"." "Decode an IDNA/punycode-encoded string. For instance \"xn--bcher-kva\" => \"bücher\"." (if (string-match "\\`xn--" string) - (puny-decode-string-internal (substring string 4)) + (condition-case nil + (puny-decode-string-internal (substring string 4)) + ;; If the string is invalid Punycode, just return the string. + (args-out-of-range string)) string)) (defconst puny-initial-n 128) commit d9a3c8974f9690e68d34a261bde58fb465750908 Author: Juri Linkov Date: Sun Oct 20 01:40:05 2019 +0300 * lisp/net/eww.el (eww-browse-url-new-window-is-tab): New defcustom. (eww-open-in-new-buffer, eww-browse-url): Use new defcustom (bug#37592). diff --git a/lisp/net/eww.el b/lisp/net/eww.el index f5dedd52b2..dccaf0497f 100644 --- a/lisp/net/eww.el +++ b/lisp/net/eww.el @@ -128,6 +128,18 @@ The string will be passed through `substitute-command-keys'." :type '(choice (const :tag "Never" nil) regexp)) +(defcustom eww-browse-url-new-window-is-tab 'tab-bar + "Whether to open up new windows in a tab or a new buffer. +If t, then open the URL in a new tab rather than a new buffer if +`eww-browse-url' is asked to open it in a new window. +If `tab-bar', then open the URL in a new tab only when +the tab bar is enabled." + :version "27.1" + :group 'eww + :type '(choice (const :tag "Always open URL in new tab" t) + (const :tag "Open new tab when tab bar is enabled" tab-bar) + (const :tag "Never open URL in new tab" nil))) + (defcustom eww-after-render-hook nil "A hook called after eww has finished rendering the buffer." :version "25.1" @@ -369,7 +381,9 @@ engine used." (interactive) (let ((url (eww-suggested-uris))) (if (null url) (user-error "No link at point") - (when tab-bar-mode + (when (or (eq eww-browse-url-new-window-is-tab t) + (and (eq eww-browse-url-new-window-is-tab 'tab-bar) + tab-bar-mode)) (let ((tab-bar-new-tab-choice t)) (tab-new))) ;; clone useful to keep history, but @@ -889,12 +903,15 @@ prefix argument reverses the effect of `browse-url-new-window-flag'. If `tab-bar-mode' is enabled, then whenever a document would otherwise be loaded in a new buffer, it is loaded in a new tab -in the tab-bar on an existing frame. +in the tab-bar on an existing frame. See more options in +`eww-browse-url-new-window-is-tab'. Non-interactively, this uses the optional second argument NEW-WINDOW instead of `browse-url-new-window-flag'." (when new-window - (when tab-bar-mode + (when (or (eq eww-browse-url-new-window-is-tab t) + (and (eq eww-browse-url-new-window-is-tab 'tab-bar) + tab-bar-mode)) (let ((tab-bar-new-tab-choice t)) (tab-new))) (pop-to-buffer-same-window commit 58d23f5f19b5b766fd70addcb36414a739a00e4a Author: Juri Linkov Date: Sun Oct 20 01:06:38 2019 +0300 Use 'C-x t' for tab-prefix-map instead of 'C-x 6' still used by 2C-mode-map. * doc/emacs/commands.texi (Keys): Add 'C-x t'. * doc/emacs/frames.texi (Tab Bars): Replace 'C-x 6' with 'C-x t'. * doc/lispref/keymaps.texi (Prefix Keys): Add 'C-x t' (tab-prefix-map). * doc/lispref/maps.texi (Standard Keymaps): Add tab-prefix-map, tab-bar-map. * lisp/dired.el: Rebind 'C-x 6 d' to 'C-x t d'. Use tab-prefix-map. * lisp/subr.el (ctl-x-6-map, ctl-x-6-prefix, ctl-x-t-prefix): Remove. (tab-prefix-map): New keymap bound to 'C-x t'. * lisp/tab-bar.el: Use tab-prefix-map instead of ctl-x-6-map. * lisp/textmodes/two-column.el: Restore autoload global setting of "\C-x6" to 2C-command. * lisp/ldefs-boot.el: Update to add setting "\C-x6" to 2C-command. * doc/emacs/commands.texi (Keys): * doc/emacs/text.texi (Two-Column): * doc/lispref/keymaps.texi (Prefix Keys): * doc/lispref/maps.texi (Standard Keymaps): Restore 'C-x 6' bound to '2C-mode-map'. diff --git a/doc/emacs/commands.texi b/doc/emacs/commands.texi index 17e0d20f35..5eb3b30417 100644 --- a/doc/emacs/commands.texi +++ b/doc/emacs/commands.texi @@ -117,13 +117,14 @@ C-k} is two key sequences, not one. By default, the prefix keys in Emacs are @kbd{C-c}, @kbd{C-h}, @kbd{C-x}, @kbd{C-x @key{RET}}, @kbd{C-x @@}, @kbd{C-x a}, @kbd{C-x -n}, @kbd{C-x r}, @kbd{C-x v}, @kbd{C-x 4}, @kbd{C-x 5}, @kbd{C-x 6}, -@key{ESC}, @kbd{M-g}, @kbd{M-o} and @key{F2}. (@key{F1} is an alias -for @kbd{C-h}.) This list is not cast in stone; if you customize -Emacs, you can make new prefix keys. You could even eliminate some of -the standard ones, though this is not recommended for most users; for -example, if you remove the prefix definition of @kbd{C-x 4}, then -@kbd{C-x 4 C-f} becomes an invalid key sequence. @xref{Key Bindings}. +n}, @kbd{C-x r}, @kbd{C-x t}, @kbd{C-x v}, @kbd{C-x 4}, @kbd{C-x 5}, +@kbd{C-x 6}, @key{ESC}, @kbd{M-g}, and @kbd{M-o}. (@key{F1} and +@key{F2} are aliases for @kbd{C-h} and @kbd{C-x 6}.) This list is not +cast in stone; if you customize Emacs, you can make new prefix keys. +You could even eliminate some of the standard ones, though this is not +recommended for most users; for example, if you remove the prefix +definition of @kbd{C-x 4}, then @kbd{C-x 4 C-f} becomes an invalid key +sequence. @xref{Key Bindings}. Typing the help character (@kbd{C-h} or @key{F1}) after a prefix key displays a list of the commands starting with that prefix. The sole diff --git a/doc/emacs/frames.texi b/doc/emacs/frames.texi index 452c167c72..cac1f7fea6 100644 --- a/doc/emacs/frames.texi +++ b/doc/emacs/frames.texi @@ -1257,32 +1257,32 @@ use persistent named window configurations without using the tab bar by typing the related commands: @kbd{M-x tab-new}, @kbd{M-x tab-next}, @kbd{M-x tab-list}, @kbd{M-x tab-close}, etc. -@kindex C-x 6 - The prefix key @kbd{C-x 6} is analogous to @kbd{C-x 5}. +@kindex C-x t + The prefix key @kbd{C-x t} is analogous to @kbd{C-x 5}. Whereas each @kbd{C-x 5} command pops up a buffer in a different frame -(@pxref{Creating Frames}), the @kbd{C-x 6} commands use a different +(@pxref{Creating Frames}), the @kbd{C-x t} commands use a different tab with a different window configuration in the selected frame. - The various @kbd{C-x 6} commands differ in how they find or create the + The various @kbd{C-x t} commands differ in how they find or create the buffer to select: @table @kbd -@item C-x 6 2 -@kindex C-x 6 2 +@item C-x t 2 +@kindex C-x t 2 @findex tab-new Add a new tab (@code{tab-new}). You can control the choice of the buffer displayed in a new tab by customizing the variable @code{tab-bar-new-tab-choice}. -@item C-x 6 b @var{bufname} @key{RET} +@item C-x t b @var{bufname} @key{RET} Select buffer @var{bufname} in another tab. This runs @code{switch-to-buffer-other-tab}. -@item C-x 6 f @var{filename} @key{RET} +@item C-x t f @var{filename} @key{RET} Visit file @var{filename} and select its buffer in another tab. This runs @code{find-file-other-tab}. @xref{Visiting}. -@item C-x 6 d @var{directory} @key{RET} +@item C-x t d @var{directory} @key{RET} Select a Dired buffer for directory @var{directory} in another tab. This runs @code{dired-other-tab}. @xref{Dired}. -@item C-x 6 r @var{tabname} @key{RET} +@item C-x t r @var{tabname} @key{RET} Renames the current tab to @var{tabname}. You can control the programmatic name given to a tab by default by customizing the variable @code{tab-bar-tab-name-function}. @@ -1297,14 +1297,14 @@ new tab with other buffers, customize the variable The following commands are used to delete and operate on tabs: @table @kbd -@item C-x 6 0 -@kindex C-x 6 0 +@item C-x t 0 +@kindex C-x t 0 @findex tab-close Close the selected tab (@code{tab-close}). It has no effect if there is only one tab. -@item C-x 6 o -@kindex C-x 6 o +@item C-x t o +@kindex C-x t o @kindex C-TAB @findex tab-next Switch to another tab. If you repeat this command, it cycles through @@ -1312,8 +1312,8 @@ all the tabs on the selected frame. With a positive numeric argument N, it switches to the next Nth tab; with a negative argument −N, it switches back to the previous Nth tab. -@item C-x 6 1 -@kindex C-x 6 1 +@item C-x t 1 +@kindex C-x t 1 @findex tab-close-other Close all tabs on the selected frame, except the selected one. @end table diff --git a/doc/emacs/text.texi b/doc/emacs/text.texi index a837b6580d..974f79d523 100644 --- a/doc/emacs/text.texi +++ b/doc/emacs/text.texi @@ -2870,8 +2870,9 @@ of text. It uses two side-by-side windows, each showing its own buffer. There are three ways to enter two-column mode: @table @asis -@item @kbd{@key{F2} 2} +@item @kbd{@key{F2} 2} or @kbd{C-x 6 2} @kindex F2 2 +@kindex C-x 6 2 @findex 2C-two-columns Enter two-column mode with the current buffer on the left, and on the right, a buffer whose name is based on the current buffer's name @@ -2882,8 +2883,9 @@ changed. This command is appropriate when the current buffer is empty or contains just one column and you want to add another column. -@item @kbd{@key{F2} s} +@item @kbd{@key{F2} s} or @kbd{C-x 6 s} @kindex F2 s +@kindex C-x 6 s @findex 2C-split Split the current buffer, which contains two-column text, into two buffers, and display them side by side (@code{2C-split}). The current @@ -2896,19 +2898,21 @@ This command is appropriate when you have a buffer that already contains two-column text, and you wish to separate the columns temporarily. @item @kbd{@key{F2} b @var{buffer} @key{RET}} +@itemx @kbd{C-x 6 b @var{buffer} @key{RET}} @kindex F2 b +@kindex C-x 6 b @findex 2C-associate-buffer Enter two-column mode using the current buffer as the left-hand buffer, and using buffer @var{buffer} as the right-hand buffer (@code{2C-associate-buffer}). @end table - @kbd{@key{F2} s} looks for a column separator, which is a string -that appears on each line between the two columns. You can specify -the width of the separator with a numeric argument to @kbd{@key{F2} -s}; that many characters, before point, constitute the separator -string. By default, the width is 1, so the column separator is the -character before point. + @kbd{@key{F2} s} or @kbd{C-x 6 s} looks for a column separator, which +is a string that appears on each line between the two columns. You can +specify the width of the separator with a numeric argument to +@kbd{@key{F2} s}; that many characters, before point, constitute the +separator string. By default, the width is 1, so the column separator +is the character before point. When a line has the separator at the proper place, @kbd{@key{F2} s} puts the text after the separator into the right-hand buffer, and @@ -2920,22 +2924,25 @@ mode: write it in the left-hand buffer, and put an empty line in the right-hand buffer.) @kindex F2 RET +@kindex C-x 6 RET @findex 2C-newline - The command @kbd{@key{F2} @key{RET}} (@code{2C-newline}) inserts -a newline in each of the two buffers at corresponding positions. -This is the easiest way to add a new line to the two-column text while -editing it in split buffers. + The command @kbd{@key{F2} @key{RET}} or @kbd{C-x 6 @key{RET}} +(@code{2C-newline}) inserts a newline in each of the two buffers at +corresponding positions. This is the easiest way to add a new line to +the two-column text while editing it in split buffers. @kindex F2 1 +@kindex C-x 6 1 @findex 2C-merge When you have edited both buffers as you wish, merge them with -@kbd{@key{F2} 1} (@code{2C-merge}). This copies the +@kbd{@key{F2} 1} or @kbd{C-x 6 1} (@code{2C-merge}). This copies the text from the right-hand buffer as a second column in the other buffer. To go back to two-column editing, use @kbd{@key{F2} s}. @kindex F2 d +@kindex C-x 6 d @findex 2C-dissociate - Use @kbd{@key{F2} d} to dissociate the two buffers, leaving each as -it stands (@code{2C-dissociate}). If the other buffer, the one not -current when you type @kbd{@key{F2} d}, is empty, @kbd{@key{F2} d} -kills it. + Use @kbd{@key{F2} d} or @kbd{C-x 6 d} to dissociate the two buffers, +leaving each as it stands (@code{2C-dissociate}). If the other buffer, +the one not current when you type @kbd{@key{F2} d}, is empty, +@kbd{@key{F2} d} kills it. diff --git a/doc/lispref/keymaps.texi b/doc/lispref/keymaps.texi index 532e537026..8ff329bdac 100644 --- a/doc/lispref/keymaps.texi +++ b/doc/lispref/keymaps.texi @@ -545,8 +545,14 @@ key. @item @cindex @kbd{C-x 6} -@vindex ctl-x-6-map -@code{ctl-x-6-map} is the global keymap used for the @kbd{C-x 6} prefix +@vindex 2C-mode-map +@code{2C-mode-map} is the global keymap used for the @kbd{C-x 6} prefix +key. + +@item +@cindex @kbd{C-x t} +@vindex tab-prefix-map +@code{tab-prefix-map} is the global keymap used for the @kbd{C-x t} prefix key. @item diff --git a/doc/lispref/maps.texi b/doc/lispref/maps.texi index 1ee4816b0c..7743f3cb3c 100644 --- a/doc/lispref/maps.texi +++ b/doc/lispref/maps.texi @@ -21,7 +21,7 @@ keymaps, @pxref{Keymaps}. @c Don't add xrefs to things covered in {Keymaps}. @table @code @item 2C-mode-map -A sparse keymap for subcommands of the prefix @key{F2}.@* +A sparse keymap for subcommands of the prefix @kbd{C-x 6}.@* @xref{Two-Column,, Two-Column Editing, emacs, The GNU Emacs Manual}. @item abbrev-map @@ -42,9 +42,6 @@ A sparse keymap for subcommands of the prefix @kbd{C-x 4}. @item ctl-x-5-map A sparse keymap for subcommands of the prefix @kbd{C-x 5}. -@item ctl-x-6-map -A sparse keymap for subcommands of the prefix @kbd{C-x 6}. - @item ctl-x-map A full keymap for @kbd{C-x} commands. @@ -181,6 +178,14 @@ A sparse keymap that provides global bindings for search-related commands. The keymap used by Special mode.@* @xref{Basic Major Modes}. +@item tab-prefix-map +The global keymap used for the @kbd{C-x t} prefix key for tab-bar related commands.@* +@xref{Tab Bars,,, emacs, The GNU Emacs Manual}. + +@item tab-bar-map +The keymap defining the contents of the tab bar.@* +@xref{Tab Bars,,, emacs, The GNU Emacs Manual}. + @item tool-bar-map The keymap defining the contents of the tool bar.@* @xref{Tool Bar}. diff --git a/etc/NEWS b/etc/NEWS index 6ed3fd4608..e49dc0c998 100644 --- a/etc/NEWS +++ b/etc/NEWS @@ -2131,9 +2131,9 @@ The new command 'tab-bar-mode' enables the tab bar at the top of each frame, where you can use tabs to switch between named persistent window configurations. -The 'C-x 6' sequence is the new prefix key for tab-related commands: -'C-x 6 2' creates a new tab; 'C-x 6 0' deletes the current tab; -'C-x 6 b' switches to buffer in another tab; 'C-x 6 f' and 'C-x 6 C-f' +The 'C-x t' sequence is the new prefix key for tab-related commands: +'C-x t 2' creates a new tab; 'C-x t 0' deletes the current tab; +'C-x t b' switches to buffer in another tab; 'C-x t f' and 'C-x t C-f' edit file in another tab; and 'C-TAB' and 'S-C-TAB' switch to the next or previous tab. You can also switch between tabs and create/delete tabs with a mouse. @@ -2195,11 +2195,6 @@ immediately. Type 'M-x so-long-commentary' for full documentation. * Incompatible Lisp Changes in Emacs 27.1 ---- -** Two-column mode provides its 'C-x 6' prefix map only after loading -two-column.el. Its prefix key 'F2' is still available globally -along with 'C-x 6' used by the tab commands globally. - --- ** Incomplete destructive splicing support has been removed. Support for Common Lisp style destructive splicing (",.") was diff --git a/lisp/dired.el b/lisp/dired.el index 574de7ac3e..3146511305 100644 --- a/lisp/dired.el +++ b/lisp/dired.el @@ -848,7 +848,7 @@ If DIRNAME is already in a Dired buffer, that buffer is used without refresh." (interactive (dired-read-dir-and-switches "in other frame ")) (switch-to-buffer-other-frame (dired-noselect dirname switches))) -;;;###autoload (define-key ctl-x-6-map "d" 'dired-other-tab) +;;;###autoload (define-key tab-prefix-map "d" 'dired-other-tab) ;;;###autoload (defun dired-other-tab (dirname &optional switches) "\"Edit\" directory DIRNAME. Like `dired' but makes a new tab." diff --git a/lisp/ldefs-boot.el b/lisp/ldefs-boot.el index 5c20c0526d..ea111f2d3f 100644 --- a/lisp/ldefs-boot.el +++ b/lisp/ldefs-boot.el @@ -34138,6 +34138,7 @@ resumed later. ;;;;;; 0 0)) ;;; Generated autoloads from textmodes/two-column.el (autoload '2C-command "two-column" () t 'keymap) + (global-set-key "\C-x6" '2C-command) (global-set-key [f2] '2C-command) (autoload '2C-two-columns "two-column" "\ diff --git a/lisp/subr.el b/lisp/subr.el index f3371dd2d7..ada078aed9 100644 --- a/lisp/subr.el +++ b/lisp/subr.el @@ -1262,12 +1262,9 @@ The normal global definition of the character C-x indirects to this keymap.") (defalias 'ctl-x-5-prefix ctl-x-5-map) (define-key ctl-x-map "5" 'ctl-x-5-prefix) -(defvar ctl-x-6-map (make-sparse-keymap) - "Keymap for tab commands.") -(defalias 'ctl-x-6-prefix ctl-x-6-map) -(define-key ctl-x-map "6" 'ctl-x-6-prefix) -(defalias 'ctl-x-t-prefix ctl-x-6-map) -(define-key ctl-x-map "t" 'ctl-x-t-prefix) +(defvar tab-prefix-map (make-sparse-keymap) + "Keymap for tab-bar related commands.") +(define-key ctl-x-map "t" tab-prefix-map) ;;;; Event manipulation functions. diff --git a/lisp/tab-bar.el b/lisp/tab-bar.el index c376f59896..52d0687231 100644 --- a/lisp/tab-bar.el +++ b/lisp/tab-bar.el @@ -962,14 +962,14 @@ Like \\[find-file-other-frame] (which see), but creates a new tab." value) (switch-to-buffer-other-tab value)))) -(define-key ctl-x-6-map "2" 'tab-new) -(define-key ctl-x-6-map "1" 'tab-close-other) -(define-key ctl-x-6-map "0" 'tab-close) -(define-key ctl-x-6-map "o" 'tab-next) -(define-key ctl-x-6-map "b" 'switch-to-buffer-other-tab) -(define-key ctl-x-6-map "f" 'find-file-other-tab) -(define-key ctl-x-6-map "\C-f" 'find-file-other-tab) -(define-key ctl-x-6-map "r" 'tab-rename) +(define-key tab-prefix-map "2" 'tab-new) +(define-key tab-prefix-map "1" 'tab-close-other) +(define-key tab-prefix-map "0" 'tab-close) +(define-key tab-prefix-map "o" 'tab-next) +(define-key tab-prefix-map "b" 'switch-to-buffer-other-tab) +(define-key tab-prefix-map "f" 'find-file-other-tab) +(define-key tab-prefix-map "\C-f" 'find-file-other-tab) +(define-key tab-prefix-map "r" 'tab-rename) (provide 'tab-bar) diff --git a/lisp/textmodes/two-column.el b/lisp/textmodes/two-column.el index 5bc70d0bd5..e1ebf1a02a 100644 --- a/lisp/textmodes/two-column.el +++ b/lisp/textmodes/two-column.el @@ -184,9 +184,7 @@ minus this value." ;; This one is for historical reasons and simple keyboards, it is not ;; at all mnemonic. All usual sequences containing 2 were used, and ;; f2 could not be set up in a standard way under Emacs 18. -;; This prefix is bound only after loading this package -;; to not conflict with the C-x 6 prefix used by tab commands. -(global-set-key "\C-x6" '2C-command) +;;;###autoload (global-set-key "\C-x6" '2C-command) ;;;###autoload (global-set-key [f2] '2C-command) commit 7e238e7d50872d43a137c1350cb3b293aea176c2 Author: Juri Linkov Date: Sat Oct 19 23:51:03 2019 +0300 Add ':extend t' face attribute to diff faces (bug#37774) * lisp/vc/diff-mode.el (diff-header, diff-file-header) (diff-removed, diff-added): Add ':extend t' face attribute. * lisp/vc/ediff-init.el (ediff-current-diff-A) (ediff-current-diff-B, ediff-current-diff-C) (ediff-current-diff-Ancestor, ediff-even-diff-A) (ediff-even-diff-B, ediff-even-diff-C, ediff-even-diff-Ancestor) (ediff-odd-diff-A, ediff-odd-diff-B, ediff-odd-diff-C) (ediff-odd-diff-Ancestor): Add ':extend t' face attribute. * lisp/vc/smerge-mode.el (smerge-upper, smerge-lower) (smerge-base, smerge-markers): Add ':extend t' face attribute. * lisp/vc/log-view.el (log-view-file, log-view-message): Add ':extend t' face attribute. * lisp/faces.el (secondary-selection): Add ':extend t' face attribute. (line-number-major-tick, line-number-minor-tick): Change :foreground to :background. diff --git a/etc/NEWS b/etc/NEWS index fd46360ed2..6ed3fd4608 100644 --- a/etc/NEWS +++ b/etc/NEWS @@ -391,9 +391,9 @@ to 'completion-styles' or 'completion-category-overrides' to use it. ** New face attribute ':extend' to control face extension at EOL. The new face attribute ':extend' controls whether to use the face for displaying the empty space beyond end of line (EOL) till the edge of -the window. By default, this attribute is non-nil only for 'region' -and 'hl-line' faces; any other face that crosses end of line will not -affect the display of the empty space at EOL. +the window. By default, this attribute is non-nil only for 'region', +'secondary-selection', 'hl-line' and diff faces; any other face that +crosses end of line will not affect the display of the empty space at EOL. ** Connection-local variables diff --git a/lisp/faces.el b/lisp/faces.el index 36fc69895d..2779197804 100644 --- a/lisp/faces.el +++ b/lisp/faces.el @@ -2365,15 +2365,15 @@ If you set `term-file-prefix' to nil, this function does nothing." (defface secondary-selection '((((class color) (min-colors 88) (background light)) - :background "yellow1") + :background "yellow1" :extend t) (((class color) (min-colors 88) (background dark)) - :background "SkyBlue4") + :background "SkyBlue4" :extend t) (((class color) (min-colors 16) (background light)) - :background "yellow") + :background "yellow" :extend t) (((class color) (min-colors 16) (background dark)) - :background "SkyBlue4") + :background "SkyBlue4" :extend t) (((class color) (min-colors 8)) - :background "cyan" :foreground "black") + :background "cyan" :foreground "black" :extend t) (t :inverse-video t)) "Basic face for displaying the secondary selection." :group 'basic-faces) @@ -2419,9 +2419,9 @@ unwanted effects." (defface line-number-major-tick '((((class color grayscale) (background light)) - :foreground "grey55" :bold t) + :background "grey85" :bold t) (((class color grayscale) (background dark)) - :foreground "grey75" :bold t) + :background "grey75" :bold t) (t :inherit line-number)) "Face for highlighting \"major ticks\" (as in a ruler). When `display-line-numbers-major-tick' is positive, highlight @@ -2440,9 +2440,9 @@ unwanted effects." (defface line-number-minor-tick '((((class color grayscale) (background light)) - :foreground "grey65" :bold t) + :background "grey95" :bold t) (((class color grayscale) (background dark)) - :foreground "grey55" :bold t) + :background "grey55" :bold t) (t :inherit line-number)) "Face for highlighting \"minor ticks\" (as in a ruler). When `display-line-numbers-minor-tick' is positive, highlight diff --git a/lisp/vc/diff-mode.el b/lisp/vc/diff-mode.el index c86f15cee0..dfac1cca80 100644 --- a/lisp/vc/diff-mode.el +++ b/lisp/vc/diff-mode.el @@ -298,9 +298,9 @@ well." (defface diff-header '((((class color) (min-colors 88) (background light)) - :background "grey85") + :background "grey85" :extend t) (((class color) (min-colors 88) (background dark)) - :background "grey45") + :background "grey45" :extend t) (((class color)) :foreground "blue1" :weight bold) (t :weight bold)) @@ -308,9 +308,9 @@ well." (defface diff-file-header '((((class color) (min-colors 88) (background light)) - :background "grey75" :weight bold) + :background "grey75" :weight bold :extend t) (((class color) (min-colors 88) (background dark)) - :background "grey60" :weight bold) + :background "grey60" :weight bold :extend t) (((class color)) :foreground "cyan" :weight bold) (t :weight bold)) ; :height 1.3 @@ -328,11 +328,11 @@ well." '((default :inherit diff-changed) (((class color) (min-colors 257) (background light)) - :background "#ffeeee") + :background "#ffeeee" :extend t) (((class color) (min-colors 88) (background light)) - :background "#ffdddd") + :background "#ffdddd" :extend t) (((class color) (min-colors 88) (background dark)) - :background "#553333") + :background "#553333" :extend t) (((class color)) :foreground "red")) "`diff-mode' face used to highlight removed lines.") @@ -341,11 +341,11 @@ well." '((default :inherit diff-changed) (((class color) (min-colors 257) (background light)) - :background "#eeffee") + :background "#eeffee" :extend t) (((class color) (min-colors 88) (background light)) - :background "#ddffdd") + :background "#ddffdd" :extend t) (((class color) (min-colors 88) (background dark)) - :background "#335533") + :background "#335533" :extend t) (((class color)) :foreground "green")) "`diff-mode' face used to highlight added lines.") diff --git a/lisp/vc/ediff-init.el b/lisp/vc/ediff-init.el index 9e4d08d70c..ca7f4eb8a2 100644 --- a/lisp/vc/ediff-init.el +++ b/lisp/vc/ediff-init.el @@ -806,13 +806,13 @@ to temp files in buffer jobs and when Ediff needs to find fine differences." (defface ediff-current-diff-A '((((class color) (min-colors 88) (background light)) - :background "#ffdddd") + :background "#ffdddd" :extend t) (((class color) (min-colors 88) (background dark)) - :background "#553333") + :background "#553333" :extend t) (((class color) (min-colors 16)) - (:foreground "firebrick" :background "pale green")) + (:foreground "firebrick" :background "pale green" :extend t)) (((class color)) - (:foreground "blue3" :background "yellow3")) + (:foreground "blue3" :background "yellow3" :extend t)) (t (:inverse-video t))) "Face for highlighting the selected difference in buffer A." :group 'ediff-highlighting) @@ -827,14 +827,14 @@ this variable represents.") (defface ediff-current-diff-B '((((class color) (min-colors 88) (background light)) - :background "#ddffdd") + :background "#ddffdd" :extend t) (((class color) (min-colors 88) (background dark)) - :background "#335533") + :background "#335533" :extend t) (((class color) (min-colors 16)) - (:foreground "DarkOrchid" :background "Yellow")) + (:foreground "DarkOrchid" :background "Yellow" :extend t)) (((class color)) (:foreground "magenta3" :background "yellow3" - :weight bold)) + :weight bold :extend t)) (t (:inverse-video t))) "Face for highlighting the selected difference in buffer B." :group 'ediff-highlighting) @@ -849,13 +849,13 @@ this variable represents.") (defface ediff-current-diff-C '((((class color) (min-colors 88) (background light)) - :background "#ffffaa") + :background "#ffffaa" :extend t) (((class color) (min-colors 88) (background dark)) - :background "#888833") + :background "#888833" :extend t) (((class color) (min-colors 16)) - (:foreground "Navy" :background "Pink")) + (:foreground "Navy" :background "Pink" :extend t)) (((class color)) - (:foreground "cyan3" :background "yellow3" :weight bold)) + (:foreground "cyan3" :background "yellow3" :weight bold :extend t)) (t (:inverse-video t))) "Face for highlighting the selected difference in buffer C." :group 'ediff-highlighting) @@ -870,15 +870,15 @@ this variable represents.") (defface ediff-current-diff-Ancestor '((((class color) (min-colors 88) (background light)) - :background "#cfdeee") + :background "#cfdeee" :extend t) (((class color) (min-colors 88) (background dark)) - :background "#004151") + :background "#004151" :extend t) (((class color) (min-colors 16) (background light)) - :background "#cfdeee") + :background "#cfdeee" :extend t) (((class color) (min-colors 16) (background dark)) - :background "#004151") + :background "#004151" :extend t) (((class color)) - (:foreground "black" :background "magenta3")) + (:foreground "black" :background "magenta3" :extend t)) (t (:inverse-video t))) "Face for highlighting the selected difference in buffer Ancestor." :group 'ediff-highlighting) @@ -993,14 +993,14 @@ this variable represents.") (defface ediff-even-diff-A `((((type pc)) - (:foreground "green3" :background "light grey")) + (:foreground "green3" :background "light grey" :extend t)) (((class color) (min-colors 88)) - (:background "light grey")) + (:background "light grey" :extend t)) (((class color) (min-colors 16)) - (:foreground "Black" :background "light grey")) + (:foreground "Black" :background "light grey" :extend t)) (((class color)) (:foreground "red3" :background "light grey" - :weight bold)) + :weight bold :extend t)) (t (:italic t :stipple ,stipple-pixmap))) "Face for highlighting even-numbered non-current differences in buffer A." :group 'ediff-highlighting) @@ -1015,11 +1015,11 @@ this variable represents.") (defface ediff-even-diff-B `((((class color) (min-colors 88)) - (:background "Grey")) + (:background "Grey" :extend t)) (((class color) (min-colors 16)) - (:foreground "White" :background "Grey")) + (:foreground "White" :background "Grey" :extend t)) (((class color)) - (:foreground "blue3" :background "Grey" :weight bold)) + (:foreground "blue3" :background "Grey" :weight bold :extend t)) (t (:italic t :stipple ,stipple-pixmap))) "Face for highlighting even-numbered non-current differences in buffer B." :group 'ediff-highlighting) @@ -1034,14 +1034,14 @@ this variable represents.") (defface ediff-even-diff-C `((((type pc)) - (:foreground "yellow3" :background "light grey")) + (:foreground "yellow3" :background "light grey" :extend t)) (((class color) (min-colors 88)) - (:background "light grey")) + (:background "light grey" :extend t)) (((class color) (min-colors 16)) - (:foreground "Black" :background "light grey")) + (:foreground "Black" :background "light grey" :extend t)) (((class color)) (:foreground "yellow3" :background "light grey" - :weight bold)) + :weight bold :extend t)) (t (:italic t :stipple ,stipple-pixmap))) "Face for highlighting even-numbered non-current differences in buffer C." :group 'ediff-highlighting) @@ -1056,14 +1056,14 @@ this variable represents.") (defface ediff-even-diff-Ancestor `((((type pc)) - (:foreground "cyan3" :background "light grey")) + (:foreground "cyan3" :background "light grey" :extend t)) (((class color) (min-colors 88)) - (:background "Grey")) + (:background "Grey" :extend t)) (((class color) (min-colors 16)) - (:foreground "White" :background "Grey")) + (:foreground "White" :background "Grey" :extend t)) (((class color)) (:foreground "cyan3" :background "light grey" - :weight bold)) + :weight bold :extend t)) (t (:italic t :stipple ,stipple-pixmap))) "Face for highlighting even-numbered non-current differences in the ancestor buffer." :group 'ediff-highlighting) @@ -1085,13 +1085,13 @@ this variable represents.") (defface ediff-odd-diff-A '((((type pc)) - (:foreground "green3" :background "gray40")) + (:foreground "green3" :background "gray40" :extend t)) (((class color) (min-colors 88)) - (:background "Grey")) + (:background "Grey" :extend t)) (((class color) (min-colors 16)) - (:foreground "White" :background "Grey")) + (:foreground "White" :background "Grey" :extend t)) (((class color)) - (:foreground "red3" :background "black" :weight bold)) + (:foreground "red3" :background "black" :weight bold :extend t)) (t (:italic t :stipple "gray1"))) "Face for highlighting odd-numbered non-current differences in buffer A." :group 'ediff-highlighting) @@ -1107,13 +1107,13 @@ this variable represents.") (defface ediff-odd-diff-B '((((type pc)) - (:foreground "White" :background "gray40")) + (:foreground "White" :background "gray40" :extend t)) (((class color) (min-colors 88)) - (:background "light grey")) + (:background "light grey" :extend t)) (((class color) (min-colors 16)) - (:foreground "Black" :background "light grey")) + (:foreground "Black" :background "light grey" :extend t)) (((class color)) - (:foreground "cyan3" :background "black" :weight bold)) + (:foreground "cyan3" :background "black" :weight bold :extend t)) (t (:italic t :stipple "gray1"))) "Face for highlighting odd-numbered non-current differences in buffer B." :group 'ediff-highlighting) @@ -1128,13 +1128,13 @@ this variable represents.") (defface ediff-odd-diff-C '((((type pc)) - (:foreground "yellow3" :background "gray40")) + (:foreground "yellow3" :background "gray40" :extend t)) (((class color) (min-colors 88)) - (:background "Grey")) + (:background "Grey" :extend t)) (((class color) (min-colors 16)) - (:foreground "White" :background "Grey")) + (:foreground "White" :background "Grey" :extend t)) (((class color)) - (:foreground "yellow3" :background "black" :weight bold)) + (:foreground "yellow3" :background "black" :weight bold :extend t)) (t (:italic t :stipple "gray1"))) "Face for highlighting odd-numbered non-current differences in buffer C." :group 'ediff-highlighting) @@ -1149,11 +1149,11 @@ this variable represents.") (defface ediff-odd-diff-Ancestor '((((class color) (min-colors 88)) - (:background "gray40")) + (:background "gray40" :extend t)) (((class color) (min-colors 16)) - (:foreground "cyan3" :background "gray40")) + (:foreground "cyan3" :background "gray40" :extend t)) (((class color)) - (:foreground "green3" :background "black" :weight bold)) + (:foreground "green3" :background "black" :weight bold :extend t)) (t (:italic t :stipple "gray1"))) "Face for highlighting odd-numbered non-current differences in the ancestor buffer." :group 'ediff-highlighting) diff --git a/lisp/vc/log-view.el b/lisp/vc/log-view.el index 3389264ce6..054c2b9134 100644 --- a/lisp/vc/log-view.el +++ b/lisp/vc/log-view.el @@ -196,14 +196,14 @@ If it is nil, `log-view-toggle-entry-display' does nothing.") (defface log-view-file '((((class color) (background light)) - (:background "grey70" :weight bold)) + (:background "grey70" :weight bold :extend t)) (t (:weight bold))) "Face for the file header line in `log-view-mode'." :group 'log-view) (defface log-view-message '((((class color) (background light)) - (:background "grey85")) + (:background "grey85" :extend t)) (t (:weight bold))) "Face for the message header line in `log-view-mode'." :group 'log-view) diff --git a/lisp/vc/smerge-mode.el b/lisp/vc/smerge-mode.el index f032b08416..6d2d3f8d42 100644 --- a/lisp/vc/smerge-mode.el +++ b/lisp/vc/smerge-mode.el @@ -77,9 +77,9 @@ Used in `smerge-diff-base-upper' and related functions." (defface smerge-upper '((((class color) (min-colors 88) (background light)) - :background "#ffdddd") + :background "#ffdddd" :extend t) (((class color) (min-colors 88) (background dark)) - :background "#553333") + :background "#553333" :extend t) (((class color)) :foreground "red")) "Face for the `upper' version of a conflict.") @@ -88,9 +88,9 @@ Used in `smerge-diff-base-upper' and related functions." (defface smerge-lower '((((class color) (min-colors 88) (background light)) - :background "#ddffdd") + :background "#ddffdd" :extend t) (((class color) (min-colors 88) (background dark)) - :background "#335533") + :background "#335533" :extend t) (((class color)) :foreground "green")) "Face for the `lower' version of a conflict.") @@ -99,9 +99,9 @@ Used in `smerge-diff-base-upper' and related functions." (defface smerge-base '((((class color) (min-colors 88) (background light)) - :background "#ffffaa") + :background "#ffffaa" :extend t) (((class color) (min-colors 88) (background dark)) - :background "#888833") + :background "#888833" :extend t) (((class color)) :foreground "yellow")) "Face for the base code.") @@ -109,9 +109,9 @@ Used in `smerge-diff-base-upper' and related functions." (defface smerge-markers '((((background light)) - (:background "grey85")) + (:background "grey85" :extend t)) (((background dark)) - (:background "grey30"))) + (:background "grey30" :extend t))) "Face for the conflict markers.") (defvar smerge-markers-face 'smerge-markers) commit ab7db2814f6bf0a02d533d2cbf1a3d5160a7a007 Author: Glenn Morris Date: Sat Oct 19 11:26:34 2019 -0700 * lisp/net/tramp.el (tramp-antispoof-regexp): Fix version. diff --git a/lisp/net/tramp.el b/lisp/net/tramp.el index 6c17ef0b34..95ca6e3e2a 100644 --- a/lisp/net/tramp.el +++ b/lisp/net/tramp.el @@ -643,7 +643,7 @@ The answer will be provided by `tramp-action-terminal', which see." (defcustom tramp-antispoof-regexp (regexp-quote "Access granted. Press Return to begin session. ") "Regular expression matching plink's anti-spoofing message." - :version 27.1 + :version "27.1" :type 'regexp) (defcustom tramp-operation-not-permitted-regexp commit 278b7c1b52be11e8c49b8252953e8e84d45765c3 Author: Alan Mackenzie Date: Sat Oct 19 18:21:25 2019 +0000 Don't downcase the key binding in global-set-key. This fixes bug #37769. * lisp/subr.el (global-set-key): Provide a non-nil DONT-DOWNCASE argument to read-key-sequence. * etc/NEWS: Add an entry for this change. diff --git a/etc/NEWS b/etc/NEWS index 5794af5b60..fd46360ed2 100644 --- a/etc/NEWS +++ b/etc/NEWS @@ -461,6 +461,11 @@ RGB triplets with a single hexadecimal digit per component. Note that this key binding will not work on MS-Windows systems if 'w32-scroll-lock-modifier' is non-nil. +--- +** 'global-set-key', called interactively, now no longer downcases a +key binding with an upper case letter - if you can type it, you can +bind it. + * Editing Changes in Emacs 27.1 diff --git a/lisp/subr.el b/lisp/subr.el index 1a4a2e8b81..f3371dd2d7 100644 --- a/lisp/subr.el +++ b/lisp/subr.el @@ -1120,7 +1120,7 @@ that local binding will continue to shadow any global binding that you make with this function." (interactive (let* ((menu-prompting nil) - (key (read-key-sequence "Set key globally: "))) + (key (read-key-sequence "Set key globally: " nil t))) (list key (read-command (format "Set key %s to command: " (key-description key)))))) commit 2385dddb3338fd0f34aac0633dde78dd650f7d94 Author: Eli Zaretskii Date: Sat Oct 19 18:05:44 2019 +0300 Fix a recent change in Emacs FAQ * doc/misc/efaq.texi (New in Emacs 23, Common requests): Remove references to the removed section "Highlighting a region". diff --git a/doc/misc/efaq.texi b/doc/misc/efaq.texi index 3df30957c4..4a98379fc2 100644 --- a/doc/misc/efaq.texi +++ b/doc/misc/efaq.texi @@ -1268,7 +1268,7 @@ Directory-local variables can now be defined, in a similar manner to file-local variables. @item -Transient Mark mode (@pxref{Highlighting a region}) is on by default. +Transient Mark mode is on by default. @end itemize @@ -1428,7 +1428,6 @@ of files from Macintosh, Microsoft, and Unix platforms. * Displaying the current file name in the titlebar:: * Turning on abbrevs by default:: * Associating modes with files:: -* Highlighting a region:: * Replacing highlighted text:: * Controlling case sensitivity:: * Working with unprintable characters:: commit 5ea28ea4d12140ebcfaa293b6f29521a80b3de25 Author: Michael Albinus Date: Sat Oct 19 15:25:45 2019 +0200 * doc/emacs/emacs.texi (Intro): Mention remote file editing. diff --git a/doc/emacs/emacs.texi b/doc/emacs/emacs.texi index 28a0f562f8..a7967ecaee 100644 --- a/doc/emacs/emacs.texi +++ b/doc/emacs/emacs.texi @@ -1517,10 +1517,11 @@ is not silent.) We call Emacs @dfn{advanced} because it can do much more than simple insertion and deletion of text. It can control subprocesses, indent -programs automatically, show multiple files at once, and more. -Emacs editing commands operate in terms of characters, words, lines, -sentences, paragraphs, and pages, as well as expressions and comments -in various programming languages. +programs automatically, show multiple files at once, edit remote files +like they were local files, and more. Emacs editing commands operate +in terms of characters, words, lines, sentences, paragraphs, and +pages, as well as expressions and comments in various programming +languages. @dfn{Self-documenting} means that at any time you can use special commands, known as @dfn{help commands}, to find out what your options commit 981c309325d55e8c5947274e4df6346ea51a056a Author: Stefan Kangas Date: Sat Oct 19 15:04:13 2019 +0200 Don't explain FTP acronym in FAQ * doc/misc/efaq.texi (Common acronyms): Remove explanation of the FTP acronym. Emacs is no longer distributed over FTP, and the FAQ doesn't refer to any other FTP URLs. diff --git a/doc/misc/efaq.texi b/doc/misc/efaq.texi index a8d03cca74..3df30957c4 100644 --- a/doc/misc/efaq.texi +++ b/doc/misc/efaq.texi @@ -280,13 +280,12 @@ For information on some of the files in the @file{etc} directory, @pxref{Informational files for Emacs}. @node Common acronyms -@section What are FSF, GNU, RMS, FTP, and GPL? +@section What are FSF, GNU, RMS, and GPL? @cindex FSF, definition of @cindex GNU, definition of @cindex RMS, definition of @cindex Stallman, Richard, acronym for @cindex Richard Stallman, acronym for -@cindex FTP, definition of @cindex GPL, definition of @cindex Acronyms, definitions for @cindex Common acronyms, definitions for @@ -302,9 +301,6 @@ GNU's Not Unix @item RMS Richard Matthew Stallman -@item FTP -File Transfer Protocol - @item GPL GNU General Public License commit 11c3ec3df6ad79ee5175094f0cf14248d9724aa2 Author: Stefan Kangas Date: Fri Oct 18 22:55:56 2019 +0200 Remove FAQ section "Highlighting a region" (Bug#37818) * doc/misc/efaq.texi (Highlighting a region): Remove section. diff --git a/doc/misc/efaq.texi b/doc/misc/efaq.texi index bb79b6c837..a8d03cca74 100644 --- a/doc/misc/efaq.texi +++ b/doc/misc/efaq.texi @@ -1765,23 +1765,6 @@ determines which interpreter you're using by examining the first line of the script. Use @kbd{C-h v} (or @kbd{M-x describe-variable}) on @code{interpreter-mode-alist} to learn more. -@node Highlighting a region -@section How can I highlight a region of text in Emacs? -@cindex Highlighting text -@cindex Text, highlighting -@cindex @code{transient-mark-mode} -@cindex Region, highlighting a - -You can cause the region to be highlighted when the mark is active by -including - -@lisp -(transient-mark-mode 1) -@end lisp - -@noindent -in your @file{.emacs} file. Since Emacs 23.1, this feature is on by default. - @node Replacing highlighted text @section How can I replace highlighted text with what I type? @cindex @code{delete-selection-mode} commit 21f5bd6154f254a53942a9823c9c708ffa4b22a4 Author: Michael Albinus Date: Sat Oct 19 14:23:21 2019 +0200 Support PuTTY's antispoof message in Tramp * lisp/net/tramp-sh.el (tramp-actions-before-shell): Add respective entry for PuTTY's antispoof message. * lisp/net/tramp.el (tramp-antispoof-regexp): New defcustom. (tramp-action-confirm-message): New defun. diff --git a/lisp/net/tramp-sh.el b/lisp/net/tramp-sh.el index e92b9d7729..26254f87fe 100644 --- a/lisp/net/tramp-sh.el +++ b/lisp/net/tramp-sh.el @@ -556,6 +556,7 @@ shell from reading its init file." (tramp-yesno-prompt-regexp tramp-action-yesno) (tramp-yn-prompt-regexp tramp-action-yn) (tramp-terminal-prompt-regexp tramp-action-terminal) + (tramp-antispoof-regexp tramp-action-confirm-message) (tramp-process-alive-regexp tramp-action-process-alive)) "List of pattern/action pairs. Whenever a pattern matches, the corresponding action is performed. diff --git a/lisp/net/tramp.el b/lisp/net/tramp.el index 6ff313e8fb..6c17ef0b34 100644 --- a/lisp/net/tramp.el +++ b/lisp/net/tramp.el @@ -636,6 +636,16 @@ The regexp should match at end of buffer. The answer will be provided by `tramp-action-terminal', which see." :type 'regexp) +;; Plink 0.71 has added an additional anti-spoofing prompt after +;; authentication. This could be discarded with the argument +;; \"-no-antispoof\". However, since we don't know which PuTTY +;; version is installed, we must react interactively. +(defcustom tramp-antispoof-regexp + (regexp-quote "Access granted. Press Return to begin session. ") + "Regular expression matching plink's anti-spoofing message." + :version 27.1 + :type 'regexp) + (defcustom tramp-operation-not-permitted-regexp (concat "\\(" "preserving times.*" "\\|" "set mode" "\\)" ":\\s-*" (regexp-opt '("Operation not permitted") t)) @@ -3935,6 +3945,13 @@ The terminal type can be configured with `tramp-terminal-type'." (tramp-send-string vec (concat tramp-terminal-type tramp-local-end-of-line)) t) +(defun tramp-action-confirm-message (_proc vec) + "Return RET in order to confirm the message." + (with-current-buffer (tramp-get-connection-buffer vec) + (tramp-message vec 6 "\n%s" (buffer-string))) + (tramp-send-string vec tramp-local-end-of-line) + t) + (defun tramp-action-process-alive (proc _vec) "Check, whether a process has finished." (unless (process-live-p proc) commit ba8944bba8aaa58d60af955a8ea676a5260af346 Author: Raimon Grau Date: Sat Oct 19 11:46:17 2019 +0200 Fix optional parameter passing in calc-fin-* functions * lisp/calc/calc-fin.el (calc-fin-pv, calc-fin-fv, calc-fin-pmt) (calc-fin-pner, calc-fin-rate): Add support for an optional parameter standing for an initial lump. The functions already support it but the extra parameter was not taken into account in stack mode. This commit it takes into consideration when deciding if a function takes 3 or 4 parameters (bug#37649). diff --git a/lisp/calc/calc-fin.el b/lisp/calc/calc-fin.el index 813da2869e..4302cbcf5a 100644 --- a/lisp/calc/calc-fin.el +++ b/lisp/calc/calc-fin.el @@ -35,9 +35,10 @@ (calc-slow-wrapper (if (calc-is-hyperbolic) (calc-enter-result 3 "pvl" (cons 'calcFunc-pvl (calc-top-list-n 3))) - (if (calc-is-inverse) - (calc-enter-result 3 "pvb" (cons 'calcFunc-pvb (calc-top-list-n 3))) - (calc-enter-result 3 "pv" (cons 'calcFunc-pv (calc-top-list-n 3))))))) + (let ((n (if (calc-is-option) 4 3))) + (if (calc-is-inverse) + (calc-enter-result n "pvb" (cons 'calcFunc-pvb (calc-top-list-n n))) + (calc-enter-result n "pv" (cons 'calcFunc-pv (calc-top-list-n n)))))))) (defun calc-fin-npv (arg) (interactive "p") @@ -51,42 +52,48 @@ (calc-slow-wrapper (if (calc-is-hyperbolic) (calc-enter-result 3 "fvl" (cons 'calcFunc-fvl (calc-top-list-n 3))) - (if (calc-is-inverse) - (calc-enter-result 3 "fvb" (cons 'calcFunc-fvb (calc-top-list-n 3))) - (calc-enter-result 3 "fv" (cons 'calcFunc-fv (calc-top-list-n 3))))))) + (let ((n (if (calc-is-option) 4 3))) + (if (calc-is-inverse) + (calc-enter-result n "fvb" (cons 'calcFunc-fvb (calc-top-list-n n))) + (calc-enter-result n "fv" (cons 'calcFunc-fv (calc-top-list-n n)))))))) (defun calc-fin-pmt () (interactive) (calc-slow-wrapper (if (calc-is-hyperbolic) (calc-enter-result 3 "fvl" (cons 'calcFunc-fvl (calc-top-list-n 3))) - (if (calc-is-inverse) - (calc-enter-result 3 "pmtb" (cons 'calcFunc-pmtb (calc-top-list-n 3))) - (calc-enter-result 3 "pmt" (cons 'calcFunc-pmt (calc-top-list-n 3))))))) + (let ((n (if (calc-is-option) 4 3))) + (if (calc-is-inverse) + (calc-enter-result n "pmtb" (cons 'calcFunc-pmtb (calc-top-list-n n))) + (calc-enter-result n "pmt" (cons 'calcFunc-pmt (calc-top-list-n n)))))))) (defun calc-fin-nper () (interactive) (calc-slow-wrapper (if (calc-is-hyperbolic) (calc-enter-result 3 "nprl" (cons 'calcFunc-nperl (calc-top-list-n 3))) - (if (calc-is-inverse) - (calc-enter-result 3 "nprb" (cons 'calcFunc-nperb - (calc-top-list-n 3))) - (calc-enter-result 3 "nper" (cons 'calcFunc-nper - (calc-top-list-n 3))))))) + (let ((n (if (calc-is-option) 4 3))) + (if (calc-is-inverse) + (calc-enter-result n "nprb" (cons 'calcFunc-nperb + (calc-top-list-n n))) + (calc-enter-result n "nper" (cons 'calcFunc-nper + (calc-top-list-n n)))))))) (defun calc-fin-rate () (interactive) (calc-slow-wrapper - (calc-pop-push-record 3 - (if (calc-is-hyperbolic) "ratl" - (if (calc-is-inverse) "ratb" "rate")) - (calc-to-percentage - (calc-normalize - (cons (if (calc-is-hyperbolic) 'calcFunc-ratel - (if (calc-is-hyperbolic) 'calcFunc-rateb - 'calcFunc-rate)) - (calc-top-list-n 3))))))) + (let ((n (if (and (not (calc-is-hyperbolic)) + (calc-is-option)) + 4 3))) + (calc-pop-push-record n + (if (calc-is-hyperbolic) "ratl" + (if (calc-is-inverse) "ratb" "rate")) + (calc-to-percentage + (calc-normalize + (cons (if (calc-is-hyperbolic) 'calcFunc-ratel + (if (calc-is-hyperbolic) 'calcFunc-rateb + 'calcFunc-rate)) + (calc-top-list-n n)))))))) (defun calc-fin-irr (arg) (interactive "P") commit 842cc05d5ca5e54aef5c455a92203fd512e89202 Author: Lars Ingebrigtsen Date: Sat Oct 19 11:31:58 2019 +0200 Remove some compat code from cperl-mode.el * lisp/progmodes/cperl-mode.el: Remove old-Emacs compat code. diff --git a/lisp/progmodes/cperl-mode.el b/lisp/progmodes/cperl-mode.el index 3c06d23095..5d4cf96d4c 100644 --- a/lisp/progmodes/cperl-mode.el +++ b/lisp/progmodes/cperl-mode.el @@ -77,43 +77,17 @@ (eval-when-compile (require 'cl-lib)) +(defvar msb-menu-cond) +(defvar gud-perldb-history) (defvar vc-rcs-header) (defvar vc-sccs-header) -(eval-when-compile - (condition-case nil - (require 'custom) - (error nil)) - (condition-case nil - (require 'man) - (error nil)) - (defvar msb-menu-cond) - (defvar gud-perldb-history) - (defmacro cperl-is-face (arg) ; Takes quoted arg - (cond ((fboundp 'find-face) - `(find-face ,arg)) - (;;(and (fboundp 'face-list) - ;; (face-list)) - (fboundp 'face-list) - `(member ,arg (and (fboundp 'face-list) - (face-list)))) - (t - `(boundp ,arg)))) - (defmacro cperl-make-face (arg descr) ; Takes unquoted arg - (cond ((fboundp 'make-face) - `(make-face (quote ,arg))) - (t - `(defvar ,arg (quote ,arg) ,descr)))) - (defmacro cperl-force-face (arg descr) ; Takes unquoted arg - `(progn - (or (cperl-is-face (quote ,arg)) - (cperl-make-face ,arg ,descr)) - (or (boundp (quote ,arg)) ; We use unquoted variants too - (defvar ,arg (quote ,arg) ,descr)))) - (defmacro cperl-etags-snarf-tag (_file _line) - '(etags-snarf-tag)) - (defmacro cperl-etags-goto-tag-location (elt) - `(etags-goto-tag-location ,elt))) +(defmacro cperl-force-face (arg descr) ; Takes unquoted arg + `(progn + (or (facep (quote ,arg)) + (make-face ,arg)) + (or (boundp (quote ,arg)) ; We use unquoted variants too + (defvar ,arg (quote ,arg) ,descr)))) (defun cperl-choose-color (&rest list) (let (answer) @@ -5788,10 +5762,10 @@ indentation and initial hashes. Behaves usually outside of comment." font-lock-variable-name-face) ; Just to put something t) ("\\(@\\|\\$#\\)\\(\\$+\\([a-zA-Z_:][a-zA-Z0-9_:]*\\|[^ \t\n]\\)\\)" - (1 cperl-array-face) + (1 'cperl-array-face) (2 font-lock-variable-name-face)) ("\\(%\\)\\(\\$+\\([a-zA-Z_:][a-zA-Z0-9_:]*\\|[^ \t\n]\\)\\)" - (1 cperl-hash-face) + (1 'cperl-hash-face) (2 font-lock-variable-name-face)) ;;("\\([smy]\\|tr\\)\\([^a-z_A-Z0-9]\\)\\(\\([^\n\\]*||\\)\\)\\2") ;;; Too much noise from \s* @s[ and friends @@ -5907,10 +5881,6 @@ indentation and initial hashes. Behaves usually outside of comment." "Face for comments") (cperl-force-face font-lock-function-name-face "Face for function names") - (cperl-force-face cperl-hash-face - "Face for hashes") - (cperl-force-face cperl-array-face - "Face for arrays") ;;(defvar font-lock-constant-face 'font-lock-constant-face) ;;(defvar font-lock-variable-name-face 'font-lock-variable-name-face) ;;(or (boundp 'font-lock-type-face) @@ -5922,16 +5892,16 @@ indentation and initial hashes. Behaves usually outside of comment." ;; 'cperl-nonoverridable-face ;; "Face to use for data types from another group.")) (if (and - (not (cperl-is-face 'cperl-array-face)) - (cperl-is-face 'font-lock-emphasized-face)) + (not (facep 'cperl-array-face)) + (facep 'font-lock-emphasized-face)) (copy-face 'font-lock-emphasized-face 'cperl-array-face)) (if (and - (not (cperl-is-face 'cperl-hash-face)) - (cperl-is-face 'font-lock-other-emphasized-face)) + (not (facep 'cperl-hash-face)) + (facep 'font-lock-other-emphasized-face)) (copy-face 'font-lock-other-emphasized-face 'cperl-hash-face)) (if (and - (not (cperl-is-face 'cperl-nonoverridable-face)) - (cperl-is-face 'font-lock-other-type-face)) + (not (facep 'cperl-nonoverridable-face)) + (facep 'font-lock-other-type-face)) (copy-face 'font-lock-other-type-face 'cperl-nonoverridable-face)) ;;(or (boundp 'cperl-hash-face) ;; (defconst cperl-hash-face @@ -5942,10 +5912,10 @@ indentation and initial hashes. Behaves usually outside of comment." ;; 'cperl-array-face ;; "Face to use for arrays.")) (let ((background 'light)) - (and (not (cperl-is-face 'font-lock-constant-face)) - (cperl-is-face 'font-lock-reference-face) + (and (not (facep 'font-lock-constant-face)) + (facep 'font-lock-reference-face) (copy-face 'font-lock-reference-face 'font-lock-constant-face)) - (if (cperl-is-face 'font-lock-type-face) nil + (if (facep 'font-lock-type-face) nil (copy-face 'default 'font-lock-type-face) (cond ((eq background 'light) @@ -5960,7 +5930,7 @@ indentation and initial hashes. Behaves usually outside of comment." "pink"))) (t (set-face-background 'font-lock-type-face "gray90")))) - (if (cperl-is-face 'cperl-nonoverridable-face) + (if (facep 'cperl-nonoverridable-face) nil (copy-face 'font-lock-type-face 'cperl-nonoverridable-face) (cond @@ -5974,43 +5944,9 @@ indentation and initial hashes. Behaves usually outside of comment." (if (x-color-defined-p "orchid1") "orchid1" "orange"))))) - ;; (if (cperl-is-face 'font-lock-other-emphasized-face) nil - ;; (copy-face 'bold-italic 'font-lock-other-emphasized-face) - ;; (cond - ;; ((eq background 'light) - ;; (set-face-background 'font-lock-other-emphasized-face - ;; (if (x-color-defined-p "lightyellow2") - ;; "lightyellow2" - ;; (if (x-color-defined-p "lightyellow") - ;; "lightyellow" - ;; "light yellow")))) - ;; ((eq background 'dark) - ;; (set-face-background 'font-lock-other-emphasized-face - ;; (if (x-color-defined-p "navy") - ;; "navy" - ;; (if (x-color-defined-p "darkgreen") - ;; "darkgreen" - ;; "dark green")))) - ;; (t (set-face-background 'font-lock-other-emphasized-face "gray90")))) - ;; (if (cperl-is-face 'font-lock-emphasized-face) nil - ;; (copy-face 'bold 'font-lock-emphasized-face) - ;; (cond - ;; ((eq background 'light) - ;; (set-face-background 'font-lock-emphasized-face - ;; (if (x-color-defined-p "lightyellow2") - ;; "lightyellow2" - ;; "lightyellow"))) - ;; ((eq background 'dark) - ;; (set-face-background 'font-lock-emphasized-face - ;; (if (x-color-defined-p "navy") - ;; "navy" - ;; (if (x-color-defined-p "darkgreen") - ;; "darkgreen" - ;; "dark green")))) - ;; (t (set-face-background 'font-lock-emphasized-face "gray90")))) - (if (cperl-is-face 'font-lock-variable-name-face) nil + (if (facep 'font-lock-variable-name-face) nil (copy-face 'italic 'font-lock-variable-name-face)) - (if (cperl-is-face 'font-lock-constant-face) nil + (if (facep 'font-lock-constant-face) nil (copy-face 'italic 'font-lock-constant-face)))) (setq cperl-faces-init t)) (error (message "cperl-init-faces (ignored): %s" errs)))) @@ -6961,7 +6897,7 @@ Use as file (file-of-tag) fileind (format "%s:%s" file line) ;; Moves to beginning of the next line: - info (cperl-etags-snarf-tag file line)) + info (etags-snarf-tag)) ;; Move back (forward-char -1) ;; Make new member of hierarchy name ==> file ==> pos if needed @@ -7033,7 +6969,7 @@ One may build such TAGS files from CPerl mode menu." (if (vectorp update) (progn (find-file (elt update 0)) - (cperl-etags-goto-tag-location (elt update 1)))) + (etags-goto-tag-location (elt update 1)))) (if (eq update -999) (cperl-tags-hier-init t))) (defun cperl-tags-treeify (to level) commit 8dd18bbb6f3c09a4988cf2e06378aa24b098fb85 Author: Eli Zaretskii Date: Sat Oct 19 12:12:31 2019 +0300 Fix display of Info files on TTY frames * lisp/info.el (info-symbols-and-replacements): New variable. (Info-mode): Use 'info-symbols-and-replacements' to set up a buffer-display-table for non-ASCII symbols used by Info files that cannot be displayed on TTY frames. diff --git a/lisp/info.el b/lisp/info.el index fc0d58068a..951bdad4c2 100644 --- a/lisp/info.el +++ b/lisp/info.el @@ -4297,6 +4297,33 @@ With a zero prefix arg, put the name inside a function call to `info'." (defvar Info-mode-font-lock-keywords '(("‘\\([‘’]\\|[^‘’]*\\)’" (1 'Info-quoted)))) +;; See info-utils.c:degrade_utf8 in Texinfo for the source of the list +;; below. +(defvar info-symbols-and-replacements + '((?\‘ . "`") + (?\’ . "'") + (?\“ . "\"") + (?\” . "\"") + (?© . "(C)") + (?\》 . ">>") + (?→ . "->") + (?⇒ . "=>") + (?⊣ . "-|") + (?★ . "-!-") + (?↦ . "==>") + (?‐ . "-") + (?‑ . "-") + (?‒ . "-") + (?– . "-") + (?— . "--") + (?− . "-") + (?… . "...") + (?• . "*") + ) + "A list of Unicode symbols used in Info files and their ASCII translations. +Each element should be a cons cell with its car a character and its cdr +a string of ASCII characters.") + ;; Autoload cookie needed by desktop.el ;;;###autoload (define-derived-mode Info-mode nil "Info" ;FIXME: Derive from special-mode? @@ -4368,6 +4395,20 @@ Advanced commands: (setq case-fold-search t) (setq buffer-read-only t) (setq Info-tag-table-marker (make-marker)) + (unless (or (display-multi-font-p) + (coding-system-equal + (coding-system-base (terminal-coding-system)) + 'utf-8)) + (dolist (elt info-symbols-and-replacements) + (let ((ch (car elt)) + (repl (cdr elt))) + (or (char-displayable-p ch) + (aset (or buffer-display-table + (setq buffer-display-table (make-display-table))) + ch (vconcat (mapcar (lambda (c) + (make-glyph-code c 'homoglyph)) + repl))))))) + (if Info-use-header-line ; do not override global header lines (setq header-line-format '(:eval (get-text-property (point-min) 'header-line)))) commit a3726f057b6467d9c4ff0e09d4b86d89bdd380a4 Author: Lars Ingebrigtsen Date: Sat Oct 19 11:00:21 2019 +0200 Remove some compat code from CEDET * lisp/cedet/semantic.el (pp): * lisp/cedet/semantic/complete.el (initialize-instance): Remove old-Emacs compat code. diff --git a/lisp/cedet/semantic.el b/lisp/cedet/semantic.el index 0b878cae52..7d5017c620 100644 --- a/lisp/cedet/semantic.el +++ b/lisp/cedet/semantic.el @@ -368,8 +368,7 @@ to use Semantic, and `semantic-init-hook' is run." ;;; Parsing Commands ;; -(eval-when-compile - (condition-case nil (require 'pp) (error nil))) +(require 'pp) (defvar semantic-edebug nil "When non-nil, activate the interactive parsing debugger. diff --git a/lisp/cedet/semantic/complete.el b/lisp/cedet/semantic/complete.el index 14d2bd38ee..29f33d4a10 100644 --- a/lisp/cedet/semantic/complete.el +++ b/lisp/cedet/semantic/complete.el @@ -1666,10 +1666,7 @@ Display mechanism using tooltip for a list of possible completions.") (cl-defmethod initialize-instance :after ((obj semantic-displayer-tooltip) &rest args) "Make sure we have tooltips required." - (condition-case nil - (require 'tooltip) - (error nil)) - ) + (require 'tooltip)) (defvar tooltip-mode) commit 53774c45325c7307aeed340e53b851cbc7b7b242 Author: Lars Ingebrigtsen Date: Sat Oct 19 10:58:40 2019 +0200 Remove some compat code from mm-url.el * lisp/gnus/mm-url.el (mm-url-use-external): Remove old-Emacs compat code. diff --git a/lisp/gnus/mm-url.el b/lisp/gnus/mm-url.el index b53a1bcd30..b53f1e38b1 100644 --- a/lisp/gnus/mm-url.el +++ b/lisp/gnus/mm-url.el @@ -41,10 +41,7 @@ "A wrapper of url package and external url command for Gnus." :group 'gnus) -(defcustom mm-url-use-external (not - (condition-case nil - (require 'url) - (error nil))) +(defcustom mm-url-use-external nil "If non-nil, use external grab program `mm-url-program'." :version "22.1" :type 'boolean commit 480a03ba8f659c687f7e408a632325e0b7d658ad Author: Lars Ingebrigtsen Date: Sat Oct 19 10:57:33 2019 +0200 Remove compat code from nnbabyl.el * lisp/gnus/nnbabyl.el (rmail): Remove old-Emacs compat code. diff --git a/lisp/gnus/nnbabyl.el b/lisp/gnus/nnbabyl.el index 46d5244607..aa48dbd0fa 100644 --- a/lisp/gnus/nnbabyl.el +++ b/lisp/gnus/nnbabyl.el @@ -29,10 +29,7 @@ ;;; Code: (require 'nnheader) -(condition-case nil - (require 'rmail) - (error (nnheader-message - 5 "Ignore rmail errors from this file, you don't have rmail"))) +(require 'rmail) (require 'nnmail) (require 'nnoo) (eval-when-compile (require 'cl-lib)) commit 842518a0dbc1f84705784f9a34ab9dd2cf29015e Author: Lars Ingebrigtsen Date: Sat Oct 19 10:54:09 2019 +0200 Remove some compat code in imap.el * lisp/net/imap.el (imap-sasl-auth-p): Remove old-Emacs compat code. diff --git a/lisp/net/imap.el b/lisp/net/imap.el index 71d19185ff..4601e84b22 100644 --- a/lisp/net/imap.el +++ b/lisp/net/imap.el @@ -904,10 +904,8 @@ t if it successfully authenticates, nil otherwise." (declare-function sasl-step-set-data "sasl" (step data)) (defun imap-sasl-auth-p (buffer) - (and (condition-case () - (require 'sasl) - (error nil)) - (sasl-find-mechanism (imap-sasl-make-mechanisms buffer)))) + (require 'sasl) + (sasl-find-mechanism (imap-sasl-make-mechanisms buffer))) (defun imap-sasl-auth (buffer) "Login to server using the SASL method." commit fc6de411a7afeeb197eef0a23b83a5ea9a14bbc6 Author: Hong Xu Date: Sat Oct 19 10:43:37 2019 +0200 special-mode doc string clarification * lisp/simple.el (special-mode): Make the doc string explain what special modes are for (bug#37787). diff --git a/lisp/simple.el b/lisp/simple.el index cd674c36e7..338f3e3fd8 100644 --- a/lisp/simple.el +++ b/lisp/simple.el @@ -474,7 +474,10 @@ Other major modes are defined by comparison with this one." (put 'special-mode 'mode-class 'special) (define-derived-mode special-mode nil "Special" - "Parent major mode from which special major modes should inherit." + "Parent major mode from which special major modes should inherit. + +A special major mode is intended to view specially formatted data +rather than files. These modes usually use read-only buffers." (setq buffer-read-only t)) ;; Making and deleting lines.