Commit graph

181238 commits

Author SHA1 Message Date
Eli Zaretskii
f430166f7d ; * doc/lispref/commands.texi (Special Events): Add cross-reference. 2026-02-08 08:34:36 +02:00
Stéphane Marks
e0ce881be9 ; Minor changes to 'truncate-string-pixelwise' (bug#80244)
Fix two bugs and add tests for them.
2026-02-07 14:49:15 +02:00
kobarity
3107c66c84 Change the type of 'python-eldoc-function-timeout' to number
* etc/NEWS: Announce the change.
* lisp/progmodes/python.el (python-eldoc-function-timeout):
Change the type.  (Bug#80045)
2026-02-07 14:44:27 +02:00
kobarity
482748592f Use 'project-name-cached' in 'python-shell-get-process-name'
* lisp/progmodes/python.el
(python-shell-get-project-name): New function.
(python-shell-get-process-name): Use it.  (Bug#80045)

Co-authored-by: Liu Hui <liuhui1610@gmail.com>
2026-02-07 14:41:48 +02:00
kobarity
3d7e78b810 Revert "Performance improvement of 'python-shell-get-process'"
This reverts commit 83b4f1ba26.
We concluded that it is better to use 'project-name-cached'.
(Bug#80045)
2026-02-07 14:41:10 +02:00
Eli Zaretskii
419ac8148f ; Document creation of strings from copies of other strings
* doc/lispref/strings.texi (Creating Strings): Document how to
create a string from N copies of another string.  (Bug#80256)
2026-02-07 14:22:12 +02:00
Michael Albinus
04bb557d7e ; * lisp/doc-view.el (doc-view-mode-p): Fix docstring. 2026-02-07 11:33:14 +01:00
Michael Albinus
89209a83b6 Support D-Bus file descriptor manipulation
* doc/misc/dbus.texi (Synchronous Methods): Adapt `dbus-call-method'.
(Asynchronous Methods): Adapt `dbus-call-method-asynchronously'.
(File Descriptors): New chapter, replaces Inhibitor Locks.

* etc/NEWS: Replace "New D-Bus functions to support systemd
inhibitor locks" by "Support D-Bus file descriptor manipulation".
Presentational fixes and improvements.

* lisp/net/dbus.el (dbus-call-method)
(dbus-call-method-asynchronously): Adapt docstring.
(dbus-list-hash-table): Return (nreverse result).
(dbus-monitor-goto-serial): Declare `completion'.

* src/dbusbind.c (Fdbus_message_internal, xd_read_message_1):
Handle `:keep-fd'.
(xd_registered_inhibitor_locks, Fdbus_make_inhibitor_lock)
(Fdbus_close_inhibitor_lock, Fdbus_registered_inhibitor_locks): Delete.
(xd_registered_fds): New variable.
(Fdbus__fd_open, Fdbus__fd_close, Fdbus__registered_fds):
New DEFUNs.  (Bug#79963)
(syms_of_dbusbind_for_pdumper): Initialize `xd_registered_fds'.
(syms_of_dbusbind): Remove subroutines
`Sdbus_make_inhibitor_lock', `Sdbus_close_inhibitor_lock' and
`Sdbus_registered_inhibitor_locks'.  Remove symbol `Qdbus_call_method'.
Declare subroutines `Sdbus__fd_open', `Sdbus__fd_close' and
`Sdbus__registered_fds'.  Declare symbol `QCkeep_fd'.  staticpro
`xd_registered_fds'.

* test/lisp/net/dbus-tests.el (dbus-test10-inhibitor-locks): Delete.
(dbus-test10-keep-fd, dbus-test10-open-close-fd): New tests.
2026-02-07 11:32:54 +01:00
Philip Kaludercic
1aabe135e6
; Fix partial revert from c31e7ef4d5
* lisp/emacs-lisp/package.el (package-autosuggest-style)
(package-autosuggest-mode, package--autosuggest-suggested)
(package--suggestion-applies-p, package--autosuggest-database)
(package--autosuggest-find-candidates)
(package--autosugest-line-format, package-autosuggest-face)
(package--autosuggest-after-change-mode, package-autosuggest):
Remove definitions that were kept in package-activate.el.
2026-02-07 11:02:19 +01:00
Eli Zaretskii
e1524740be ; Fix documentation of widget commands
* doc/misc/widget.texi (Widgets and the Buffer): Fix the
signatures of 'widget-forward' and 'widget-backward'.  Reported by
Tim Landscheidt <tim@tim-landscheidt.de>.

* lisp/wid-edit.el (widget-forward, widget-backward)
(widget-move): Doc fixes.
2026-02-07 11:45:00 +02:00
Philip Kaludercic
c31e7ef4d5
Revert "Enable 'package-autosuggest-mode' at startup"
This reverts commit ae67318362.
2026-02-07 10:39:18 +01:00
Eli Zaretskii
cdc390d992 ; Improve documentation of 'etags-regen-mode'
* doc/emacs/maintaining.texi (Xref, Tags Tables)
(Create Tags Table, Select Tags Table): Improve documentation and
cross-references for 'etags-regen-mode'.
2026-02-07 09:12:42 +02:00
Dmitry Gutov
df517aa958 etags-regen--build-program-options: Expand the error message text
* lisp/progmodes/etags-regen.el (etags-regen--build-program-options):
Expand the error message text.
2026-02-07 02:07:30 +02:00
Dmitry Gutov
cc9fea52a3 etags--xref-backend: Move the definition to autoloads
* lisp/progmodes/etags.el (etags--xref-backend):
Move the definition to autoloads, so that etags.el doesn't have to
be loaded before it really is used.
2026-02-07 02:06:52 +02:00
Dmitry Gutov
b37711a25f Some manual updates for the recent change
* doc/emacs/maintaining.texi (Looking Up Identifiers):
Mention that 'M-.' can signal an error.
(Xref): Recommend using 'etags-regen-mode' (bug#43086).

* etc/NEWS: Add updated marks.
2026-02-07 00:01:56 +02:00
Philip Kaludercic
bc413b3507
Use 'buffer-file-name' when matching 'auto-mode-alist'
* lisp/emacs-lisp/package-activate.el (package--suggestion-applies-p):
The file name associated with a buffer is a better match for
entries in 'auto-mode-alist', so we use that instead of the
buffer name that can have additional noise to make the name unique.
2026-02-06 22:50:49 +01:00
Philip Kaludercic
6314c08c6b
Link to "Major Mode" node in manual when suggesting packges
* lisp/emacs-lisp/package.el (package--autosugest-prompt): Add
another button.
2026-02-06 22:37:06 +01:00
Philip Kaludercic
f561eed4d6
Add separate user option to prevent repetitive package suggestions
* lisp/emacs-lisp/package-activate.el
(package-autosuggest-style): Remove option 'once' and defer to
new user option.
(package-autosuggest-once): Add new option.
(package--suggestion-applies-p)
(package--autosuggest-after-change-mode): Respect new user option.
2026-02-06 22:31:30 +01:00
Philip Kaludercic
5808909d1e
; Properly initialize 'package-autosuggest-mode'
* lisp/emacs-lisp/package-activate.el (package-autosuggest-mode):
Add :initialize property to minor mode definition as recommended
in (elisp) Variable Definitions.
2026-02-06 22:24:09 +01:00
Philip Kaludercic
f64430fbad
; Fix typo
* lisp/emacs-lisp/package-activate.el (package--autosugest-line-format):
Use actually existing face symbol.
2026-02-06 22:15:49 +01:00
Philip Kaludercic
4a1e4a6edc
; * lisp/emacs-lisp/package-activate.el: Add note on preloading 2026-02-06 22:15:06 +01:00
Philip Kaludercic
ae67318362
Enable 'package-autosuggest-mode' at startup
* lisp/emacs-lisp/package.el (package-autosuggest-style)
(package-autosuggest-mode, package--autosuggest-suggested)
(package--suggestion-applies-p, package--autosuggest-database)
(package--autosuggest-find-candidates)
(package--autosugest-line-format, package-autosuggest-face)
(package--autosuggest-after-change-mode, package-autosuggest):
Remove definitions needed to recognise suggestions from here.

* lisp/emacs-lisp/package-activate.el (package-autosuggest-style)
(package--autosuggest-database, package--autosuggest-suggested)
(package--suggestion-applies-p)
(package--autosuggest-find-candidates)
(package--autosugest-line-format, package-autosuggest)
(package--autosuggest-after-change-mode)
(package-autosuggest-mode): Move definitions from package.el.

(package--activated, package-installed-p, package-get-version)
(package-activate-all, package-activate-all): Remove unnecessary
autoloads.

* lisp/loadup.el: Load "package-activate.el".
2026-02-06 21:15:29 +01:00
Mattias Engdegård
66d307aa08 ; * etc/NEWS (help-setup-xref): slight polish (bug#80276) 2026-02-06 17:11:17 +01:00
Sean Whitton
c6e550c24e Separate input histories for 'C-x v !' and Git pulling & pushing
* lisp/vc/vc-dispatcher.el (vc-user-edit-command-history): Use
this as a dynamically bound variable, not a minibuffer history.
(vc-user-edit-command): Pass its value to read-shell-command.
* lisp/vc/vc-git.el (vc-git--pushpull):
* lisp/vc/vc.el (vc-edit-next-command): Bind it.
(vc-edit-next-command-history): New variable.
* etc/NEWS: Document the change.
2026-02-06 14:06:36 +00:00
Dmitry Gutov
90d3fdaffc Allow using xref-find-references without visiting a tags table
* lisp/progmodes/xref.el (xref-find-backend):
Allow returning nil (bug#43086).
(xref-backend-definitions, xref-backend-apropos):
Signal user-error when no backend is available.  The error text
suggests a few built-in Xref backends.
(xref-backend-identifier-completion-table): Default to nil.
(xref--no-backend-available): New helper function.

* lisp/progmodes/etags.el (etags--xref-backend):
Return nil when no tags table is visited.
2026-02-06 05:56:52 +02:00
João Távora
ec5479f0b5 Eglot: fix thinko in eglot--async-request
Just because a specific request of a specific "hint" is
cancelled doesn't mean we can cancel the other's too.  Also
eglot-advertise-cancellation = nil was subtly broken.

This manifested itself mostly in Eglot semantic tokens.

* lisp/progmodes/eglot.el (eglot--async-request): Fix thinkos.
2026-02-05 22:39:19 +00:00
Mattias Engdegård
4169720313 ; * test/lisp/vc/ediff-mult-tests.el: use ert-with-temp-directory
Suggested by Pip Cet.
2026-02-05 17:36:18 +01:00
Mattias Engdegård
893e0783c9 ; * lisp/subr.el (take-while): bytecode micro-optimisation 2026-02-05 17:36:17 +01:00
Sean Whitton
a06cddec20 ; diff--revert-kill-hunks: Hoist binding inhibit-read-only. 2026-02-05 12:24:05 +00:00
Sean Whitton
3863449a0a ; * lisp/window.el (window--frame-landscape-p): Tweak wording. 2026-02-05 12:18:54 +00:00
Visuwesh
e2f9e6ba7d vc-git--mailinfo: Use file-local-name (bug#80295, bug#80320)
* lisp/vc/vc-git.el (vc-git--mailinfo):
Use file-local-name (bug#80295, bug#80320).
2026-02-05 12:11:53 +00:00
Protesilaos Stavrou
dda572a2fa New minibuffer history for vc-user-edit-command (bug#80169)
* lisp/vc/vc-dispatcher.el (vc-user-edit-command-history): New variable.
(vc-user-edit-command): Use it (bug#80169).
* etc/NEWS: Announce it.
2026-02-05 12:01:43 +00:00
Sean Whitton
10aa35bab7 Bind "u", "@" in diff-mode-read-only-map, not diff-mode-shared-map
* lisp/vc/diff-mode.el (diff-mode-shared-map): Move bindings for
"u" and "@" from here ...
(diff-mode-read-only-map): ... to here.
2026-02-05 11:49:28 +00:00
Sean Whitton
ccee1c0de6 ; Improve outgoing base command docstrings. 2026-02-05 11:46:01 +00:00
Sean Whitton
0dfaa75612 Bind "s" in diff-mode-read-only-map, not diff-mode-shared-map
* lisp/vc/diff-mode.el (diff-mode-shared-map): Move binding for
"s" from here ...
(diff-mode-read-only-map): ... to here (bug#80330).
2026-02-05 11:31:05 +00:00
Eli Zaretskii
8beb69b77c ; Fix cross references in "User Lisp Directory"
* doc/emacs/custom.texi (User Lisp Directory): Fix wording,
punctuation, and cross-references.  (Bug#80321)
2026-02-05 11:28:13 +02:00
Troy Brown
f660a5469c Fix last change in align.el
* lisp/align.el (align-region): Additional fix of last change.
(Bug#80316)

Copyright-paperwork-exempt: yes
2026-02-05 10:56:51 +02:00
John Wiegley
fd6d8faa62 Fix aligning buffer regions containing multiple alignment sections
* lisp/align.el (align-region): Use markers to ensure the regions
stay accurate after overlapping aligning modifications.  (Bug#80316)

* test/lisp/align-tests.el (align-c-multi-section): New test.
2026-02-05 10:51:16 +02:00
Philip Kaludercic
ebe3838011
Merge remote-tracking branch 'origin/master' into feature/package-autosuggest 2026-02-04 17:36:37 +01:00
Philip Kaludercic
0277fd791b
Rephrase package suggestion message
* lisp/emacs-lisp/package.el (package--autosugest-prompt):
Follow Richard's suggestion from
https://mail.gnu.org/archive/html/emacs-devel/2026-02/msg00040.html.
2026-02-04 17:36:32 +01:00
Stefan Monnier
3ea1010a6b * lisp/comint.el (comint-redirect-hook): Defvar (bug#80313) 2026-02-04 11:14:10 -05:00
Stefan Monnier
f38b0872f0 (yaml-ts-mode-yamllint-options): Use a list of strings
It is both simpler to code and marginally more general (allows
spaces in arguments).

* lisp/textmodes/yaml-ts-mode.el (yaml-ts-mode-yamllint-options): Use
a list.
(yaml-ts-mode-flymake): Adjust accordingly.
2026-02-04 11:03:57 -05:00
Stefan Monnier
f73cb8fba2 shortdoc: Don't burp on missing docstrings
* lisp/emacs-lisp/shortdoc.el (shortdoc--display-function): Report
missing docstrings more cleanly than "Wrong type argument: stringp, nil".
2026-02-04 10:59:23 -05:00
Mattias Engdegård
1396b373ff ediff-mult-tests.el: remove temporary directory after test
* test/lisp/vc/ediff-mult-tests.el (ediff-test-bug3348): Clean up.
2026-02-04 14:33:36 +01:00
Mattias Engdegård
6dc2336a4f Make vc-git-tests work with git < 2.46
* test/lisp/vc/vc-git-tests.el (vc-git-test-branch-remotes):
The 'unset' subcommand to 'git config' was introduced in git 2.46; use
the '--unset' option instead.
2026-02-04 13:26:08 +01:00
Philip Kaludercic
4ab81f82bf
Do not compile database into package.el
* lisp/emacs-lisp/package.el (package--autosuggest-database):
Add new variable.
(package--autosuggest-find-candidates): Load the contents of the
database from 'data-directory' if necessary, and store them in
the new variable.
2026-02-03 17:25:57 +01:00
Dmitry Gutov
083f89f858 Fix [More] buttons in tutorial and other buttons in Semantic
* lisp/help-mode.el (help-setup-xref): Update docstring (bug#80276).

* etc/NEWS: Add description for the earlier change in help-setup-xref.

* lisp/tutorial.el (tutorial--describe-nonstandard-key)
(tutorial--detailed-help): Use 'with-help-window', call it after.

* lisp/cedet/semantic/util.el (semantic-describe-buffer): Same.

* lisp/cedet/semantic/decorate/include.el
(semantic-decoration-include-describe)
(semantic-decoration-unknown-include-describe)
(semantic-decoration-fileless-include-describe)
(semantic-decoration-unparsed-include-describe)
(semantic-decoration-all-include-summary): Same.
2026-02-03 05:14:59 +02:00
Stefan Monnier
53bc4a2cb6 isearch.el: Remove autoloads hacks
* lisp/isearch.el (char-fold-to-regexp): Remove redundant autoload.
(emoji--read-emoji): Use `declare-function` rather than autoload.
2026-02-02 17:42:40 -05:00
Eli Zaretskii
16b10d7617 ; Improve indexing in the ELisp manual
* doc/lispref/functions.texi (Function Names):
* doc/lispref/variables.texi (Tips for Defining): Improve
indexing.
2026-02-02 15:24:21 +02:00
Sean Whitton
a269bcb86b diff-mode-shared-map: Bind '@' to diff-revert-and-kill-hunk
* lisp/vc/diff-mode.el (diff-mode-shared-map): Bind '@' to
diff-revert-and-kill-hunk.
2026-02-02 12:57:12 +00:00