Lars Ingebrigtsen [Tue, 5 Jul 2022 11:03:36 +0000 (13:03 +0200)]
Remove the interactive prefix from emoji-insert
* lisp/international/emoji.el (emoji-insert): Remove the prefix
action from this command, since the same is already available on
`C-x 8 e s', and we're considering using the prefix to copy to the
kill ring.
Po Lu [Tue, 5 Jul 2022 06:55:24 +0000 (14:55 +0800)]
Allow immediately saving XDS drops
This fixes things with programs that have a very timeout, such
as Chromium, within which it isn't practical for the user to
confirm the default file name.
* lisp/x-dnd.el (x-dnd-direct-save-function): Add new choices to
defcustom.
(x-dnd-init-frame): Use fast protocol requests.
(x-dnd-save-direct-immediately): New function.
(x-dnd-handle-xds-drop): Fix nil values of selected file name.
Paul Eggert [Tue, 5 Jul 2022 04:12:45 +0000 (23:12 -0500)]
Quote configure.ac arguments more consistently
This should help avoid further Autoconf portability gotchas such as
the one recently fixed in 2022-06-27T04:26:01Z!meyering@fb.com.
* autogen.sh (autoconf_min): Adjust pattern to match
updated configure.ac.
* configure.ac: Quote arguments more consistently,
as per the Autoconf manual.
Paul Eggert [Tue, 5 Jul 2022 04:23:59 +0000 (23:23 -0500)]
Don’t mishandle preset emacs_cv_lesstif
* configure.ac: Restore CFLAGS etc. correctly even when
emacs_cv_lesstif is already set on the command line.
Stefan Kangas [Tue, 5 Jul 2022 04:30:40 +0000 (06:30 +0200)]
Merge from origin/emacs-28
d5e1424174 Expand docstrings related to auto-saving
Stefan Kangas [Tue, 5 Jul 2022 04:30:40 +0000 (06:30 +0200)]
; Merge from origin/emacs-28
The following commits were skipped:
28c5c27162 Don't bug out in manual-html-fix-index-2 on newer makeinfo...
724f712ef1 Preserve <title> in the Emacs manuals
Po Lu [Tue, 5 Jul 2022 03:03:11 +0000 (11:03 +0800)]
Don't take XCB socket every time we want the no of the next request
* src/xterm.c (x_ignore_errors_for_next_request, x_uncatch_errors)
(x_check_errors, x_had_errors_p): Don't call XNextRequest
redundantly. Use NextRequest if it was immediately preceded by
XNextRequest, which updates dpy->request.
Stefan Kangas [Tue, 5 Jul 2022 02:57:51 +0000 (04:57 +0200)]
New command emacs-news-mode-open-line
* lisp/textmodes/emacs-news-mode.el
(emacs-news-mode-open-line): New command.
(emacs-news-mode-map): Remap 'open-line' to above new command.
Po Lu [Tue, 5 Jul 2022 02:40:32 +0000 (10:40 +0800)]
Improve support for remote files in XDS
* lisp/x-dnd.el (x-dnd-direct-save-function): Remove "local file
name" from documentation.
(x-dnd-save-direct): Handle remote file names normally.
(x-dnd-handle-xds-drop): Handle remote file names in URI.
Po Lu [Tue, 5 Jul 2022 02:12:19 +0000 (10:12 +0800)]
Don't overestimate supported input extension version on GTK 3
* src/xterm.c (x_term_init): If minor > original_minor (the
maximum version supported by libXi), set it back to
original_minor.
Alexander Adolf [Sat, 2 Jul 2022 15:27:55 +0000 (17:27 +0200)]
Add reverse mapping for EUDC attribute names
* lisp/net/eudc.el (eudc-translate-query): new optional parameter to
reverse the mapping direction
(eudc-translate-attribute-list): new optional parameter to
reverse the mapping direction
Stefan Monnier [Mon, 4 Jul 2022 22:44:03 +0000 (18:44 -0400)]
(gnus-inverse-list-range-intersection): Update alias
* lisp/gnus/gnus-range.el (gnus-inverse-list-range-intersection):
Don't alias to an obsolete alias.
Stefan Kangas [Mon, 4 Jul 2022 21:54:07 +0000 (23:54 +0200)]
Expand docstrings related to auto-saving
* lisp/files.el (auto-save-visited-mode):
* lisp/simple.el (auto-save-mode): Expand docstring.
Paul Eggert [Mon, 4 Jul 2022 21:21:35 +0000 (16:21 -0500)]
Fix core dump with x-get-local-selection
* src/xselect.c (Fx_get_local_selection): Check that VALUE has 4
elements, since x_get_local_selection can dump core otherwise.
This pacifies gcc -Wanalyzer-null-dereference, which found the
problem.
Stefan Kangas [Mon, 4 Jul 2022 16:44:24 +0000 (18:44 +0200)]
Add quit-window entry to list-timers menu
* lisp/emacs-lisp/timer-list.el (timer-list-mode-map): Add
quit-window entry to menu.
Stefan Kangas [Mon, 4 Jul 2022 16:42:26 +0000 (18:42 +0200)]
Prefer defvar-keymap in emacs-lisp/*.el
* lisp/emacs-lisp/backtrace.el (backtrace-mode-map):
* lisp/emacs-lisp/bytecomp.el (emacs-lisp-compilation-mode-map):
* lisp/emacs-lisp/checkdoc.el (checkdoc-minor-mode-map):
* lisp/emacs-lisp/crm.el (crm-local-completion-map)
(crm-local-must-match-map):
* lisp/emacs-lisp/debug.el (debugger-mode-map):
* lisp/emacs-lisp/edebug.el (edebug-mode-map, edebug-global-map)
(edebug-eval-mode-map):
* lisp/emacs-lisp/eieio-custom.el (eieio-custom-mode-map):
* lisp/emacs-lisp/elp.el (elp-results-symname-map):
* lisp/emacs-lisp/lisp-mode.el (lisp-mode-shared-map):
* lisp/emacs-lisp/re-builder.el (reb-mode-map)
(reb-lisp-mode-map, reb-subexp-mode-map):
* lisp/emacs-lisp/tabulated-list.el (tabulated-list-mode-map)
(tabulated-list-sort-button-map):
* lisp/emacs-lisp/timer-list.el (timer-list-mode-map):
Stefan Kangas [Mon, 4 Jul 2022 16:19:20 +0000 (18:19 +0200)]
Document using make-composed-keymap with defvar-keymap
* doc/lispref/keymaps.texi (Inheritance and Keymaps): Document
using 'make-composed-keymap' with 'defvar-keymap'.
* lisp/help-mode.el (help-mode-map): Use defvar-keymap to make this
code match the above documentation change.
Stefan Kangas [Mon, 4 Jul 2022 14:58:53 +0000 (16:58 +0200)]
; Fix warning in mwheel.el
* lisp/mwheel.el (global-text-scale-adjust): Declare function.
Stefan Kangas [Mon, 4 Jul 2022 14:54:38 +0000 (16:54 +0200)]
Doc fix; quote keys in face-remap.el
* lisp/face-remap.el (text-scale-adjust, global-text-scale-adjust):
Doc fix; quote keys.
Stefan Kangas [Mon, 4 Jul 2022 14:18:54 +0000 (16:18 +0200)]
Inherit instead of copying keymap in bookmark.el
* lisp/bookmark.el (bookmark-rename): Inherit instead of copying
keymap.
Stefan Kangas [Mon, 4 Jul 2022 14:02:26 +0000 (16:02 +0200)]
* src/keymap.c (Fcopy_keymap): Document using defvar-keymap.
Mattias Engdegård [Mon, 4 Jul 2022 13:54:14 +0000 (15:54 +0200)]
; remove regexp ambiguity
Stefan Kangas [Mon, 4 Jul 2022 13:45:18 +0000 (15:45 +0200)]
Use substitute-command-keys in Helper-help
* lisp/emacs-lisp/helper.el (Helper-help-scroller)
(Helper-help-options, Helper-help): Use substitute-command-keys.
(Helper-help-map): Prefer defvar-keymap.
Po Lu [Mon, 4 Jul 2022 13:03:02 +0000 (21:03 +0800)]
Avoid code duplication converting XI event state in toolkit menu code
* src/xmenu.c (x_menu_translate_generic_event):
(popup_get_selection): Use `xi_convert_event_state' instead.
* src/xterm.c (xi_convert_event_state): Export on non-GTK
builds.
* src/xterm.h: Update prototypes.
Stefan Kangas [Mon, 4 Jul 2022 13:06:52 +0000 (15:06 +0200)]
Fix scrolling backwards in Helper-help
* lisp/emacs-lisp/helper.el (Helper-help-scroller): Fix scrolling
backwards.
Mattias Engdegård [Mon, 4 Jul 2022 12:52:50 +0000 (14:52 +0200)]
Remove some useless `eval-when-compile`
* lisp/cedet/semantic/java.el (semantic-java-number-regexp):
* lisp/cedet/semantic/lex.el (semantic-lex-number-expression):
* lisp/emacs-lisp/cl-indent.el (common-lisp-indent-function-1):
* lisp/emacs-lisp/lisp-mode.el (lisp-imenu-generic-expression)
(lisp--el-match-keyword, lisp-string-in-doc-position-p):
* lisp/emacs-lisp/shorthands.el (shorthands-font-lock-shorthands):
* lisp/net/socks.el (socks-send-command):
* lisp/progmodes/meta-mode.el (meta-font-lock-keywords):
* lisp/shell.el (shell--parse-pcomplete-arguments):
* lisp/textmodes/sgml-mode.el (sgml-mode):
* lisp/textmodes/tex-mode.el (tex--guess-mode)
(tex-common-initialization, tex-input-files-re):
* lisp/textmodes/tildify.el (tildify-mode):
* lisp/xdg.el (xdg-line-regexp):
Eliminate `eval-when-compile` when the argument would be evaluated by
the compiler anyway.
Mattias Engdegård [Mon, 4 Jul 2022 12:12:24 +0000 (14:12 +0200)]
Replace lisp-mode-symbol-regexp with (rx lisp-mode-symbol)
This is shorter, simplifies use inside rx expressions, and removes
need for eval-when-compile elsewhere (for later exploitation).
* lisp/emacs-lisp/lisp-mode.el (lisp-mode-symbol): New rx-define.
(lisp-mode-symbol-regexp): Redefine using lisp-mode-symbol.
(lisp-imenu-generic-expression, lisp--el-match-keyword)
(lisp-fdefs, lisp-string-in-doc-position-p):
* lisp/emacs-lisp/checkdoc.el (checkdoc--error-bad-format-p):
* lisp/emacs-lisp/shorthands.el (shorthands-font-lock-shorthands):
Use lisp-mode-symbol instead of lisp-mode-symbol-regexp.
Stefan Kangas [Mon, 4 Jul 2022 12:53:16 +0000 (14:53 +0200)]
* lisp/progmodes/ebrowse.el (ebrowse-tree-mode): Fix typo.
Stefan Kangas [Mon, 4 Jul 2022 12:10:04 +0000 (14:10 +0200)]
Remove remaining Helper-help support from view-mode
* lisp/view.el (view-old-Helper-return-blurb): Make obsolete.
(view--enable, view--disable): Delete remaining Helper-help support
code; view-mode stopped using it in 1995.
Eli Zaretskii [Mon, 4 Jul 2022 12:13:12 +0000 (15:13 +0300)]
; Fix doc strings in help-fns.el
* lisp/help-fns.el (help-fns-edit-mode-done)
(help-fns-edit-mode-cancel): Doc fixes.
Lars Ingebrigtsen [Mon, 4 Jul 2022 10:37:17 +0000 (12:37 +0200)]
Don't bug out in manual-html-fix-index-2 on newer makeinfo versions
Backport from master.
* admin/admin.el (manual-html-fix-index-2): Don't bug out if the
makeinfo version doesn't include <ul>.
(cherry picked from commit
e0e3f2b672bc42da52ac9c7596c7560a88684651)
Lars Ingebrigtsen [Mon, 4 Jul 2022 10:47:16 +0000 (12:47 +0200)]
Preserve <title> in the Emacs manuals
Backport from master.
* admin/admin.el (manual-html-fix-headers): Preserve the <title>
element (bug#48334).
(cherry picked from commit
b778e71af7ca8c59917334b4bb1b34cdb52faca9)
Eli Zaretskii [Mon, 4 Jul 2022 11:59:58 +0000 (14:59 +0300)]
; Fix documentation of 'file-parent-directory'
* doc/lispref/files.texi (Directory Names):
* lisp/files.el (file-parent-directory): Improve wording of the
documentation of 'file-parent-directory'. (Bug#56355)
Daanturo [Mon, 4 Jul 2022 11:07:51 +0000 (13:07 +0200)]
Add file-parent-directory function
* doc/lispref/files.texi: Document the function.
* etc/NEWS: Add its entry.
* lisp/emacs-lisp/shortdoc.el: Add it to 'file-name' group.
* lisp/files.el: implementation (bug#56355).
Benjamin Riefenstahl [Mon, 4 Jul 2022 10:57:34 +0000 (12:57 +0200)]
lisp/thumbs.el: Fix calling the "convert" command
* lisp/thumbs.el (thumbs-call-convert): Pass 'action-prefix' and
'action' as a combined parameter. Do not pass 'arg' if it is nil.
(thumbs-modify-image): Do not pass "" as 'arg' to
'thumbs-call-convert' (bug#56375).
Some time in the past this was converted from using the shell to
passing the parameters directly, but the fallout was not handled
correctly.
Lars Ingebrigtsen [Mon, 4 Jul 2022 10:47:16 +0000 (12:47 +0200)]
Preserve <title> in the Emacs manuals
* admin/admin.el (manual-html-fix-headers): Preserve the <title>
element (bug#48334).
Lars Ingebrigtsen [Mon, 4 Jul 2022 10:37:17 +0000 (12:37 +0200)]
Don't bug out in manual-html-fix-index-2 on newer makeinfo versions
* admin/admin.el (manual-html-fix-index-2): Don't bug out if the
makeinfo version doesn't include <ul>.
Visuwesh [Sun, 3 Jul 2022 13:29:44 +0000 (15:29 +0200)]
Exclude radio buttons when suggesting URI in eww
* lisp/net/eww.el (eww-links-at-point): Exclude radio links.
(bug#56366).
Stefan Kangas [Mon, 4 Jul 2022 10:12:45 +0000 (12:12 +0200)]
New command help-fns-edit-mode-cancel
* lisp/help-fns.el (help-fns-edit-mode-cancel): New command.
(help-fns--edit-value-mode-map): Bind it to 'C-c C-k'.
(help-fns-edit-variable): Advertise it in help text.
Po Lu [Mon, 4 Jul 2022 06:02:42 +0000 (14:02 +0800)]
Handle errors caused by ignoring errors with GDK's trap installed
* src/xterm.c (x_ignore_errors_for_next_request)
(x_stop_ignoring_errors): Also tell GDK to ignore errors from
the following requests. (bug#56372)
Po Lu [Mon, 4 Jul 2022 05:41:20 +0000 (13:41 +0800)]
Always wait for XdndStatus before sending XdndDrop
* src/xterm.c (x_dnd_do_drop): New function.
(x_dnd_begin_drag_and_drop): Clear new flag.
(handle_one_xevent): Use that function; send drops upon receipt
of pending XdndStatus, to avoid race conditions where we don't
yet know the selected action.
Po Lu [Mon, 4 Jul 2022 04:56:24 +0000 (12:56 +0800)]
Fix accessing dpyinfo after it is deallocated
* src/xterm.c (x_connection_closed): Print disconnect error for
the last terminal before freeing it.
Stefan Kangas [Mon, 4 Jul 2022 04:30:34 +0000 (06:30 +0200)]
Merge from origin/emacs-28
41472f3b6c Document 'jit-lock-debug-mode'
Po Lu [Mon, 4 Jul 2022 03:32:05 +0000 (11:32 +0800)]
Display list of traps and handlers when crashing due to an X error
* src/xterm.c (x_connection_closed): Print list of installed
error handlers if not crashing due to an IO error.
(NO_INLINE): Include error serial in error message.
Florian Rommel [Fri, 3 Jun 2022 01:03:03 +0000 (03:03 +0200)]
Add support for fullscreen values fullheight and fullwidth on PGTK
* src/pgtkterm.c (window_state_event): Support values fullheight and
fullwidth for the fullscreen frame-parameter
* doc/lispref/frames.texi (Size Parameters): Document inability to
actively set hullheight/fullwidth for PGTK frames
* configure.ac: Bump GTK version for PGTK
* etc/NEWS: Change GTK version in PGTK announcement
Po Lu [Mon, 4 Jul 2022 01:33:19 +0000 (09:33 +0800)]
Add some more error checking code to `x_stop_ignoring_errors'
* src/xterm.c (x_stop_ignoring_errors): Abort if no request was
actually made, making the state inconsistent.
Stefan Kangas [Sun, 3 Jul 2022 21:05:50 +0000 (23:05 +0200)]
Simplify lisp-el-font-lock-keywords-2 definition slightly
* lisp/emacs-lisp/lisp-mode.el (lisp-el-font-lock-keywords-2):
Simplify slightly.
Stefan Kangas [Sun, 3 Jul 2022 15:35:53 +0000 (17:35 +0200)]
Quote some literal keys to get help-key-binding face
* lisp/align.el (align):
* lisp/bindings.el (undo-repeat-map):
* lisp/calc/calc-embed.el (calc-do-embedded):
* lisp/calc/calc-prog.el (calc-user-define-invocation):
* lisp/calc/calc-yank.el (calc--edit-mode):
* lisp/comint.el (comint-history-isearch)
* lisp/dired.el (dired-mode):
* lisp/emulation/viper.el (viper-mode):
* lisp/erc/erc-button.el (erc-button-face):
* lisp/erc/erc-track.el (erc-track-enable-keybindings):
* lisp/gnus/gnus-art.el (gnus-article-button-face):
* lisp/gnus/gnus-eform.el (gnus-edit-form):
* lisp/gnus/gnus-sum.el (gnus-summary-stop-at-end-of-message)
(gnus-summary-goto-unread):
* lisp/icomplete.el (icomplete-show-matches-on-no-input):
* lisp/image-mode.el (image-scroll-up):
* lisp/international/iso-transl.el (iso-transl-set-language):
* lisp/isearch.el (isearch-forward-regexp):
* lisp/misc.el (butterfly):
* lisp/outline.el (outline-minor-mode-cycle-filter)
(outline-minor-mode-cycle):
* lisp/progmodes/grep.el (rgrep):
* lisp/progmodes/gud.el (gud-gdb-repeat-map, gud-sdb-repeat-map)
(gud-dbx-repeat-map, gud-xdb-repeat-map, gud-perldb-repeat-map)
(gud-pdb-repeat-map, gud-guiler-repeat-map, gud-jdb-repeat-map):
* lisp/progmodes/idlw-shell.el (idlwave-shell-graphics-window-size)
(idlwave-shell-mode):
* lisp/progmodes/idlwave.el (idlwave-shell-debug-modifiers)
(idlwave-list-shell-load-path-shadows):
* lisp/progmodes/python.el (python-shell-get-process-or-error):
* lisp/repeat.el (repeat-check-key):
* lisp/replace.el (query-replace, query-replace-regexp)
(read-regexp):
* lisp/simple.el (read-extended-command-predicate):
* lisp/tab-bar.el (tab-bar-switch-repeat-map)
(tab-bar-move-repeat-map):
* lisp/term.el (ansi-term):
* lisp/textmodes/reftex-index.el (reftex-index-phrases-set-macro-key):
* lisp/vc/emerge.el (emerge-scroll-left, emerge-scroll-right):
* lisp/windmove.el:
* lisp/winner.el (winner-mode): Quote literal keys to get
'help-key-binding' face.
* lisp/comint.el (comint-insert-previous-argument): Use regular
quotes.
Stefan Kangas [Sun, 3 Jul 2022 19:00:16 +0000 (21:00 +0200)]
Use command substitutions instead of literal keys in some places
* lisp/emulation/viper-macs.el (ex-map, viper-set-register-macro):
* lisp/minibuffer.el (minibuffer-beginning-of-buffer-movement):
* lisp/speedbar.el (speedbar-frame-mode):
* lisp/subr.el (kbd):
* lisp/textmodes/page-ext.el (pages-directory)
(pages-directory-for-addresses):
* lisp/textmodes/reftex-toc.el: Use command substitutions instead of
literal keys.
Stefan Kangas [Sun, 3 Jul 2022 20:42:13 +0000 (22:42 +0200)]
Normalize definition of erc-track-minor-mode-map
* lisp/erc/erc-track.el (erc-track-minor-mode-map): Normalize keymap
definition.
Stefan Kangas [Sun, 3 Jul 2022 20:32:47 +0000 (22:32 +0200)]
Use substitute-command-keys in reftex-toc-show-help
* lisp/textmodes/reftex-toc.el (reftex-toc-help)
(reftex-toc-show-help): Use substitute-command-keys.
Stefan Kangas [Sun, 3 Jul 2022 18:59:00 +0000 (20:59 +0200)]
Font lock \\<> and \\{} command substitutions in docstrings
* lisp/emacs-lisp/lisp-mode.el (lisp-el-font-lock-keywords-2):
Support \\<> and \\{} command substitutions.
Stefan Kangas [Sun, 3 Jul 2022 21:28:50 +0000 (23:28 +0200)]
Fix warning in last commit
* lisp/calc/calc-misc.el (calc-dispatch-help): Fix warning.
Eli Zaretskii [Sun, 3 Jul 2022 17:57:22 +0000 (20:57 +0300)]
; * lisp/mwheel.el (mouse-wheel-scroll-amount): Doc fix.
Juri Linkov [Sun, 3 Jul 2022 17:02:02 +0000 (20:02 +0300)]
Use more help-key-binding faces in repeat-mode message
* lisp/repeat.el (repeat-echo-message-string): Use
substitute-command-keys for repeat-exit-key as well.
Juri Linkov [Sun, 3 Jul 2022 17:00:11 +0000 (20:00 +0300)]
* lisp/mwheel.el: More fixes for global-text-scale (bug#48307)
(mouse-wheel-global-text-scale): Move down closer to mouse-wheel-text-scale.
(mouse-wheel-scroll-amount): Add :value global-text-scale and mention it
in the docstring.
(mouse-wheel-global-text-scale, mouse-wheel--setup-bindings):
Add mouse-wheel-down-alternate-event and mouse-wheel-up-alternate-event.
Allow a list of modifiers for 'text-scale'.
Stefan Kangas [Sun, 3 Jul 2022 15:31:45 +0000 (17:31 +0200)]
Improve calc-dispatch-help docstring
* lisp/calc/calc-misc.el (calc-dispatch-help): Use command
substitutions.
Michael Albinus [Sun, 3 Jul 2022 16:23:55 +0000 (18:23 +0200)]
Tramp code cleanup
* lisp/net/tramp-cache.el (tramp-get-file-property)
(tramp-get-connection-property): Make DEFAULT optional. Adapt callees.
* lisp/net/tramp.el:
* lisp/net/tramp-adb.el:
* lisp/net/tramp-cmds.el:
* lisp/net/tramp-compat.el:
* lisp/net/tramp-crypt.el:
* lisp/net/tramp-ftp.el:
* lisp/net/tramp-fuse.el:
* lisp/net/tramp-gvfs.el:
* lisp/net/tramp-integration.el:
* lisp/net/tramp-sh.el:
* lisp/net/tramp-smb.el:
* lisp/net/tramp-sshfs.el:
* lisp/net/trampver.el: Code cleanup.
* test/lisp/net/tramp-tests.el (tramp--test-sh-no-ls--dired-p)
(tramp--test-with-proper-process-name-and-buffer): Code cleanup.
Florian Rommel [Sun, 3 Jul 2022 15:04:32 +0000 (17:04 +0200)]
abort-redisplay: Add missing unbind_to in 'recenter'
* src/window.c (recenter): Add ubind_to before early return.
(Bug#56369)
Stefan Monnier [Sun, 3 Jul 2022 15:12:45 +0000 (11:12 -0400)]
lisp/elec-pair.el: Simplify last change
* lisp/elec-pair.el (electric-pair--with-syntax):
Rename from `electric-pair--with-text-syntax`.
Make `start` mandatory. Run `body` in the normal syntax if `start` is nil.
(electric-pair--with-syntax-1): New function, extracted from
`electric-pair--with-text-syntax`.
(electric-pair-syntax-info, electric-pair--balance-info):
Adjust calls accordingly.
Stefan Kangas [Sun, 3 Jul 2022 13:16:23 +0000 (15:16 +0200)]
Fix dired-goto-subdir prompt
* lisp/dired-aux.el (dired-goto-subdir): Fix prompt and improve
docstring. Add interactive mode tag for dired-mode.
Stefan Kangas [Sun, 3 Jul 2022 12:47:53 +0000 (14:47 +0200)]
Fix warnings in my last commit
* lisp/textmodes/emacs-news-mode.el (outline): Require.
Stefan Kangas [Sun, 3 Jul 2022 12:40:21 +0000 (14:40 +0200)]
Improve navigation keybindings in emacs-news-mode
* lisp/textmodes/emacs-news-mode.el (emacs-news-common-map): New
defvar-keymap. Bind navigation commands as in 'org-mode' and
'outline-minor-mode'.
(emacs-news-mode-map): Inherit from 'emacs-news-common-map'.
(emacs-news-view-mode-map): New defvar-keymap; inherit from
'emacs-news-common-map'.
Eli Zaretskii [Sun, 3 Jul 2022 12:39:05 +0000 (15:39 +0300)]
Merge branch 'master' of git.savannah.gnu.org:/srv/git/emacs
Eli Zaretskii [Sun, 3 Jul 2022 12:37:50 +0000 (15:37 +0300)]
Fix implementation of 'reset' face values
* src/xfaces.c (Finternal_merge_in_global_face)
(gui_supports_face_attributes_p): Only modify local copy of face
attributes when replacing 'reset' pseudo-values with real values.
(Bug#38771)
Stefan Kangas [Sun, 3 Jul 2022 12:34:44 +0000 (14:34 +0200)]
; * etc/NEWS: Tag two items.
Stefan Kangas [Sun, 3 Jul 2022 12:32:44 +0000 (14:32 +0200)]
Move dired-clean-up-buffers-too to dired.el
* lisp/dired-x.el (dired-clean-up-buffers-too)
(dired-clean-confirm-killing-deleted-buffers): Move from here...
* lisp/dired.el (dired-clean-up-buffers-too)
(dired-clean-confirm-killing-deleted-buffers): ...to
here. (Bug#21981)
(dired-clean-up-after-deletion): Adjust documentation.
* etc/NEWS: Announce the change.
kobarity [Sun, 3 Jul 2022 12:22:13 +0000 (14:22 +0200)]
Fix `python-nav-beginning-of-defun' line continuation using backslash
* lisp/progmodes/python.el (python-nav--beginning-of-defun): Allow
line continuation using backslash in defuns (bug#55702).
(python-info-looking-at-beginning-of-defun): Add CHECK-STATEMENT
argument.
Stefan Kangas [Sun, 3 Jul 2022 12:20:34 +0000 (14:20 +0200)]
* lisp/dired-x.el (dired-omit-size-limit): Increase value.
Lars Ingebrigtsen [Sun, 3 Jul 2022 12:05:01 +0000 (14:05 +0200)]
Make string-limit with encoding return complete glyphs
* lisp/emacs-lisp/subr-x.el (string-limit): Return more correct
results in the CODING-SYSTEM case for coding systems with BOM and
charset designations (bug#48324). Also amend the algorithm to
return complete glyphs, not just complete code points.
Po Lu [Sun, 3 Jul 2022 11:48:55 +0000 (19:48 +0800)]
Improve performance when rejecting XI touch event
* src/xterm.c (handle_one_xevent): Avoid sync handling simple
error.
Lars Ingebrigtsen [Sun, 3 Jul 2022 10:57:29 +0000 (12:57 +0200)]
Fix streaming problems in nnimap-retrieve-headers
* lisp/gnus/nnimap.el (nnimap-retrieve-headers): Don't stream the
UID FETCH commands, since the server may return the results
out-of-order (bug#56332).
Lars Ingebrigtsen [Sun, 3 Jul 2022 10:55:00 +0000 (12:55 +0200)]
Add new function `seq-split'
* doc/lispref/sequences.texi (Sequence Functions): Document it.
* lisp/emacs-lisp/seq.el (seq-split): New function.
* lisp/emacs-lisp/shortdoc.el (sequence): Mention it.
Allen Li [Sun, 3 Jul 2022 10:31:15 +0000 (12:31 +0200)]
elec-pair: Fix bug incorrectly hiding syntax-propertize-function
* lisp/elec-pair.el (electric-pair--with-text-syntax): New macro.
(electric-pair-syntax-info):
(electric-pair--balance-info):
(electric-pair--syntax-ppss, electric-pair--balance-info): Use it.
(electric-pair--with-uncached-syntax): Remove (bug#49629).
The main bug that this is fixing is `syntax-propertize-function' being
hidden in `electric-pair--balance-info' when the original syntax table
is to be used, not `electric-pair-text-syntax-table'.
Notably, this causes `electric-pair-mode' to often misbehave in HTML
files when pairing angle brackets.
This commit also flushes the cache before installing
`electric-pair-text-syntax-table', to prevent cached syntax for the
original table from affecting things.
Eli Zaretskii [Sun, 3 Jul 2022 10:22:42 +0000 (13:22 +0300)]
; * src/xfaces.c (Finternal_set_lisp_face_attribute): Fix last change.
Po Lu [Sun, 3 Jul 2022 09:51:55 +0000 (17:51 +0800)]
Improve efficiency of `x_frame_highlight' and `x_frame_unhighlight'
* src/xterm.c (x_frame_highlight, x_frame_unhighlight): Don't
sync catching errors.
Stefan Kangas [Sun, 3 Jul 2022 09:44:04 +0000 (11:44 +0200)]
* lisp/dired.el (dired-do-eww): New command.
Stefan Kangas [Sat, 2 Jul 2022 20:17:06 +0000 (22:17 +0200)]
Improve dired-do-{info,man} error handling
* lisp/dired.el (dired-do-man, dired-do-info): Use
'dired-get-file-for-visit' to get better error handling.
Interactive mode tagging.
Eli Zaretskii [Sun, 3 Jul 2022 09:30:24 +0000 (12:30 +0300)]
Implement pseudo-value 'reset' of face attrributes
* doc/lispref/display.texi (Face Attributes):
* etc/NEWS: Document the new pseudo-value 'reset'.
* src/xfaces.c (realize_named_face, lookup_derived_face)
(gui_supports_face_attributes_p, lookup_named_face)
(Finternal_merge_in_global_face, merge_named_face, merge_faces):
Handle the 'reset' pseudo-value of a face's attribute.
(syms_of_xfaces): New symbol 'reset'.
(RESET_P): New macro.
(check_lface_attrs, Finternal_set_lisp_face_attribute): Allow
'reset' as a value of any attribute except ':inherit'.
(Bug#38771)
James Thomas [Sat, 2 Jul 2022 09:23:54 +0000 (14:53 +0530)]
* lisp/leim/quail/indian.el ("malayalam-mozhi"): Set DETERMINISTIC.
Po Lu [Sun, 3 Jul 2022 06:33:02 +0000 (14:33 +0800)]
Fix deadlocks with very old versions of libXi
* src/xfns.c (setup_xi_event_mask, Fx_create_frame): Set
`xi_mask' ourselves if the version of libXi is too old to have
working XIGetSelectedEvents.
* src/xterm.c (x_destroy_window): Free `xi_mask' with xfree in
that case.
Eli Zaretskii [Sun, 3 Jul 2022 05:40:54 +0000 (08:40 +0300)]
Document 'jit-lock-debug-mode'
* doc/lispref/modes.texi (Other Font Lock Variables): Document
'jit-lock-debug-mode'.
Stefan Kangas [Sun, 3 Jul 2022 04:30:39 +0000 (06:30 +0200)]
; Merge from origin/emacs-28
The following commit was skipped:
d927181b1a * lisp/progmodes/cc-mode.el (c-common-init): Bind case-fol...
Stefan Kangas [Sun, 3 Jul 2022 04:30:38 +0000 (06:30 +0200)]
Merge from origin/emacs-28
dc3d01a5af CC Mode: Fix a c-backward-token-2 call wrongly jumping bac...
e390396e68 Doc fixes; don't use obsolete names
c85f7c2e8a Don't refer to obsolete alias for insert-char
60ad45c5d2 Don't use obsolete face name in manoj-dark-theme
Po Lu [Sun, 3 Jul 2022 01:41:32 +0000 (09:41 +0800)]
Speed up receiving drops over slow connections
* lisp/x-dnd.el (x-dnd-debug-errors): New variable.
(x-dnd-handle-drag-n-drop-event): Bind
`x-fast-protocol-requests' to t if that is off.
* src/xfns.c (Fx_change_window_property):
(Fx_delete_window_property):
* src/xselect.c (Fx_send_client_message, x_send_client_event):
Don't sync to check for errors if fast protocol requests are
enabled.
* src/xterm.c (x_catch_errors_for_lisp, x_check_errors_for_lisp)
(x_uncatch_errors_for_lisp): New functions.
(syms_of_xterm): New variable `x-fast-protocol-requests'.
* src/xterm.h: Update prototypes.
Lars Ingebrigtsen [Sat, 2 Jul 2022 20:03:06 +0000 (22:03 +0200)]
REQUIRE-MATCH doc string clarification
* src/minibuf.c (Fcompleting_read):
* lisp/minibuffer.el (read-file-name): Clarify what the return
value is in the REQUIRE-MATCH function case.
Lars Ingebrigtsen [Sat, 2 Jul 2022 17:45:27 +0000 (19:45 +0200)]
Fix some typos in NEWS
Lars Ingebrigtsen [Sat, 2 Jul 2022 16:42:11 +0000 (18:42 +0200)]
Add sanity check for Emacsen distributed without .el files
* src/lread.c (maybe_swap_for_eln): Add sanity check for Emacsen
distributed without .el files (bug#48342).
Alan Mackenzie [Mon, 31 Jan 2022 17:44:59 +0000 (17:44 +0000)]
* lisp/progmodes/cc-mode.el (c-common-init): Bind case-fold-search to nil
Backport: This fixes bug #53605.
Alan Mackenzie [Sat, 2 Jul 2022 16:12:59 +0000 (16:12 +0000)]
CC Mode: Fix a c-backward-token-2 call wrongly jumping back over macros.
This fixes bug #56256.
* lisp/progmodes/cc-fonts.el (c-font-lock-c++-lambda-captures): Replace a
c-backward-token-2, which could jump back too far leading to an infinite
loop, with a save-excursion to remember the point we've got to go back to.
Lars Ingebrigtsen [Sat, 2 Jul 2022 15:58:56 +0000 (17:58 +0200)]
Filter out nul bytes when killing from a *grep* buffer
* lisp/progmodes/grep.el (grep-mode): Filter out the nul bytes
(bug#48321).
Manuel Giraud [Sat, 2 Jul 2022 15:38:36 +0000 (17:38 +0200)]
Add more separators to longlines-mode
* lisp/obsolete/longlines.el (longlines-breakpoint-chars): New
custom to have multiple breakpoint chars.
(longlines-set-breakpoint): Add a target-column parameter and use
`longlines-breakpoint-chars'.
(longlines-find-break-backward, longlines-find-break-foreward):
Use `longlines-breakpoint-chars'.
(longlines-wrap-line): Do not insert space upon merging, just
remove the soft newline. Fix "space before tab" in indent.
(longlines-merge-lines-p): Use the new target-column parameter to
find out if the next line could be merged with the current one.
(longlines-encode-region): Do not replace a soft newline with a
space, just remove it.
* etc/NEWS: New user option 'longlines-breakpoint-chars'
Lars Ingebrigtsen [Sat, 2 Jul 2022 15:33:33 +0000 (17:33 +0200)]
Unobsolete longlines-mode (bug#18589)
Stefan Kangas [Sat, 2 Jul 2022 15:32:14 +0000 (17:32 +0200)]
Use help-key-binding face in text scale adjust messages
* lisp/face-remap.el (text-scale-adjust)
(global-text-scale-adjust): Use substitute-command-keys.
Stefan Kangas [Sat, 2 Jul 2022 14:59:14 +0000 (16:59 +0200)]
Use help-key-binding face in repeat-mode message
* lisp/repeat.el (repeat-echo-message-string): Use
substitute-command-keys.
Stefan Kangas [Sat, 2 Jul 2022 14:56:39 +0000 (16:56 +0200)]
Make dired-jump repeatable in repeat-mode
* lisp/dired.el (dired-jump-map): New variable.
(dired-jump): Put 'repeat-map' property with 'dired-jump-map'.
Eli Zaretskii [Sat, 2 Jul 2022 14:56:05 +0000 (17:56 +0300)]
; * etc/NEWS: Fix typo in recently-added entry.
Eli Zaretskii [Sat, 2 Jul 2022 14:52:23 +0000 (17:52 +0300)]
; Minor fixes for 'global-text-scale-adjust'
* doc/emacs/display.texi (Text Scale): Improve indexing.
* lisp/mwheel.el (mouse-wheel-global-text-scale): Doc fix.
* lisp/face-remap.el (global-text-scale-adjust-resizes-frames):
Fix a typo.
(global-text-scale-adjust-limits): Doc fix.
(Bug#48307)
Stefan Kangas [Sat, 2 Jul 2022 13:41:43 +0000 (15:41 +0200)]
Move dired-info and dired-man from dired-x to dired
* lisp/dired-x.el (dired-bind-man, dired-bind-info): Change into
defvars and make obsolete.
(dired-extra-startup): Doc fix.
(dired-info, dired-man): Move from here...
* lisp/dired.el (dired-do-info, dired-do-man): ...to here and
rename. (Bug#21981)
* lisp/dired.el (dired-mode-map): Bind 'I' and 'N' to 'dired-do-info'
and 'dired-do-man'.
* doc/misc/dired-x.texi (Miscellaneous Commands): Remove documentation
of 'dired-info' and 'dired-man'.
* doc/emacs/dired.texi (Dired Enter): Document 'dired-do-info' and
'dired-do-man'.
* etc/NEWS: Announce the above changes.
Stefan Kangas [Sat, 2 Jul 2022 10:25:03 +0000 (12:25 +0200)]
Prefer defvar-keymap in nxml/*.el
* lisp/nxml/nxml-mode.el (nxml-mode-map):
* lisp/nxml/nxml-outln.el (nxml-outline-prefix-map)
(nxml-outline-show-map, nxml-outline-hiding-tag-map)
(nxml-outline-showing-tag-map): Prefer defvar-keymap.