* etc/themes/newcomers-presets-theme.el
(newcomers-presets-mode-enabled-local-modes): Interpret the
variable as a proper alist without duplicate keys.
(newcomers-presets-mode): Handle new structure.
* lisp/vc/smerge-mode.el (smerge--refine-chopup-region):
Replace `beg..end` arg with an overlay.
(smerge-refine-regions): Replace `beg` arg with an overlay.
(smerge--refine-prepare-regions, smerge--refine-apply-diff-1):
New functions, extracted from `smerge-refine-regions`.
(smerge--refine-apply-diff): New function.
(smerge-refine-regions): Use them. Also delete temp files right after
running `diff` rather than after applying diff's output.
* lisp/recentf.el (recentf-exclude-ignored-extensions): Doc fix.
(recentf-exclude-file-by-extension-p): Rename from
`recentf-exclude-ignored-extensions'; all references changed.
Doc fix.
* etc/NEWS: Improve wording of the entry which announces the
above.
* lisp/recentf.el (recentf-exclude-ignored-extensions): New
user option.
(recentf-exclude-ignored-extensions): New function.
* etc/NEWS: Announce the new option and function.
(Bug#80347)
* lisp/vc/vc-dispatcher.el (vc-display-failed-async-commands):
New user option.
(vc-do-async-command): Use it.
* doc/emacs/vc1-xtra.texi (General VC Options):
* etc/NEWS: Document it.
* lisp/vc/vc-dispatcher.el (vc-do-command): Adjust message to
begin "Failed" not "Done" when command exits non-zero.
* lisp/vc/vc.el (vc-checkin): Adjust message to end in
"...failed" not "...done" when async command exits non-zero.
Walking the window tree is more reliable than using the selected
window. Implement 'get-mru-frame' on top of 'get-mru-frames'
using 'frame-use-time'.
* lisp/frame.el (frame-use-time): Change to walk the window tree
for the specified frame.
(get-mru-frames): New defun.
(get-mru-frame): Change to call 'get-mru-frames'.
* doc/lispref/frames.texi: Update documentation.
* etc/NEWS: Update announcement.
* lisp/subr.el (any): Rename from this ...
(member-if): ... to this. All uses changed.
(any): New function alias.
* lisp/emacs-lisp/cl-seq.el (cl-member-if): Mark obsolete.
* lisp/obsolete/cl.el (member-if): Delete obsolete function
alias.
* doc/lispref/lists.texi (List Elements):
* doc/misc/cl.texi (Lists as Sets):
* etc/NEWS: Document the change.
See initial discussion here:
https://lists.gnu.org/archive/html/emacs-devel/2026-02/msg00400.html
* lisp/international/characters.el (pairs): Populate
special-mirror-table.
* src/xdisp.c (produce_special_glyphs): Add two arguments. One
to identify the paragraph direction and one to identify that the
glyph is produced on the left hand side of a window. Mirror
glyph defined in the display table according to the new
special-mirror-table. Bidi mirroring always takes precedence.
(init_iterator, insert_left_trunc_glyphs, display_line)
(display_string): Call 'produce_special_glyphs' with new arguments.
(syms_of_xdisp) <special-mirror-table>: New char-table.
* etc/NEWS: Announce the change.
* lisp/subr.el (any): Rename from this ...
(member-if): ... to this. All uses changed.
Implement '&key KEY-FN' for backwards compatibility.
(any): New function alias.
* lisp/emacs-lisp/cl-seq.el (cl-member-if): Make an alias for
'member-if'.
* lisp/obsolete/cl.el (member-if): Delete obsolete function
alias.
* doc/lispref/lists.texi (List Elements):
* doc/misc/cl.texi (Lists as Sets):
* etc/NEWS: Document the change.
Not a bug report, but this is from the emacs-devel thread
"Tree-sitter: Transcendental things".
Improve tree-sitter thing navigation functions to handle the
case where there are multiple nested parsers in the
buffer. Previously these functions just grab the node at point
and are limited to the parser of that node. Now these functions
will thoUrouly search through all parsers that covers point
before giving up.
* doc/lispref/parsing.texi: Mention the change.
* lisp/treesit.el (treesit--some): New macro.
(treesit--thing-sibling): Use the new macro, add a new PARSER
parameter.
(treesit-thing-prev):
(treesit-thing-next): Add PARSER parameter.
(treesit-thing-at):
(treesit-navigate-thing): Use the new macro, add a new PARSER
parameter. Also pass the PARSER arg to recursive calls and
calls to treesit-thing-prev, etc.
* src/w32image.c (w32_gdip_export_frame): New function.
(gdiplus_init): Load 'GdipCreateBitmapFromHBITMAP' from GDI+ DLL.
* src/w32fns.c (Fw32_export_frame): New primitive.
* etc/NEWS: Announce the new primitive.
* src/keyboard.c (syms_of_keyboard):
<multiple_terminals_merge_keyboards>: New variable.
(read_event_from_main_queue): Mention it in message.
* lisp/cus-start.el: Make it customizable.
* src/callint.c (Ffuncall_interactively):
* src/keyboard.c (Frecursive_edit):
* src/minibuf.c (read_minibuf): When its value is true, don't
enter single-kboard mode (bug#79892).
* admin/notes/multi-tty:
* etc/NEWS: Document it.
* lisp/emacs-lisp/package.el (package-upgrade-keep-previous):
Rename user option to 'package-retention-policy'.
(package--policy-type): New constant for policy types.
(package-retention-policy): New option.
(package-review-policy): Use new type constant.
(package--review-p): Rename and generalise to
'package-matches-selector-p'.
(package-matches-selector-p): New function.
(package-upgrade, package-menu--mark-upgrades-1): Respect
'package-retention-policy'.
* doc/emacs/package.texi (Package Installation): Document new option.
* etc/NEWS: Update NEWS entry. (Bug#79957)
This change adds a conditional to keep old package versions on upgrade.
This allows users to keep running multiple Emacsen without a package
upgrade in one Emacs breaking another running Emacs.
* lisp/emacs-lisp/package.el (package-upgrade-keep-previous):
New boolean user option.
(package-upgrade): Use it.
(package-menu--mark-upgrades-1): Use it.
(package-menu--find-upgrades): Make consistent with new option.
* etc/NEWS: Announce it.
(Bug#79957)
* src/lisp.h (FOR_EACH_TAIL_INTERNAL): Divvy up the code into...
(FOR_EACH_TAIL_BASIC, FOR_EACH_TAIL_STEP_CYCLEP): ...these macros,
so that they can be used in more flexible ways.
* src/fns.c (internal_equal_1): Detect circular lists and call...
(internal_equal_cycle): ...this function that keeps comparing
but now detecting cycles in the other argument.
* lisp/emacs-lisp/testcover.el (testcover-after):
Remove unnecessary error handling.
* test/src/fns-tests.el (test-cycle-equal): Adapt and extend.
* test/lisp/emacs-lisp/testcover-resources/testcases.el
(testcover-testcase-cyc1): Remove case that no longer applies.
* doc/lispref/objects.texi (Equality Predicates): Update.
* etc/NEWS: Announce.
* admin/merge-gnulib (GNULIB_MODULES): Add crypto/sha3-buffer.
* lib/sha3.c: New file, imported by running admin/merge-gnulib.
* lib/sha3.h: Likewise.
* m4/sha3.m4: Likewise.
* lib/gnulib.mk.in: Updated by admin/merge-gnulib.
* m4/gnulib-comp.m4: Likewise.
* src/fns.c: Include sha3.h
(Fsecure_hash_algorithms): Add Qsha3_224, Qsha3_256, Qsha3_384, and
Qsha3_512.
(secure_hash): Likewise.
(Fsecure_hash): List the SHA-3 algorithms in the docstring.
(syms_of_fns): Define Qsha3_224, Qsha3_256, Qsha3_384, and Qsha3_512.
* test/lisp/net/gnutls-tests.el (gnutls-tests-internal-macs-upcased):
Filter out the new SHA-3 algorithms since they are currently not
implemented in gnutls.
* test/src/fns-tests.el (test-secure-hash): Add test cases for the new
algorithms.
* doc/lispref/text.texi (Checksum/Hash): List the SHA-3 algorithms.
Mention that they are considered secure.
* etc/NEWS: Mention the new feature.
Variable names to control indentation have never been
standardized, but over the years some conventions have naturally
arisen, mostly the use of `FOO-indent-offset`,
`FOO-basic-offset`, or `FOO-indent-level` for `FOO-mode`.
When the new TS modes were introduced, a mistake was made that
I failed to catch at the time, where those modes used
`FOO-mode-indent-offset` instead of the "standard" `FOO-indent-offset`.
In order to save packages like `editorconfig-mode` and `indent-bars-mode`
from having to cater to yet-another-convention, rename those
vars to what they should have been all along.
* lisp/editorconfig.el (editorconfig-indentation-alist): Remove the
ad-hoc entries for the deviating modes using `FOO-mode-indent-offset`.
* lisp/textmodes/toml-ts-mode.el (toml-ts-indent-offset):
* lisp/textmodes/mhtml-ts-mode.el (mhtml-ts-js-css-indent-offset)
(mhtml-ts--js-css-indent-offset):
* lisp/textmodes/html-ts-mode.el (html-ts-indent-offset):
* lisp/progmodes/typescript-ts-mode.el (typescript-ts-indent-offset):
* lisp/progmodes/php-ts-mode.el (php-ts-indent-offset)
(php-ts-js-css-indent-offset, php-ts-html-indent-offset):
* lisp/progmodes/json-ts-mode.el (json-ts-indent-offset):
* lisp/progmodes/java-ts-mode.el (java-ts-indent-offset)
(java-ts-method-chaining-indent-offset):
* lisp/progmodes/go-ts-mode.el (go-ts-indent-offset):
* lisp/progmodes/csharp-mode.el (csharp-ts-indent-offset):
* lisp/progmodes/cmake-ts-mode.el (cmake-ts-indent-offset):
* lisp/progmodes/c-ts-mode.el (c-ts-indent-offset):
Rename `FOO-mode-indent-offset` to `FOO-indent-offset`,
with obsolete alias.
* lisp/calendar/calendar.el (calendar-month-edges): Fix typo.
(calendar-total-months): New variable.
(calendar-get-month-range, calendar-get-date-range)
(calendar--month-overlap-p, calendar-month-visible-p)
(calendar-nongregorian-date-visible-p): New functions.
(calendar-nongregorian-visible-p): Declare obsolete.
(calendar-recompute-layout-variables, calendar-generate):
Replace fixed month numbers with 'calendar-total-months'.
(calendar-cursor-to-date, calendar-date-is-visible-p): Support
the calendar with more than three months.
(calendar-mode): Make some variables buffer-local to allow
calendar-mode buffers showing different number of months.
(calendar-mode-map): Use new command names.
* lisp/calendar/cal-move.el (calendar-goto-today): Always move
the cursor to today's date.
(calendar--show-month-at-edge): New function.
(calendar-recenter, calendar-forward-day): Support the calendar
with more than three months.
(calendar-forward-month, calendar-end-of-month)
(calendar-beginning-of-year, calendar-end-of-year): Place the
new month at the edge instead of the second month segment, to
prevent the cursor from jumping back and forth. This is
consistent with the behavior of calendar-forward-day/week.
(calendar-scroll-left): Maintain the relative position of the
cursor with respect to the window, when the old date is out of
view.
(calendar-scroll-left-three-months)
(calendar-scroll-right-three-months): Replace the fixed month
number with the actual number of months. Rename ...
(calendar-scroll-calendar-left, calendar-scroll-calendar-right):
... to new commands. Make old names as aliases and mark them
obsolete.
(calendar-show-more-months, calendar-show-fewer-months): New
commands.
* lisp/calendar/cal-menu.el (cal-menu-holiday-window-suffix):
Use the actual date range instead of three months.
(cal-menu-scroll-menu, cal-menu-global-mouse-menu): Use new
command names and update description.
* lisp/calendar/holidays.el (holidays, list-holidays)
(calendar-check-holidays, holiday-in-range): Use
calendar-total-months.
(calendar-list-holidays, holiday-fixed, holiday-float)
(holiday-sexp): Replace displayed-year/month with the actual
calendar range.
(holiday-after, holiday-easter-etc-abs)
(holiday-greek-orthodox-easter-abs): New functions.
(holiday-advent, holiday-easter-etc)
(holiday-greek-orthodox-easter): Look up holidays in all visible
years instead of current displayed-year.
* lisp/calendar/solar.el (solar-equinoxes-solstices): Search
equinoxes and solstices in all visible months.
(solar-equinoxes-solstices-1): New function.
* lisp/calendar/lunar.el (lunar-phase-list): Add optional
argument.
(calendar-lunar-phases): Use visible calendar range.
* lisp/calendar/cal-china.el (holiday-chinese-new-year)
(holiday-chinese-winter-solstice, holiday-chinese-qingming)
(holiday-chinese): Replace displayed-year/month with the actual
calendar range, and look up holidays in all visible years.
* lisp/calendar/cal-julian.el (holiday-julian): Use
calendar-nongregorian-date-visible-p because there may exist
more than one corresponding dates when the calendar shows more
months.
* lisp/calendar/cal-bahai.el (holiday-bahai): Support calendar
with more than three months.
(holiday-bahai-new-year, holiday-bahai-twin-holy-birthdays):
Look up holidays in all visible years.
(holiday-bahai-new-year-1, holiday-bahai-twin-holy-birthdays-1):
New functions.
* lisp/calendar/cal-hebrew.el (calendar-hebrew-date-is-visible-p)
(holiday-hebrew, calendar-hebrew-mark-date-pattern): Support
calendar with more than three months, in which more than one
holidays may exist.
(holiday-hebrew-rosh-hashanah-1, holiday-hebrew-hanukkah-1)
(holiday-hebrew-passover-1): New functions.
(holiday-hebrew-rosh-hashanah, holiday-hebrew-hanukkah)
(holiday-hebrew-passover, holiday-hebrew-tisha-b-av): Look up
holidays in all visible years.
* lisp/calendar/cal-islam.el (holiday-islamic): Support calendar
with more than three months.
(holiday-islamic-new-year): Find holidays in all visible years.
* lisp/calendar/diary-lib.el (diary-mark-sexp-entries)
(calendar-mark-days-named, calendar-mark-date-pattern)
(calendar-mark-complex): Use the displayed range instead of the
three-month range.
(calendar-mark-1): Fix marking dates in calendar with more than
three months.
* test/lisp/calendar/holidays-tests.el
(holidays-test-holiday-easter-etc, holidays-test--get-holidays)
(holidays-test-more-months): New test file.
* doc/emacs/calendar.texi: Mention new commands and update
related description.
* etc/NEWS: Announce new commands. (bug#80099)
Users can revert to the old 'delete-frame' behavior of selecting
the oldest frame in 'frame-list' rather than the most-recently
used frame.
* src/frame.c (delete_frame): Consult
'after-delete-frame-select-mru-frame'.
(syms_of_frame): New defvar
'after-delete-frame-select-mru-frame'.
* etc/NEWS: Reflect the new user option.
The main point is to make the content of 'eshell-aliases-file' stable so
that storing it in git becomes feasible.
This also makes the output of the alias command come out in alphabetical
order (bug#80401).
* lisp/eshell/em-alias.el (eshell/alias): Sort when updating
'eshell-command-aliases-list'.
* test/lisp/eshell/em-alias-tests.el
(em-alias-test/alias-list-is-sorted): New test.
* etc/NEWS: Announce this change.
* lisp/mail/rmailsum.el (rmail-summary-sender-function)
(rmail-summary-recipient-function, rmail-summary-address-width):
New user options.
(rmail-summary--address-display, rmail-summary-name-or-address)
(rmail-summary-recipient-strip-quoted-names)
(rmail-summary-recipient-names): New functions.
(rmail-header-summary): Use them when formatting sender and
recipient fields (bug#80406).
* doc/emacs/rmail.texi (Rmail Make Summary): Document them.
* test/lisp/mail/rmailsum-tests.el: New file.
(rmailsum-tests-name-or-address-prefers-name)
(rmailsum-tests-name-or-address-fallback-to-address)
(rmailsum-tests-recipient-strip-quoted-names-first-line)
(rmailsum-tests-recipient-names-folded)
(rmailsum-tests-recipient-names-fallback-to-address): New tests.
The custom Pdb class enables native completion in pdb by
wrapping the pdb's native completer. It also makes necessary
function definitions like __PYTHON_EL_* available between pdb
frames, and enables non-native completion/ffap/eldoc
functionalities when debugging inside python modules.
* lisp/progmodes/python.el (python-shell-send-setup-code): Fix
the separator between python-shell-setup-codes.
(python-shell-completion-native-setup): Move common completion
setup code ...
(python-shell-completion-setup-code): ... here.
(python-shell-completion-at-point): Enable native completion for
pdb and respect the delimiter of pdb completer.
(python-shell-pdb-setup-code): New variable.
(python-shell-comint-watch-for-first-prompt-output-filter): Send
setup codes only once.
(python-ffap-module-path, python-eldoc--get-doc-at-point): Stop
sending setup code in every function call.
* test/lisp/progmodes/python-tests.el (python-tests--pdb-1)
(python-shell-pdb-1): New test.
* etc/NEWS: Mention the change. (bug#80182)
* doc/emacs/custom.texi (Custom Themes): Mention command in a
general context.
(Newcomers Theme): Mention command in the context of the
'newcomers-preset' theme
* etc/NEWS: Mention new command.
* lisp/custom.el (copy-theme-options): New command.
* doc/emacs/custom.texi (Beginners Theme): Document new theme.
* etc/NEWS: Mention new theme.
* etc/themes/newcomers-presets-theme.el: New file including
new theme.
* lisp/frame.el (get-mru-frame): New defun.
* src/frame.c (delete_frame): Call 'get-mru-frame' (when force
is not Qnoelisp) to select the most recently used frame that is
not the deleted frame as the candidate to select.
(syms_of_frame): Qget_mru_frame new DEFSYM.
* doc/lispref/frames.texi: Document the new functions.
* etc/NEWS: Announce the new functions.
* lisp/vc/vc.el (vc-root-diff-outgoing-base)
(vc-diff-outgoing-base, vc-log-outgoing-base)
(vc-root-log-outgoing-base): Rename from these ...
(vc-root-diff-outstanding, vc-diff-outstanding)
(vc-log-outstanding, vc-root-log-outstanding): ... to these.
All uses changed.