Commit graph

182402 commits

Author SHA1 Message Date
Eli Zaretskii c19e9ddd48 ; Improve documentation of 'emacs-lock' features
* lisp/emacs-lock.el (emacs-lock-unlockable-modes)
(emacs-lock-locked-buffer-functions, emacs-lock-mode)
(emacs-lock--can-auto-unlock, emacs-lock--kill-emacs-hook)
(emacs-lock--kill-emacs-query-functions)
(emacs-lock--kill-buffer-query-functions, emacs-lock-mode)
(emacs-lock-unload-function): Doc fixes.
2026-06-25 11:26:27 +03:00
Alan Mackenzie 749ce42049 CC Mode: Set parse-sexp-lookup-properties for every mode
This fixes a bug reported and diagnosed by Campbell Barton
<ideasman42@gmail.com> on the emacs-devel list.

* lisp/progmodes/cc-mode.el (c-basic-common-init): Set
parse-sexp-lookup-properties or (for XEmacs) lookup-syntax-properties
for every CC Mode mode.
2026-06-25 10:00:13 +03:00
Dirk-Jan C. Binnema def15c1b97 Disable DMABUF and Compositing for xwidget
Webkit does not support DMABUF or accelerated compositing in the
offscreen widgets Emacs uses for xwidget.  Disable both for non-pgtk
GTK3 builds (Bug#80834).
* src/xterm.c (init_xterm): Set WEBKIT_DISABLE_DMABUF_RENDERER and
WEBKIT_DISABLE_COMPOSITING_MODE when built with xwidgets and not pgtk.

Copyright-paperwork-exempt: yes
2026-06-25 09:56:05 +03:00
Eli Zaretskii 2c5b4911b3 ; * doc/lispref/commands.texi (Interactive Codes): More examples of '*'. 2026-06-25 09:48:52 +03:00
Eli Zaretskii ea87a99b84 ; Fix recent improvements in docs of splitting and merging frames
* lisp/window-x.el (merge-frames): Doc fix.

* doc/lispref/windows.texi (Basic Windows): Fix a typo.
* doc/lispref/frames.texi (Splitting and Merging Frames): Fix
wording, markup and indexing.
2026-06-25 09:43:29 +03:00
Eli Zaretskii 0ec6a3fd44 Fix failure code in 'run-hook-query-error-with-timeout'
* lisp/subr.el (run-hook-query-error-with-timeout): Fix incorrect
call to 'error'.  (Bug#81292)
2026-06-25 09:11:18 +03:00
Zhengyi Fu 72b8d88171 Use default-value in project--value-in-dir
When in a VC project whose dir-locals file specifies `project-vc-name',
the function `project--value-in-dir' previously used `symbol-value' to
retrieve the variable value, causing `project-name' to return the same
name for all VC projects without an explicit `project-vc-name'.  Use
`default-value' instead to correctly fall back to the default value.

* lisp/progmodes/project.el (project--value-in-dir): Replace `symbol-value'
with `default-value' (bug#81293).

Copyright-paperwork-exempt: yes
2026-06-25 05:58:08 +03:00
Dmitry Gutov b34952ee94 etags-regen--maybe-generate: No error when no project found
* lisp/progmodes/etags-regen.el (etags-regen--maybe-generate):
When no project found, abort cleanly with a message.
2026-06-24 18:00:12 +03:00
Martin Rudalics 30fc250a26 ; * doc/lispref/frames.texi (Deleting Frames): Fix typo in last commit. 2026-06-24 11:39:02 +02:00
Stephen Berman 8679bdf081 Mark ChangeLog entry as tiny change
* ChangeLog.5: Mark an entry as a tiny change, because the
"Copyright-paperwork-exempt: yes" line was mistakenly omitted from
the commit log entry.
2026-06-24 11:35:54 +02:00
Sean Whitton 070a3a356f VC revert: When un-adding, clear vc-backend property
* lisp/vc/vc.el (vc-revert-file, vc-revert-files): When
un-adding, clear vc-backend property (bug#81291).
2026-06-24 10:29:50 +01:00
Sean Whitton c8a86c1561 ; make change-history-commit 2026-06-24 10:06:37 +01:00
Martin Rudalics 884d7a198c Document new option 'delete-frame-choose-selected' (Bug#80397)
* doc/lispref/frames.texi (Deleting Frames): Document new option
'delete-frame-choose-selected'.
* etc/NEWS: Mark 'delete-frame-choose-selected', 'split-frame'
and 'merge-frames' as documented.
2026-06-24 10:09:47 +02:00
Martin Rudalics f0bfa33039 Document 'split-frame' and 'merge-frames' in Elisp manual
* doc/lispref/frames.texi (Splitting and Merging Frames): New
section.
* doc/lispref/elisp.texi (Top): Add new section.
* doc/lispref/windows.texi (Basic Windows): Explain terms
'layout' and 'identity' of windows.
(Window Configurations): Explain that window identities are
preserved by window configurations and get lost with window
states.
2026-06-23 16:37:37 +02:00
Sean Whitton 0d67e76b94 Eglot: release version 1.24
* lisp/progmodes/eglot.el (Version): Bump to 1.24.

* etc/EGLOT-NEWS: Announce new version.
2026-06-23 13:22:58 +01:00
Sean Whitton f52457d17e Jsonrpc: release version 1.0.29
(Version): Bump to 1.0.29.
2026-06-23 13:22:34 +01:00
João Távora 4f6b6f462c jsonrpc-shutdown: Ensure we wait whole timeout & increase timeout
* lisp/jsonrpc.el (jsonrpc-shutdown): Ensure that we wait for
the whole timeout and increase the timeout to 300ms (bug#80140).
2026-06-23 13:18:56 +01:00
Sean Whitton eb814fbb5c vc-hg-state-slow: Run from the repository root
* lisp/vc/vc-hg.el (vc-hg-state-slow): Run command from the
repository root.  This fixes cases where a whole subdirectory no
longer exists.  We should return 'missing' for any files within
it.
2026-06-23 11:28:19 +01:00
Sean Whitton 3660bd3eb4 vc-dir-delete-file: Call vc-delete-file on FILESET-ONLY-FILES
* lisp/vc/vc-dir.el (vc-dir-delete-file): Call vc-delete-file on
FILESET-ONLY-FILES.  See bug#80998.
2026-06-23 11:08:16 +01:00
Stéphane Marks a3a72ae355 Fix 'truncate-string-pixelwise' to restore the window buffer
* lisp/emacs-lisp/subr-x.el (truncate-string-pixelwise): Safely
save/restore the selected window's buffer, and not the reference
or current buffers.  Guard dedicated windows.  Remove the work
buffer from the window's buffer list.  Bind
'buffer-list-update-hook' 'window-scroll-functions'
'window-configuration-change-hook' to nil around the window
buffer swap.  (Bug#81262; see also bug#80244.)
2026-06-23 10:25:28 +01:00
Stéphane Marks b684922900 Restore progress-reporter suffix as update-text (bug#81134)
* lisp/subr.el (progress-reporter-update-functions): Update
docstring.
(progress-reporter-update): New UPDATE-TEXT argument replacing
previously deleted SUFFIX.
(make-progress-reporter): Document suffix slot available for
reuse.
(progress-reporter-force-update): Update function signature.
(progress-reporter-echo-area): Restore the text argument and
echo it.
(progress-reporter-do-update): Update function signature.  Treat
UPDATE-TEXT as ephemeral and do not persist it in the reporter
instance.  Update the hook.
(progress-reporter-done): Update the hook.
* lisp/system-taskbar.el
(system-taskbar--progress-reporter-update): Update function
signature.
* lisp/net/tramp.el (tramp-progress-reporter-update): Update
function signature.
* doc/lispref/display.texi (Progress): Update documentation.
2026-06-23 10:16:00 +01:00
Juri Linkov e182c704c7 Rename recently added after-delete-frame-select-mru-frame
Rename 'after-delete-frame-select-mru-frame' to
'delete-frame-choose-selected' for symmetry with
'delete-window-choose-selected' with the same
default value 'mru' (bug#80397).

* lisp/cus-start.el: Add a choice like in
'delete-window-choose-selected'.

* src/frame.c (delete_frame): Compare delete_frame_choose_selected
with Qmru.
(syms_of_frame): Define symbol Qmru.
Use DEFVAR_LISP for 'delete-frame-choose-selected'
and set the default value to Qmru.
2026-06-22 18:57:52 +03:00
duli e47bd3070a Eglot: decode unhexed file URI paths as UTF-8 (bug#79897)
'url-unhex-string' only decodes %XX sequences and returns a
unibyte string; it does not interpret the resulting octets as
UTF-8.  Its docstring says that the resulting string generally
requires decoding with an appropriate coding system.

LSP messages are UTF-8, and document URIs are transferred as URI
strings.  When recovering the file path from the URI, decode the
unhexed octets as UTF-8 instead of using them directly as an
Emacs string.  This should fix bug#79897.

Copyright-paperwork-exempt: yes

* lisp/progmodes/eglot.el (eglot-uri-to-path): Decode the
  result of 'url-unhex-string' with 'utf-8-unix'.
2026-06-22 16:27:35 +01:00
Sean Whitton e940326250 ; * etc/NEWS: Mention limitation of diff-apply-buffer. 2026-06-22 13:40:50 +01:00
Michael Albinus 25084664ba Sync with Tramp 2.8.2
* lisp/net/tramp-message.el (tramp-trace-add-package): New defun.

* lisp/net/tramp-smb.el (tramp-smb-maybe-open-connection):
Remove superfluous comment.

* lisp/net/tramp.el (tramp-restricted-shell-hosts-alist):
Use `file-name-sans-extension'.
(tramp-completion-handle-expand-file-name):
Apply `tramp-drop-volume-letter' consequently.

* test/lisp/net/tramp-tests.el
(tramp--test-ignore-make-symbolic-link-error): Use `file-error'
instead of `remote-file-error'
(tramp--test-instrument-test-case-p): Fix doxstring.
(tramp-test10-write-region-other-file-name-handler)
(tramp-test49-external-backend-function): Adapt tests.
2026-06-22 14:17:18 +02:00
Sean Whitton 7be92efa5e Rename variable to macroexp-enable-preserve-posification
* lisp/emacs-lisp/macroexp.el
(macroexp-enable-pos-preservation): Rename ...
(macroexp-enable-preserve-posification): ... to this.  All uses
changes.
2026-06-22 10:45:27 +01:00
Eshel Yaron 2066a0c9e8 New variable 'macroexp-enable-pos-preservation' (bug#79599)
* lisp/emacs-lisp/macroexp.el
(macroexp-enable-pos-preservation): New variable.
(macroexp-preserve-posification): Respect it.
* lisp/emacs-lisp/elisp-scope.el (elisp-scope-1): Use it.
* test/lisp/emacs-lisp/macroexp-tests.el
(macroexp--test-macroexp-enable-pos-preservation): New test.
2026-06-22 10:44:18 +01:00
milkvetch 00c290be85 Avoid infinite loop in some Dired marking commands
These commands use dired-get-filename inside a dired-mark-if form;
when the bottom subdirectory is hidden, dired-get-filename makes
it so the dired-mark-if loop never reaches the end of the buffer.
This is fixed by skipping hidden subdirectories (bug#80964).

* lisp/dired.el (dired-mark-files-regexp)
(dired-mark-files-containing-regexp):
* lisp/dired-x.el (dired-mark-unmarked-files):
* lisp/dired-aux.el (dired-compare-directories): Skip hidden subdirectories.
2026-06-21 20:19:19 +02:00
Eli Zaretskii e78a0fc9f4 Resurrect effect of 2nd arg t in 'format-mode-line'
* src/xdisp.c (Fformat_mode_line): Resurrect support for FACE = t.
Doc fix.  (Bug#81271)

* doc/lispref/modes.texi (Emulating Mode Line): Fix documentation
of 'format-mode-line' when 2nd argument is t.

* test/src/xdisp-tests.el (xdisp-test-format-mode-line): New test.
2026-06-20 14:18:16 +03:00
Eli Zaretskii 3eb124692d Fix 'format-mode-line' for integer second argument
* src/xdisp.c (Fformat_mode_line): Test for integers with
INTEGERP.  (Bug#81272)
2026-06-20 13:32:22 +03:00
Eli Zaretskii 4f1af6fa6e ; * doc/lispref/commands.texi (Interactive Codes): Clarify '*' (bug#81236). 2026-06-20 12:06:39 +03:00
Stéphane Marks 75cd277198 markdown-ts-mode: fix code block and table overlays (bug#81195)
Fix to eliminate erroneous multiple code block overlays.  Fixes
to deal with 'treesit' fontification catching up to
user-initiated code block range expansions; e.g., inserting,
yanking.  Set overlay properties only once.

* lisp/textmodes/markdown-ts-mode.el
(markdown-ts--fontify-code-block): Use 'overlays-in' not
'overlays-at'.  Use only overlays, eliminate markers.
(markdown-ts--enable-code-block-in-context-mode): Add 'sit-for'
to allow 'treesit' to catch up (pending input should not be an
issue).
(markdown-ts--run-command-in-code-block): Use overlays instead
of 'get-char-property'.
(markdown-ts--code-block-in-context-mode-update-ov): Use
overlays instead of 'get-char-property'.  Set overlay properties
only once.
(markdown-ts--in-table-mode-update-ov): Set overlay properties
only once.
2026-06-20 11:32:50 +03:00
Ivar Rummelhoff ae69929472 ; Improve code comment and 'winner-redo' docstring (bug#81235). 2026-06-20 11:25:04 +03:00
Stéphane Marks ca7c8208b7 markdown-ts-mode: Fix computing code block current region (bug#81219)
This ensures that commands such as 'comment-or-uncomment-region'
operate on the correct region in the work buffer.

* lisp/textmodes/markdown-ts-mode.el (markdown-ts--run-command-in-code-block):
Fix adj-region-beg and adj-region-end.
2026-06-20 10:57:00 +03:00
Oleksandr Makhmudov c3bc049549 Eglot: add 'nu-ts-mode' as a nushell major mode
'nu-ts-mode' is an alternative tree-sitter-based major mode for
nushell.  This commit adds it to the list of major modes that run
the nushell language server.
* lisp/progmodes/eglot.el (eglot-server-programs): Add 'nu-ts-mode'.
(Bug#81206)

Copyright-paperwork-exempt: yes
2026-06-20 10:50:44 +03:00
समीर सिंह Sameer Singh c0a33a474d
Fix c-ts-mode bsd-style indentation of union bodies (bug#81255)
* lisp/progmodes/c-ts-mode.el (c-ts-mode--simple-indent-rules): Add
"union_specifier" to the parent-is regexp.

* test/lisp/progmodes/c-ts-mode-resources/indent-bsd.erts: New test.
2026-06-19 19:10:30 -07:00
Yuan Fu 9d1b0c2d7f
Fix markdown-inline incremental parsing issue (bug#81019)
* lisp/treesit.el:
(treesit--embed-languages-need-full-parse): New variable.
(treesit--set-embed-ranges): Reparse full range if the langauge
needs it.
2026-06-19 19:09:01 -07:00
Stephen Berman a94a33827b Avoid an unusual error when visiting a directory in Dired
* lisp/dired.el (dired-internal-noselect): Unset
'dired--ls-error-buffer' before calling 'dired-readin'.  This is a
safeguard to prevent an error when visiting a directory in Dired,
which apparently happens when the variable somehow gets set even
though 'ls' has not emitted an error message (bug#80499, Message #218).

* test/lisp/dired-tests.el (dired-test-set-dired--ls-error-buffer): New test.
2026-06-19 10:13:22 +02:00
Dmitry Gutov b6e7962700 Fix "diff-apply-buffer applies to the wrong file"
* lisp/vc/diff-mode.el (diff-find-file-name): Inhibit the "drop
dir" behavior in diffs produced by Git and Hg (bug#81210).
Except for the virtual subdirectories like a/b/etc, which is
moved and happens for all such diffs.  Tighten the check for
such virtual directory names, though (characters are the chars
used by the configuration option 'diff.mnemonicPrefix').
(diff-setup-buffer-type): Recognize Hg diffs where only one
revision is specified, too.

* test/lisp/vc/diff-mode-tests.el
(diff-mode-test-setup-buffer-type)
(diff-mode-test-find-file-name-create): New tests.
2026-06-19 06:39:25 +03:00
Martin Rudalics 14bf2a707c Fix thinko in 'set-frame-size-and-position' (Bug#81193)
* lisp/frame.el (set-frame-size-and-position): Do not subtract
scoll bar, fringes and internal border sizes twice (Bug#81193).
2026-06-18 16:41:23 +02:00
Alan Third 050ca1a40f ; Remove NS port toolbar styling code (bug#80307)
Reverts cbf9c58730.

* src/nsterm.m: Remove the code that calls setToolbarStyle.
2026-06-17 17:38:08 +01:00
JD Smith 2ac289d096 Correct default native-comp tests
Supersedes 5bd9d1f7df3.

* configure.ac: Store `with_native_compilation' to correctly test
whether to use the soft or hard (error) checks, as these set the
variable by side-effect.
2026-06-17 12:20:17 -04:00
JD Smith a25cf2b986 Revert "Fix the Android build"
This reverts commit 916572f6e0, in favor
of another fix.
2026-06-16 17:11:44 -04:00
Stefan Monnier a6f5437110 (comint--intersect-regions): Fix bug#81243
* lisp/comint.el (comint--intersect-regions): Fix syntax-propertization.
2026-06-16 09:57:48 -04:00
Martin Rudalics ea09986dae ; * lisp/window.el (display-buffer): Fix doc-string typo. 2026-06-15 10:46:11 +02:00
Martin Rudalics 7b4e12b51c ; * lisp/help.el (temp-buffer-resize-mode): Fix doc-string typo. 2026-06-15 10:41:00 +02:00
Eli Zaretskii a8da2d20d0 ; * src/keyboard.c (Finsert_special_event): Fix quotes. 2026-06-14 07:21:39 +03:00
Kyle Meyer df60bad165 Update to Org 9.8.6 2026-06-13 23:59:15 -04:00
Stefan Monnier d48977dea8 src/keyboard.c (Finsert_special_event): Don't ignore unknown events 2026-06-13 18:27:26 -04:00
João Távora 669e93ec5d Eglot: restore compatibility to Emacs 26.3
Github-reference: https://github.com/joaotavora/eglot/discussions/1591

Can't use setf plist-get.

* lisp/progmodes/eglot.el (eglot--async-request): Use cl-getf.
2026-06-13 16:15:44 +01:00