]> git.eshelyaron.com Git - emacs.git/log
emacs.git
3 years agoRevert VC-related prefix user options to previous values
Lars Ingebrigtsen [Thu, 18 Nov 2021 11:11:35 +0000 (12:11 +0100)]
Revert VC-related prefix user options to previous values

* lisp/vc/smerge-mode.el (smerge-command-prefix):
* lisp/vc/pcvs.el (cvs-minor-mode-prefix):
* lisp/vc/diff-mode.el (diff-minor-mode-prefix): Revert to
previous values, as external packages rely on those values.

3 years agoFix `narrow-to-defun' in "async function" in js-mode
Lars Ingebrigtsen [Thu, 18 Nov 2021 10:25:18 +0000 (11:25 +0100)]
Fix `narrow-to-defun' in "async function" in js-mode

* lisp/progmodes/js.el (js--plain-method-re):
(js--function-prologue-beginning):
(js--ensure-cache): Allow "async" before "function" (bug#51926).
This makes `narrow-to-defun' work as expected.

3 years agoFix eldoc usage of newly introduced variable
Greg Minshall [Thu, 18 Nov 2021 09:32:34 +0000 (10:32 +0100)]
Fix eldoc usage of newly introduced variable

* lisp/emacs-lisp/eldoc.el
(eldoc-display-message-no-interference-p): Make this function work
in older Emacs versions again (bug#51939).

3 years ago; * src/macfont.m: fix typing errors
Mattias Engdegård [Thu, 18 Nov 2021 09:01:17 +0000 (10:01 +0100)]
; * src/macfont.m: fix typing errors

3 years agoMake the optional describe-map-tree parameters optional
Lars Ingebrigtsen [Wed, 17 Nov 2021 08:29:06 +0000 (09:29 +0100)]
Make the optional describe-map-tree parameters optional

* lisp/help.el (describe-map-tree): Make the optional parameters
optional.  This makes testing easier.

3 years agoDon't ignore restriction in indent-region-line-by-line
Miha Rihtaršič [Wed, 17 Nov 2021 08:12:21 +0000 (09:12 +0100)]
Don't ignore restriction in indent-region-line-by-line

* lisp/indent.el (indent-according-to-mode): Don't widen if the new
optional argument is non-nil.
(indent-region): Explicitly widen before calling
indent-region-line-by-line.
(indent-region-line-by-line): Don't widen (bug#51892).

Emacs convention is that low-level functions should respect restriction
so that their callers can set restriction according to their needs. For
example, 'c-indent-region' is a lower-level function which respects the
current restriction and 'indent-region' is a higher-level user command
which sets the restriction for lower-level functions, it calls
"(widen)".

'indent-region-line-by-line' is a low-level function on a similar level
as 'c-indent-region'. This patch makes it respect the current
restriction instead of having it call "(widen)".

3 years agoFix two failing tests in mh-utils-tests
Mike Kupfer [Thu, 18 Nov 2021 04:25:50 +0000 (20:25 -0800)]
Fix two failing tests in mh-utils-tests

* test/lisp/mh-e/mh-utils-tests.el
(mh-test-utils-mock-call-process): Add mock for root folders.
(mh-folder-completion-function-08-plus-slash)
(mh-folder-completion-function-09-plus-slash-tmp): Skip these tests
with Mailutils, which doesn't handle root folders.  (Bug#51902)

3 years agoRevert "* lisp/image-dired.el: Remove unnecessary 'declare-function'."
Stefan Kangas [Wed, 17 Nov 2021 23:58:26 +0000 (00:58 +0100)]
Revert "* lisp/image-dired.el: Remove unnecessary 'declare-function'."

This reverts commit e0261d4a0cf2a23d32b51b84870a3a75f8273c7c.

This commit gives warnings on builds --without-x.
Problem pointed out by Glenn Morris <rgm@gnu.org> in:
https://lists.gnu.org/r/emacs-devel/2021-11/msg01278.html

3 years agoFix recent changes related to USABLE_SIGIO
Eli Zaretskii [Wed, 17 Nov 2021 18:33:40 +0000 (20:33 +0200)]
Fix recent changes related to USABLE_SIGIO

* src/process.c (wait_reading_process_output) [WINDOWSNT]:
* src/keyboard.c (handle_async_input) [DOS_NT]: Ifdef away the
code that is not needed on MS-Windows.  (Bug#50403) (Bug#51820)

3 years agoMake process_pending_signals useful on systems without SIGIO
Ken Brown [Wed, 17 Nov 2021 18:02:44 +0000 (13:02 -0500)]
Make process_pending_signals useful on systems without SIGIO

* src/keyboard.c (handle_async_input): Call gobble_input
unconditionally, not just if USABLE_SIGIO is defined.  This makes
process_pending_signals do something useful on systems that have
to poll for input.  (Bug#51820)

3 years agoAvoid delays waiting for input on systems without SIGIO
Ken Brown [Wed, 17 Nov 2021 16:55:39 +0000 (11:55 -0500)]
Avoid delays waiting for input on systems without SIGIO

* src/process.c (wait_reading_process_output) [!USABLE_SIGIO]: If
we're waiting for input, don't use a timeout of more than 25 msec
in the call to select.  (Bug#50043)

3 years agoPrevent subprocess hangs in xwidget
Po Lu [Wed, 17 Nov 2021 13:30:20 +0000 (21:30 +0800)]
Prevent subprocess hangs in xwidget

* src/xwidget.c (Fmake_xwidget, Fxwidget_webkit_goto_url): Use
`catch_child_signal' instead of trying to preserve the previous
signal handler.

3 years agoUse substitute-command-keys in some messages
Stefan Kangas [Mon, 8 Mar 2021 09:56:51 +0000 (10:56 +0100)]
Use substitute-command-keys in some messages

* lisp/dired.el (dired-get-file-for-visit):
* lisp/doc-view.el (doc-view-buffer-message):
* lisp/help.el (help-window-setup):
* lisp/ibuf-ext.el (ibuffer-do-kill-lines):
* lisp/vc/ediff.el (ediff-documentation): Use 'substitute-command-keys'.

3 years agoDon't draw xwidgets that have just been resized
Po Lu [Wed, 17 Nov 2021 12:31:41 +0000 (20:31 +0800)]
Don't draw xwidgets that have just been resized

This serves to eliminate the huge black bar displayed when the
offscreen widget has been resized (and as such the damage event
signal is sent), but the X window hasn't.

* src/xwidget.c (xv_do_draw): Don't draw xwidgets that have
just been resized.
(x_draw_xwidget_glyph_string)
(xwidget_init_view): Clear just_resized.

(Fxwidget_resize): Set just_resized first, then queue allocate.

3 years agoIgnore some externally maintained files in AUTHORS
Stefan Kangas [Wed, 17 Nov 2021 11:08:56 +0000 (12:08 +0100)]
Ignore some externally maintained files in AUTHORS

* admin/authors.el (authors-ignored-files): Ignore externally
maintained files.

3 years ago* lisp/image-dired.el: Remove unnecessary 'declare-function'.
Stefan Kangas [Wed, 17 Nov 2021 10:46:14 +0000 (11:46 +0100)]
* lisp/image-dired.el: Remove unnecessary 'declare-function'.

3 years ago; * admin/MAINTAINERS: Add myself.
Stefan Kangas [Wed, 17 Nov 2021 09:49:19 +0000 (10:49 +0100)]
; * admin/MAINTAINERS: Add myself.

3 years agoChange the call signature to keymap-substitute
Lars Ingebrigtsen [Wed, 17 Nov 2021 07:34:32 +0000 (08:34 +0100)]
Change the call signature to keymap-substitute

* lisp/keymap.el (keymap-substitute): Make the keymap the first
parameter for symmetry with the other functions.
* lisp/emacs-lisp/shortdoc.el (keymaps):
* lisp/emacs-lisp/bytecomp.el (lambda): Adjust.

3 years agoMerge from origin/emacs-28
Stefan Kangas [Wed, 17 Nov 2021 07:20:55 +0000 (08:20 +0100)]
Merge from origin/emacs-28

fa0b34b716 * admin/authors.el (authors-ignored-files): Ignore some NE...
c25be3e7bb * lisp/tab-bar.el (tab-bar-select-tab): Add check for wc-f...
38d905abf9 * lisp/tab-bar.el: Doc fixes for commands bound to modifie...

3 years agoMake bookmark-set prompt less confusing
Lars Ingebrigtsen [Wed, 17 Nov 2021 07:16:58 +0000 (08:16 +0100)]
Make bookmark-set prompt less confusing

* lisp/bookmark.el (bookmark-set): Make the prompt less confusing
(bug#51876).

3 years agoFix mh-mime build problem
Lars Ingebrigtsen [Wed, 17 Nov 2021 07:14:23 +0000 (08:14 +0100)]
Fix mh-mime build problem

* lisp/mh-e/mh-mime.el (mh-acros): Require to get mh-dlet*.

3 years agoTemporarily mark two failing tests as unstable
Stefan Kangas [Wed, 17 Nov 2021 06:59:00 +0000 (07:59 +0100)]
Temporarily mark two failing tests as unstable

* test/lisp/mh-e/mh-utils-tests.el
(mh-folder-completion-function-08-plus-slash)
(mh-folder-completion-function-09-plus-slash-tmp): Temporarily
mark two failing tests as unstable.

3 years ago; * admin/automerge: Maintain.
Stefan Kangas [Wed, 17 Nov 2021 06:37:38 +0000 (07:37 +0100)]
; * admin/automerge: Maintain.

3 years agoFix bookmark-bmenu-mode-map syntax
Lars Ingebrigtsen [Wed, 17 Nov 2021 06:04:22 +0000 (07:04 +0100)]
Fix bookmark-bmenu-mode-map syntax

* lisp/bookmark.el (bookmark-bmenu-mode-map): Fix syntax in defvar-keymap.

3 years agoRemove some references to XEmacs
Stefan Kangas [Wed, 17 Nov 2021 05:25:50 +0000 (06:25 +0100)]
Remove some references to XEmacs

* lisp/emulation/viper-cmd.el (viper-start-R-mode):
* lisp/emulation/viper-init.el (viper-window-display-p):
* lisp/emulation/viper-mous.el (viper-surrounding-word):
* lisp/mail/footnote.el (footnote-mode):
* lisp/textmodes/reftex-index.el: Remove some comments referring to
XEmacs.

3 years agoMake mh-funcall-if-exists obsolete
Stefan Kangas [Wed, 17 Nov 2021 05:05:12 +0000 (06:05 +0100)]
Make mh-funcall-if-exists obsolete

* lisp/mh-e/mh-acros.el (mh-funcall-if-exists): Make obsolete.
* lisp/mh-e/mh-alias.el (mh-read-address):
* lisp/mh-e/mh-folder.el (mh-folder-mode):
* lisp/mh-e/mh-mime.el (mh-mm-display-part):
* lisp/mh-e/mh-show.el (mh-defun-show-buffer):
* lisp/mh-e/mh-speed.el (mh-speedbar-change-expand-button-char):
* lisp/mh-e/mh-tool-bar.el (mh-tool-bar-define):
* lisp/mh-e/mh-utils.el (mh-logo-display):
* lisp/mh-e/mh-xface.el (mh-face-display-function): Don't use
above obsolete macro.

3 years agoConvert keymaps in bookmark.el to defvar-keymap
Stefan Kangas [Wed, 17 Nov 2021 04:49:05 +0000 (05:49 +0100)]
Convert keymaps in bookmark.el to defvar-keymap

* lisp/bookmark.el (bookmark-map)
(bookmark-minibuffer-read-name-map)
(bookmark-edit-annotation-mode-map, bookmark-bmenu-mode-map):
Convert to defvar-keymap.

3 years ago* lisp/rot13.el (rot13-translate-table): Make it a `translation-table`
Stefan Monnier [Wed, 17 Nov 2021 03:48:37 +0000 (22:48 -0500)]
* lisp/rot13.el (rot13-translate-table): Make it a `translation-table`

(rot13-display-table): Use `dotimes`.

3 years ago* admin/authors.el (authors-ignored-files): Ignore some NEWS files.
Stefan Kangas [Wed, 17 Nov 2021 03:44:38 +0000 (04:44 +0100)]
* admin/authors.el (authors-ignored-files): Ignore some NEWS files.

3 years ago* admin/gitmerge.el (gitmerge-mode-map): Convert to defvar-keymap.
Stefan Kangas [Wed, 17 Nov 2021 03:14:33 +0000 (04:14 +0100)]
* admin/gitmerge.el (gitmerge-mode-map): Convert to defvar-keymap.

3 years agoUpdate xwidget webkit history buffer more eagerly
Po Lu [Wed, 17 Nov 2021 01:10:10 +0000 (09:10 +0800)]
Update xwidget webkit history buffer more eagerly

* lisp/xwidget.el (xwidget-webkit-callback): Update history
buffer on each load-changed event.

3 years agoOnly set LANG if the ID is valid
Alan Third [Sun, 14 Nov 2021 15:09:43 +0000 (15:09 +0000)]
Only set LANG if the ID is valid

* src/nsterm.m (ns_init_locale): Check the provided locale identifier
is available before trying to use it.

3 years ago* lisp/tab-bar.el (tab-bar-select-tab): Add check for wc-frame (bug#51883).
Juri Linkov [Tue, 16 Nov 2021 20:45:33 +0000 (22:45 +0200)]
* lisp/tab-bar.el (tab-bar-select-tab): Add check for wc-frame (bug#51883).

3 years ago* lisp/tab-bar.el: Doc fixes for commands bound to modifier keys.
Juri Linkov [Tue, 16 Nov 2021 20:40:45 +0000 (22:40 +0200)]
* lisp/tab-bar.el: Doc fixes for commands bound to modifier keys.

(tab-bar-select-tab-modifiers)
(tab-bar-select-tab, tab-bar-switch-to-last-tab): Doc fixes.

3 years agoMake keymap-unset work
Lars Ingebrigtsen [Tue, 16 Nov 2021 18:41:56 +0000 (19:41 +0100)]
Make keymap-unset work

* lisp/keymap.el (keymap-unset): Fix key syntax (bug#51897).

3 years agoPut back documentation of legacy keymap functions
Eli Zaretskii [Tue, 16 Nov 2021 17:14:04 +0000 (19:14 +0200)]
Put back documentation of legacy keymap functions

* doc/lispref/keymaps.texi (Low-Level Key Binding): Reinstate
documentation of legacy commands and functions.

3 years agoMerge branch 'master' of git.savannah.gnu.org:/srv/git/emacs
Eli Zaretskii [Tue, 16 Nov 2021 14:18:30 +0000 (16:18 +0200)]
Merge branch 'master' of git.savannah.gnu.org:/srv/git/emacs

3 years agoMinor copyedits of recent documentation changes
Eli Zaretskii [Tue, 16 Nov 2021 14:17:10 +0000 (16:17 +0200)]
Minor copyedits of recent documentation changes

* doc/lispref/keymaps.texi (Low-Level Key Binding): Minor changes
in wording and markup.

3 years agoSome minor Tramp updates
Michael Albinus [Tue, 16 Nov 2021 14:04:27 +0000 (15:04 +0100)]
Some minor Tramp updates

* lisp/net/tramp-crypt.el (tramp-crypt-add-directory): Add comment.

* lisp/net/tramp.el (tramp-debug-buffer-command-completion-p)
(tramp-setup-debug-buffer): New defuns.
(tramp-get-debug-buffer): Call `tramp-setup-debug-buffer.

* test/lisp/net/tramp-tests.el (tramp-test07-abbreviate-file-name):
Extend test.

3 years agoFix compilation error in previous keymap.c change
Lars Ingebrigtsen [Tue, 16 Nov 2021 13:10:50 +0000 (14:10 +0100)]
Fix compilation error in previous keymap.c change

* src/keymap.c (initial_define_lispy_key, define_as_prefix): Fix
--enable-checking error.

3 years agoLower xwidget views owned by parent when lowering frame
Po Lu [Tue, 16 Nov 2021 09:51:07 +0000 (17:51 +0800)]
Lower xwidget views owned by parent when lowering frame

* src/xterm.c (x_lower_frame): Lower parent frame's xwidget
views as well.

* src/xwidget.h (lower_frame_xwidget_views):
* src/xwidget.c (lower_frame_xwidget_views): New function.

3 years agoAdd command to browse xwidget history
Po Lu [Mon, 15 Nov 2021 05:12:45 +0000 (13:12 +0800)]
Add command to browse xwidget history

* doc/emacs/misc.texi (Embedded WebKit Widgets)
* etc/NEWS: Document `xwidget-webkit-browse-history'.

* lisp/xwidget.el (xwidget-webkit-mode-map): Bind "H" to
xwidget-webkit-browse-history.
(xwidget-webkit-import-widget): Set last session buffer correctly.
(xwidget-webkit-browse-history): New command.
(xwidget-webkit-history--session): New variable.

(xwidget-webkit-history--insert-item)
(xwidget-webkit-history-select-item)
(xwidget-webkit-history-reload): New functions.

(xwidget-webkit-history-mode): New major mode.

3 years agoNew X resource to control the border thickness of menus
Gregory Heytings [Tue, 16 Nov 2021 08:00:24 +0000 (09:00 +0100)]
New X resource to control the border thickness of menus

* lwlib/xlwmenu.h (XtNborderThickness, XtCBorderThickness): New X
resource name.
* lwlib/xlwmenuP.h (XlwMenuPart): New border_thickness field.
* lwlib/xlwmenu.c (xlwMenuResources): Access the new resource.
(draw_shadow_rectangle): Use the new resource value.
* doc/emacs/xresources.texi (Lucid Resources): Document the new
resource (bug#51867).

3 years agoMake results details in ert-run-tests-batch configurable
Michael Herstine [Tue, 16 Nov 2021 07:48:24 +0000 (08:48 +0100)]
Make results details in ert-run-tests-batch configurable

* lisp/emacs-lisp/ert.el (ert-batch-print-length)
(ert-batch-print-level,.ert-batch-backtrace-line-length)
(ert-batch-test, ert-run-tests-interactively): Added the three
variables, bound them to these settings when formatting batch
test results including backtraces. Removed the optional
parameters output-buffer & message-fn from
ert-run-tests-interactively.
* test/lisp/emacs-lisp/ert-tests.el
(ert-test-run-tests-interactively, ert-test-run-tests-batch): use
cl-letf to capture output, new tests resp.
* test/lisp/ert-x-tests.el (ert-test-run-tests-interactively-2):
Changed to use cl-letf to capture output instead of using
message-fn.
* lisp/emacs-lisp/backtrace.el (backtrace--line-length-or-nil)
(backtrace--print-func-and-args): Fixed a bug when setting
backtrace-line-length to nil by adding a new function to check
for that case & having backtrace--print-func-and-args use it.
* doc/misc/ert.texi: document the new variables & their usage
(bug#51037).

3 years agoStart adjusting the manuals to talk about the keymap-* functions
Lars Ingebrigtsen [Tue, 16 Nov 2021 07:23:53 +0000 (08:23 +0100)]
Start adjusting the manuals to talk about the keymap-* functions

* lisp/dired.el (dired--make-directory-clickable):
* doc/lispref/keymaps.texi (Keymaps):
(Key Sequences):
(Prefix Keys):
(Active Keymaps):
(Key Lookup):
(Functions for Key Lookup):
(Changing Key Bindings):
(Key Binding Commands):
(Tool Bar):
* doc/lispref/commands.texi (Interactive Codes):
(Event Examples):
(Event Mod):
* doc/emacs/kmacro.texi (Save Keyboard Macro):
* doc/emacs/custom.texi (Keymaps):
(Keymaps):
(Minibuffer Maps):
(Rebinding):
(Init Rebinding):
(Modifier Keys):
(Mouse Buttons):
(Init Examples):
(Init Non-ASCII): Adjust the documentation to remove description
of the old syntaxes, and use the new keymap-* functions.

* doc/lispref/keymaps.texi (Low-Level Key Binding): New node that
describes `define-key' and the old key syntaxes.

3 years agoAdjust `defvar-keymap' and `define-keymap' to the new syntax
Lars Ingebrigtsen [Tue, 16 Nov 2021 07:18:30 +0000 (08:18 +0100)]
Adjust `defvar-keymap' and `define-keymap' to the new syntax

* lisp/vc/smerge-mode.el (smerge-basic-map):
* lisp/vc/pcvs.el (cvs-mode-map):
(cvs-minor-mode-prefix):
* lisp/vc/log-view.el (log-view-mode-map):
* lisp/vc/log-edit.el (log-edit-mode-map):
* lisp/vc/diff-mode.el (diff-mode-shared-map):
(diff-minor-mode-prefix):
* lisp/vc/cvs-status.el (cvs-status-mode-map):
* lisp/simple.el (special-mode-map):
* lisp/outline.el (outline--insert-open-button):
(outline--insert-close-button):
* lisp/net/shr.el (shr-map):
* lisp/net/eww.el (eww-link-keymap):
(eww-mode-map):
(eww-submit-map):
(eww-bookmark-mode-map):
(eww-history-mode-map):
(eww-buffers-mode-map):
* lisp/mh-e/mh-speed.el (:keymap):
* lisp/mh-e/mh-show.el (:keymap):
* lisp/mh-e/mh-search.el (:keymap):
* lisp/mh-e/mh-letter.el (:keymap):
* lisp/mh-e/mh-folder.el (:keymap):
* lisp/international/emoji.el (emoji-list-mode-map):
* lisp/gnus/spam.el (:keymap):
* lisp/gnus/mml.el (mml-mode-map):
* lisp/gnus/message.el (message-mode-map):
* lisp/gnus/gnus-undo.el (gnus-undo-mode-map):
* lisp/gnus/gnus-topic.el (gnus-topic-mode-map):
* lisp/gnus/gnus-sum.el (:keymap):
* lisp/gnus/gnus-srvr.el (gnus-server-mode-map):
(gnus-browse-mode-map):
* lisp/gnus/gnus-salt.el (gnus-pick-mode-map):
(gnus-tree-mode-map):
* lisp/gnus/gnus-msg.el (:prefix):
* lisp/gnus/gnus-ml.el (gnus-mailing-list-mode-map):
* lisp/gnus/gnus-kill.el (gnus-kill-file-mode-map):
* lisp/gnus/gnus-html.el (gnus-html-displayed-image-map):
* lisp/gnus/gnus-group.el (:keymap):
* lisp/gnus/gnus-eform.el (gnus-edit-form-mode-map):
* lisp/gnus/gnus-draft.el (gnus-draft-mode-map):
* lisp/gnus/gnus-dired.el (gnus-dired-mode-map):
* lisp/gnus/gnus-bookmark.el (gnus-bookmark-bmenu-mode-map):
* lisp/gnus/gnus-art.el (:keymap):
(gnus-article-edit-mode-map):
* lisp/gnus/gnus-agent.el (gnus-agent-group-mode-map):
(gnus-agent-summary-mode-map):
(gnus-agent-server-mode-map):
(gnus-category-mode-map): Adjust `defvar-keymap' and
`define-keymap' to the new syntax.

3 years agoAdd new 'keymap-*' functions
Lars Ingebrigtsen [Tue, 16 Nov 2021 07:15:43 +0000 (08:15 +0100)]
Add new 'keymap-*' functions

* lisp/keymap.el: New file with all the new keymap-* functions.

* lisp/loadup.el ("keymap"): Load.

* lisp/subr.el (kbd): Refactor out all the code to key-parse.
(define-key-after, keyboard-translate, global-set-key)
(local-set-key, global-unset-key, local-unset-key)
(local-key-binding, global-key-binding)
(substitute-key-definition): Note in doc strings that these are
legacy functions.
(define-keymap--define): Use keymap-set.

* lisp/emacs-lisp/byte-opt.el: Remove the optimizations for
defvar-keymap and define-keymap since the macros now only
understand the kbd syntax.
* lisp/emacs-lisp/bytecomp.el (byte-compile-define-keymap)
(byte-compile-define-keymap--define): Warn about invalid key
definitions in all keymap-* functions.

* lisp/emacs-lisp/shortdoc.el (keymaps): Add shortdocs form
keymap* functions.

* src/keymap.c (possibly_translate_key_sequence): Adjust callers
to key-valid-p and key-parse.
(syms_of_keymap): Adjust defs.

3 years agoAllow removing keymap definitions
Lars Ingebrigtsen [Tue, 16 Nov 2021 07:02:22 +0000 (08:02 +0100)]
Allow removing keymap definitions

* src/keymap.c (initial_define_lispy_key): Adjust caller.
(store_in_keymap): Allow removing definitions in addition to
setting them to nil.
(Fdefine_key): Ditto.
(define_as_prefix): Adjust caller.

* src/term.c (term_get_fkeys_1): Adjust caller.

3 years agoMake erc-mode noninteractive
Lars Ingebrigtsen [Mon, 15 Nov 2021 09:07:11 +0000 (10:07 +0100)]
Make erc-mode noninteractive

* lisp/erc/erc.el (erc-mode): Mark it as noninteractive, because
using it from `M-x' will only lead to problems (bug#51841).

3 years agoMerge from origin/emacs-28
Stefan Kangas [Tue, 16 Nov 2021 06:18:19 +0000 (07:18 +0100)]
Merge from origin/emacs-28

e852822f3d Fix removal of fringe marks of deleted bookmarks
b418aad85a * lisp/repeat.el (repeat-echo-message): Bind message-log-m...
fe2ac7cb7c * lisp/repeat.el (describe-repeat-maps): Use help-fns--ana...
c840bfe7e1 * lisp/repeat.el: Detect changes in the minibuffer state (...
5044151486 Avoid segfaults due to freed face cache
199e2468d3 Doc fix; change recommended file name of custom-file

3 years agoFix handling of folder "+/" in MH-E
Mike Kupfer [Tue, 16 Nov 2021 06:03:54 +0000 (22:03 -0800)]
Fix handling of folder "+/" in MH-E

* lisp/mh-e/mh-utils.el (mh-sub-folders): Fix handling of "+/".
* test/lisp/mh-e/mh-utils-tests.el
(mh-folder-completion-function-08-plus-slash)
(mh-folder-completion-function-09-plus-slash-tmp):
Fix errors made importing tests from mh-unit.el; remove declaration
that these tests are expected to fail.

3 years agoFix checkdoc complaints in MH-E
Mike Kupfer [Tue, 16 Nov 2021 05:55:53 +0000 (21:55 -0800)]
Fix checkdoc complaints in MH-E

* lisp/mh-e/mh-compat.el (mh-flet): Rewrite most of the docstring.
(mh-write-file-functions): Remove trailing space.
* lisp/mh-e-mh-scan.el (mh-scan-cmd-note-width): Break up a
line that was too long.

3 years agoFix recently changed wdired test on MS-Windows
Stefan Kangas [Tue, 16 Nov 2021 04:06:48 +0000 (05:06 +0100)]
Fix recently changed wdired test on MS-Windows

* test/lisp/wdired-tests.el (wdired-test-bug34915): Don't try to
create a local socket on MS-Windows, as it is not supported on that
platform.  Problem reported by Robert Pluim <rpluim@gmail.com>.

3 years agoPrevent xwidget windows from obscuring child frames
Po Lu [Tue, 16 Nov 2021 01:30:32 +0000 (09:30 +0800)]
Prevent xwidget windows from obscuring child frames

* src/xwidget.c (x_draw_xwidget_glyph_string): Lower view window
when creating it.

3 years agoFix xwidget isearch for queries that look like format strings
Po Lu [Tue, 16 Nov 2021 01:25:55 +0000 (09:25 +0800)]
Fix xwidget isearch for queries that look like format strings

* lisp/xwidget.el (xwidget-webkit-isearch--update): Give special
treatment to messages.

3 years agoFix documentation string
Po Lu [Tue, 16 Nov 2021 01:08:43 +0000 (09:08 +0800)]
Fix documentation string

* src/xwidget.c (Vxwidget_list, Vxwidget_views_list): Fix
horrid doc string.

3 years agoFix removal of fringe marks of deleted bookmarks
Eli Zaretskii [Mon, 15 Nov 2021 18:20:30 +0000 (20:20 +0200)]
Fix removal of fringe marks of deleted bookmarks

* lisp/bookmark.el (bookmark--remove-fringe-mark): The fringe
overlay is at BOL, not at POS.  (Bug#51233)

3 years ago* lisp/repeat.el (repeat-echo-message): Bind message-log-max to nil.
Juri Linkov [Mon, 15 Nov 2021 17:53:29 +0000 (19:53 +0200)]
* lisp/repeat.el (repeat-echo-message): Bind message-log-max to nil.

Don't insert messages about repeatable keys in the *Messages* buffer.

3 years ago* lisp/repeat.el (describe-repeat-maps): Use help-fns--analyze-function.
Robert Pluim [Mon, 15 Nov 2021 17:50:30 +0000 (19:50 +0200)]
* lisp/repeat.el (describe-repeat-maps): Use help-fns--analyze-function.

Print keys bound to commands in every keymap (bug#49265)

3 years ago* lisp/repeat.el: Detect changes in the minibuffer state (bug#47566)
Juri Linkov [Mon, 15 Nov 2021 17:39:37 +0000 (19:39 +0200)]
* lisp/repeat.el: Detect changes in the minibuffer state (bug#47566)

(repeat--prev-mb): New internal variable.
(repeat-post-hook): Check the property 'repeat-map' on the symbol
from 'this-command' in addition to 'real-this-command'.  Don't allow
repeatable maps in the activated minibuffer or in the minibuffer
from another command.  Set 'repeat--prev-mb' at the end.

3 years agoFix minor problems resulting from Tramp regression tests
Michael Albinus [Mon, 15 Nov 2021 16:50:15 +0000 (17:50 +0100)]
Fix minor problems resulting from Tramp regression tests

* lisp/net/tramp-adb.el (tramp-adb-file-name-handler-alist):
* lisp/net/tramp-archive.el (tramp-archive-file-name-handler-alist):
* lisp/net/tramp-crypt.el (tramp-crypt-file-name-handler-alist):
* lisp/net/tramp-gvfs.el (tramp-gvfs-file-name-handler-alist):
* lisp/net/tramp-rclone.el (tramp-rclone-file-name-handler-alist):
* lisp/net/tramp-sshfs.el (tramp-sshfs-file-name-handler-alist):
Add comment.

* lisp/net/tramp-cache.el (tramp-flush-file-upper-properties):
FILE can be "~".

* lisp/net/tramp.el ('tramp-ensure-dissected-file-name):
Add `tramp-suppress-trace' property.
(tramp-get-debug-buffer): Add local key for debugging.
(tramp-handle-abbreviate-file-name): Adapt implementation.

* test/lisp/net/tramp-tests.el
(tramp-test07-abbreviate-file-name):
Adapt test.
(tramp-test17-insert-directory-one-file)
(tramp--test-check-files): Use proper `no-dir' argument for
`dired-get-filename'.

3 years agoAvoid segfaults due to freed face cache
Eli Zaretskii [Mon, 15 Nov 2021 13:35:31 +0000 (15:35 +0200)]
Avoid segfaults due to freed face cache

* src/xfaces.c (face_at_buffer_position): Make sure DEFAULT_FACE
is usable.  (Bug#51864)

3 years agoAdd another 'abbreviate-file-name' test
Jim Porter [Mon, 15 Nov 2021 12:34:00 +0000 (13:34 +0100)]
Add another 'abbreviate-file-name' test

* test/lisp/files-tests.el
(files-tests-file-name-non-special-abbreviate-file-name): New test.

3 years agoSupport abbreviating home directory of Tramp filenames
Jim Porter [Mon, 15 Nov 2021 12:33:07 +0000 (13:33 +0100)]
Support abbreviating home directory of Tramp filenames

* doc/lispref/files.texi (Magic File Names): Mention
'abbreviate-file-name' in the list of magic file name handlers.

* etc/NEWS: Announce the change.

* lisp/files.el (file-name-non-special):
* lisp/net/tramp.el (tramp-file-name-for-operation):
* lisp/net/tramp-sh.el (tramp-sh-file-name-handler-alist):
* lisp/net/tramp-smb.el (tramp-smb-file-name-handler-alist):
* lisp/net/tramp-sudoedit.el (tramp-sudoedit-file-name-handler-alist):
Add 'abbreviate-file-name'.

* lisp/files.el (directory-abbrev-make-regexp):
(directory-abbrev-apply): New functions.
(abbreviate-file-name): Check for file name handler.

* test/lisp/net/tramp-tests.el (tramp-test07-abbreviate-file-name):
New test.

3 years agoDoc fix; change recommended file name of custom-file
Stefan Kangas [Mon, 15 Nov 2021 09:58:53 +0000 (10:58 +0100)]
Doc fix; change recommended file name of custom-file

* lisp/cus-edit.el (custom-file): Change file name recommendation to
match Info node '(emacs) Saving Customizations'.

3 years agoFix hanging wdired test
Stefan Kangas [Mon, 15 Nov 2021 08:42:48 +0000 (09:42 +0100)]
Fix hanging wdired test

* test/lisp/wdired-tests.el (wdired-test-bug34915): Fix hanging
test.  Don't start the Emacs Server just to create a socket; just
create the socket manually.

3 years agoFix outline-cycle-buffer issue in `C-h b' buffers
Lars Ingebrigtsen [Mon, 15 Nov 2021 06:38:07 +0000 (07:38 +0100)]
Fix outline-cycle-buffer issue in `C-h b' buffers

* lisp/outline.el (outline--fix-up-all-buttons): Fix issue when
called after collapsing a buffer (bug#51855).

3 years agoAllow mm-external-terminal-program to be a list of strings
Lars Ingebrigtsen [Mon, 15 Nov 2021 06:16:49 +0000 (07:16 +0100)]
Allow mm-external-terminal-program to be a list of strings

* doc/misc/emacs-mime.texi (Display Customization): Document it.

* lisp/gnus/mm-decode.el (mm-external-terminal-program): Allow
being a list.

3 years agoFix handling of changed prefix keys in tutorial
Basil L. Contovounesios [Mon, 15 Nov 2021 05:52:38 +0000 (06:52 +0100)]
Fix handling of changed prefix keys in tutorial

* lisp/tutorial.el (tutorial--find-changed-keys): Use keymapp to
detect prefix definitions rather than hard-coding them.  A notable
omission from the hard-coded list was mode-specific-command-prefix,
whose subcommands are often rebound (bug#40725).

3 years agoMerge from origin/emacs-28
Stefan Kangas [Mon, 15 Nov 2021 06:00:24 +0000 (07:00 +0100)]
Merge from origin/emacs-28

044dd1e210 * rcirc.el (rcirc-define-command): Fix interactive-spec ge...

3 years ago; Merge from origin/emacs-28
Stefan Kangas [Mon, 15 Nov 2021 06:00:24 +0000 (07:00 +0100)]
; Merge from origin/emacs-28

The following commit was skipped:

97059bcdff Fix `C-h k' in gnus-article-mode (don't merge)

3 years agoMerge from origin/emacs-28
Stefan Kangas [Mon, 15 Nov 2021 06:00:24 +0000 (07:00 +0100)]
Merge from origin/emacs-28

85ac0efe7c Fix semantic-symref-perform-search doc string

3 years agoFix xwidget-webkit-back-forward-list
Po Lu [Mon, 15 Nov 2021 05:43:55 +0000 (13:43 +0800)]
Fix xwidget-webkit-back-forward-list

* src/xwidget.c (Fxwidget_webkit_back_forward_list): Use correct
list variable in loop.

3 years agoStop assuming xwidget views will only be displayed in TEXT_AREA
Po Lu [Mon, 15 Nov 2021 01:27:31 +0000 (09:27 +0800)]
Stop assuming xwidget views will only be displayed in TEXT_AREA

* src/xterm.c (x_scroll_run): Use view->area when calculating
xwidget view clipping.

* src/xwidget.c (x_draw_xwidget_glyph_string): Set view->area
to s->area and use that instead.

* src/xwidget.h (struct xwidget_view): Add glyph row area field.

3 years agoPrefer POSIX timers to timerfd timers
Ken Brown [Sun, 14 Nov 2021 15:30:44 +0000 (10:30 -0500)]
Prefer POSIX timers to timerfd timers

* src/atimer.c (set_alarm): Try to start a POSIX timer before
starting a timerfd timer.  On Cygwin, return if the POSIX timer is
started successfully. (Bug#51734)

3 years ago* rcirc.el (rcirc-define-command): Fix interactive-spec generation
Philip Kaludercic [Sun, 14 Nov 2021 18:41:31 +0000 (19:41 +0100)]
* rcirc.el (rcirc-define-command): Fix interactive-spec generation

* rcirc.el (rcirc-define-command):  Wrap interactive spec in a list call.

3 years ago* lisp/tab-line.el (tab-line-mode): Preserve existing value of tab-line-format
Juri Linkov [Sun, 14 Nov 2021 18:35:42 +0000 (20:35 +0200)]
* lisp/tab-line.el (tab-line-mode): Preserve existing value of tab-line-format

Keep the old value of tab-line-format when enabling tab-line-mode
and don't overwrite it with nil when disabling tab-line-mode (bug#51830).

3 years ago* src/lread.c (read_escape): Fix handling of ?\C-<char> for chars 128-255
Stefan Monnier [Sun, 14 Nov 2021 17:56:11 +0000 (12:56 -0500)]
* src/lread.c (read_escape): Fix handling of ?\C-<char> for chars 128-255

3 years agoFix `C-h k' in gnus-article-mode (don't merge)
Lars Ingebrigtsen [Sun, 14 Nov 2021 01:46:38 +0000 (02:46 +0100)]
Fix `C-h k' in gnus-article-mode (don't merge)

* lisp/gnus/gnus-art.el (gnus-article-describe-key):
(gnus-article-describe-key-briefly): Fix `describe-key' calling
convention (bug#51796).

3 years ago; Revert "* lisp/progmodes/python.el (python-forward-sexp-function): :version fix."
Eli Zaretskii [Sun, 14 Nov 2021 17:42:37 +0000 (19:42 +0200)]
; Revert "* lisp/progmodes/python.el (python-forward-sexp-function): :version fix."

This reverts commit e6e29b435273ee9821b6536581bd151f3e50737d.
The commit was a mistake.

3 years ago; * lisp/progmodes/python.el (python-forward-sexp-function): :version fix.
Eli Zaretskii [Sun, 14 Nov 2021 16:58:57 +0000 (18:58 +0200)]
; * lisp/progmodes/python.el (python-forward-sexp-function): :version fix.

3 years agoFix recent documentation updates
Eli Zaretskii [Sun, 14 Nov 2021 16:55:37 +0000 (18:55 +0200)]
Fix recent documentation updates

* doc/lispref/text.texi (Special Properties): Improve wording.
Add cross-reference and index entry.
(Sticky Properties): Add indexing.

3 years agoFix semantic-symref-perform-search doc string
Daniel Martín [Sun, 14 Nov 2021 14:30:52 +0000 (15:30 +0100)]
Fix semantic-symref-perform-search doc string

* lisp/cedet/semantic/symref/cscope.el (semantic-symref-perform-search):
Fix the docstring to refer to the correct tool (bug#51846).

3 years agoImprove Tramp error handling
Michael Albinus [Sun, 14 Nov 2021 13:41:58 +0000 (14:41 +0100)]
Improve Tramp error handling

* doc/misc/tramp.texi (Frequently Asked Questions): Add another
`remote-file-error'.

* lisp/net/tramp.el (tramp-find-foreign-file-name-handler):
Improve error handling.

3 years ago; Merge from origin/emacs-28
Eli Zaretskii [Sun, 14 Nov 2021 13:02:44 +0000 (15:02 +0200)]
; Merge from origin/emacs-28

The following commit was skipped:

289f3a9 Add more files to be natively-compiled AOT

3 years agoMerge from origin/emacs-28
Eli Zaretskii [Sun, 14 Nov 2021 13:02:42 +0000 (15:02 +0200)]
Merge from origin/emacs-28

5dbad52 gnus-summary-line-format doc string clarification
d4536ff Fix follow-scroll-down in a small buffer which starts slightl...

3 years ago; Merge from origin/emacs-28
Eli Zaretskii [Sun, 14 Nov 2021 13:02:41 +0000 (15:02 +0200)]
; Merge from origin/emacs-28

The following commits were skipped:

4802419 Fix compilation on MS-Windows
cc4edea Use posix_spawn if possible.

3 years agoMerge from origin/emacs-28
Eli Zaretskii [Sun, 14 Nov 2021 13:02:39 +0000 (15:02 +0200)]
Merge from origin/emacs-28

a56dd60 Improve style and comments in font-related sources

3 years agoAdd more files to be natively-compiled AOT
Eli Zaretskii [Sun, 14 Nov 2021 12:46:27 +0000 (14:46 +0200)]
Add more files to be natively-compiled AOT

* src/Makefile.in (elnlisp): Add emacs-lisp/gv.eln and other
missing dependencies of comp.el.

3 years agoExpose xwidget navigation history to Lisp code
Po Lu [Thu, 11 Nov 2021 01:01:38 +0000 (09:01 +0800)]
Expose xwidget navigation history to Lisp code

* doc/lispref/display.texi (Xwidgets): Document changes.
* etc/NEWS: Announce new function.
* src/xwidget.c (Fxwidget_webkit_back_forward_list): New
function.
(syms_of_xwidget): Define new subr.

3 years agoAdd `kill-xwidget'
Po Lu [Sun, 14 Nov 2021 05:02:41 +0000 (13:02 +0800)]
Add `kill-xwidget'

* doc/lispref/display.texi (Xwidgets): Document 'kill-xwidget'.
* src/xwidget.c (kill_xwidget, Fkill_xwidget): New function.
(syms_of_xwidget): Define new subr.
(kill_buffer_xwidgets): Use `kill_xwidget' instead.

3 years agoFix previous -responsible-p change
Lars Ingebrigtsen [Sun, 14 Nov 2021 08:41:22 +0000 (09:41 +0100)]
Fix previous -responsible-p change

* lisp/vc/vc-sccs.el (vc-sccs-responsible-p):
* lisp/vc/vc-rcs.el (vc-rcs-responsible-p):
* lisp/vc/vc-cvs.el (vc-cvs-responsible-p): Make the previous
change work with relative file names, too.

3 years agognus-summary-line-format doc string clarification
Lars Ingebrigtsen [Sun, 14 Nov 2021 03:54:40 +0000 (04:54 +0100)]
gnus-summary-line-format doc string clarification

* lisp/gnus/gnus.el (gnus-summary-line-format): Clarify the Date
part of the doc string (bug#51823).

3 years agoExplain in the manual how to make `cursor-intangible' work
Lars Ingebrigtsen [Sun, 14 Nov 2021 02:14:35 +0000 (03:14 +0100)]
Explain in the manual how to make `cursor-intangible' work

* doc/lispref/text.texi (Special Properties): Explain how to make
`cursor-intangible' work (bug#51095).

3 years agoFix crash in xwidget_end_redisplay
Po Lu [Sun, 14 Nov 2021 01:58:21 +0000 (09:58 +0800)]
Fix crash in xwidget_end_redisplay

* src/xwidget.c (xwidget_end_redisplay): Always test if xv is
NULL.

3 years agoFix `C-h k' in gnus-article-mode
Lars Ingebrigtsen [Sun, 14 Nov 2021 01:46:38 +0000 (02:46 +0100)]
Fix `C-h k' in gnus-article-mode

* lisp/gnus/gnus-art.el (gnus-article-describe-key):
(gnus-article-describe-key-briefly): Fix `describe-key' calling
convention (bug#51796).

3 years agoMake all vc-*-responsible-p functions return a string
Lars Ingebrigtsen [Sun, 14 Nov 2021 01:38:48 +0000 (02:38 +0100)]
Make all vc-*-responsible-p functions return a string

* lisp/vc/vc-sccs.el (vc-sccs-responsible-p):
* lisp/vc/vc-rcs.el (vc-rcs-responsible-p):
* lisp/vc/vc-dav.el (vc-dav-responsible-p):
* lisp/vc/vc-cvs.el (vc-cvs-responsible-p): Return a file name
instead of t when we get a match (which is what
vc-backend-for-registration expects) (bug#51800).

3 years agoFix customization group of python-forward-sexp-function
Kévin Le Gouguec [Sun, 14 Nov 2021 01:30:06 +0000 (02:30 +0100)]
Fix customization group of python-forward-sexp-function

* lisp/progmodes/python.el (python-forward-sexp-function): Move from
the "Flymake integration" subsection to the "Navigation" subsection,
so that the option is sorted into the 'python' group rather than the
'python-flymake' group (bug#51807).

3 years agoFix Gnus gcc header tokenization
Lars Ingebrigtsen [Sun, 14 Nov 2021 01:21:45 +0000 (02:21 +0100)]
Fix Gnus gcc header tokenization

* lisp/gnus/gnus-msg.el (gnus-summary-resend-message-insert-gcc)
(gnus-inews-do-gcc): Fix tokenization of the gcc header.

3 years agoAdjust build-dep-zips.py download link
Lars Ingebrigtsen [Sun, 14 Nov 2021 01:06:26 +0000 (02:06 +0100)]
Adjust build-dep-zips.py download link

* admin/nt/dist-build/build-dep-zips.py (download_source): Adjust
the download link (bug#40628).