Merge from origin/emacs-31

b8133a416d ; Update exported ChangeLog files and etc/AUTHORS
5e3e1a5bb2 ; Tweak some package short descriptions.
bbe805e4b1 message.el: Fix part of bug#81035
621239ae6a Fix prompt in remote shell
6df1d33b6c Fmake_xwidget: Use about:blank workaround only when needed
f3b17c4969 Allow brew/macports libgccjit for default native compilation
7226082f46 vc-dir-refresh: Respect non-essential wrt saving buffers
438af2764d ; * doc/lispref/text.texi (Mode-Specific Indent): Fix mar...
6b39919408 ; Fix typo in prog-indentation-context documentation (bug...
95ac082d5b Merge branch 'emacs-31' of git.savannah.gnu.org:/srv/git/...
3d9d9be3a1 CC Mode: Fontify a cast type preceding a brace initializa...
fe1c02d849 Fix Tramp distrobox integration
108710992d ; * doc/misc/ert.texi (erts files): Improve example (bug#...
0989625d36 markdown-ts-mode: fix first-item indent (bug#81118)
07e02917ee [GTK3] Re-fix the stored values for width and height
776ee085ff Eglot: mentions markdown-ts-view-mode less (bug#81150)
2d915236dc vc--subject-to-file-name: Fix over-greedy regex (bug#81017)
05f89d711d Fix more missing faces on ERC margin strings
3229d6f0e3 Eglot: Simplify markdown rendering support (bug#81150)
8855e88d74 ; Improve doc strings of brows-url commands
933d35ef10 ; * lisp/net/browse-url.el (browse-url-firefox-program): ...
This commit is contained in:
Sean Whitton 2026-06-05 11:19:07 +01:00
commit 5e160e2784
29 changed files with 1587 additions and 197 deletions

File diff suppressed because it is too large Load diff

View file

@ -5196,25 +5196,7 @@ if test "$with_features" = "no" \
with_native_compilation=no
fi
if test "${with_native_compilation}" = "default"; then
# Check if libgccjit is available.
AC_CHECK_LIB([gccjit], [gcc_jit_context_acquire],
[], [libgccjit_not_found])
AC_CHECK_HEADERS([libgccjit.h], [], [libgccjit_dev_not_found])
if test "${with_native_compilation}" != "no"; then
# Check if libgccjit really works.
AC_RUN_IFELSE([libgccjit_smoke_test], [], [libgccjit_broken])
fi
fi
if test "${with_native_compilation}" != "no"; then
if test "${HAVE_ZLIB}" = no; then
AC_MSG_ERROR(['--with-native-compilation' requires zlib])
fi
SAVE_CFLAGS=$CFLAGS
SAVE_LIBS=$LIBS
if test "${opsys}" = "darwin"; then
# Ensure libgccjit installed by Homebrew or macports can be found.
if test -n "$BREW"; then
@ -5251,15 +5233,37 @@ if test "${with_native_compilation}" != "no"; then
fi
fi
# In the default case we already checked
if test "${with_native_compilation}" != "default"; then
# Check if libgccjit is available.
AC_CHECK_LIB([gccjit], [gcc_jit_context_acquire],
[], [libgccjit_not_found_err])
AC_CHECK_HEADERS([libgccjit.h], [], [libgccjit_dev_not_found_err])
# Check if libgccjit is available.
AC_CHECK_LIB([gccjit], [gcc_jit_context_acquire], [],
[if test "${with_native_compilation}" = "default"; then
libgccjit_not_found
else
libgccjit_not_found_err
fi])
AC_CHECK_HEADERS([libgccjit.h], [],
[if test "${with_native_compilation}" = "default"; then
libgccjit_dev_not_found
else
libgccjit_dev_not_found_err
fi])
if test "${with_native_compilation}" != "no"; then
# Check if libgccjit really works.
AC_RUN_IFELSE([libgccjit_smoke_test], [], [libgccjit_broken_err])
AC_RUN_IFELSE([libgccjit_smoke_test], [],
[if test "${with_native_compilation}" = "default"; then
libgccjit_broken
else
libgccjit_broken_err
fi])
fi
fi
if test "${with_native_compilation}" != "no"; then
if test "${HAVE_ZLIB}" = no; then
AC_MSG_ERROR(['--with-native-compilation' requires zlib])
fi
SAVE_CFLAGS=$CFLAGS
SAVE_LIBS=$LIBS
HAVE_NATIVE_COMP=yes
case "${opsys}" in
# mingw32 loads the library dynamically.

View file

@ -2625,7 +2625,8 @@ avoid calling @code{widen} in their indentation code and obey
@defvar prog-indentation-context
This variable, when non-@code{nil}, holds the indentation context for
the sub-mode's indentation engine provided by the superior major mode.
The value should be a list of the form @code{(@var{first-column} . @var{rest}}.
The value should be a list of the form @w{@code{(@var{first-column}
. @var{rest})}}.
The members of the list have the following meaning:
@table @var

View file

@ -999,13 +999,13 @@ will consider it to be part of the workspace. The default is
@cindex markdown renderer
@item eglot-documentation-renderer
This variable controls how Eglot renders at-point documentation imported
from the server (@pxref{Eglot Features}). By default, the variable's
value is set during startup to the @code{gfm-view-mode} markdown
renderer if available. This utility visually enhances the documentation
content through fontification and other formatting. If you set it to
@code{t}, plain text will be requested from the server and no rendering
is attempted. If the variable's value is @code{nil}, Eglot will attempt
to find a suitable renderer every time.
from the server (@pxref{Eglot Features}). The default value is
@code{nil}, meaning Eglot selects a suitable Markdown renderer on each
use---for example, @code{gfm-view-mode} from @code{markdown-mode} on
NonGNU ELPA, which enhances documentation through fontification and
other formatting. If you set it to @code{t}, plain text is requested
from the server and no rendering is attempted. See docstring for more
options.
@item eglot-mode-map
This variable is the keymap for binding Eglot-related command. It is in

View file

@ -933,8 +933,8 @@ that start with a space are part of the value).
@example
Name: foo
Code: (indent-region
(point-min) (point-max))
Code: (lambda ()
(indent-region (point-min) (point-max)))
@end example
@table @samp

View file

@ -87,6 +87,8 @@ Agustín Martín: changed ispell.el flyspell.el fixit.texi
Ahmed Khanzada: changed gtkutil.c battery.el frame.c frame.el gtkutil.h
nsterm.m w32fns.c w32term.c w32term.h xsettings.c xsettings.h
Aidan Coyle: changed eww.el
Aidan Gauland: wrote em-tramp.el
and changed eshell.texi em-term.el em-unix.el erc-match.el em-cmpl.el
em-dirs.el em-ls.el em-script.el esh-proc.el eshell-tests.el
@ -157,7 +159,7 @@ Aleksey Kladov: changed eglot.el
Alexander Adolf: wrote eudc-capf.el eudcb-ecomplete.el
eudcb-macos-contacts.el eudcb-mailabbrev.el
and changed eudc.texi message.el eudc-vars.el ecompleterc eudc-tests.el
eudc.el mailrc
eudc.el mailrc vc.el
Alexander Becher: changed vc-annotate.el
@ -288,7 +290,7 @@ Amin Bandali: changed erc.el erc.texi erc-backend.el erc-button.el
erc-compat.el erc-track.el erc-dcc.el erc-desktop-notifications.el
erc-match.el erc-services.el erc-speedbar.el erc-status-sidebar.el
erc-autoaway.el erc-fill.el erc-goodies.el erc-ibuffer.el erc-imenu.el
erc-join.el erc-lang.el erc-list.el erc-log.el and 13 other files
erc-join.el erc-lang.el erc-list.el erc-log.el and 15 other files
Amos Bird: changed xfns.c
@ -309,7 +311,7 @@ and changed nsterm.m nsfns.m nsmenu.m nsterm.h font-lock.el nsimage.m
Anders Waldenborg: changed emacsclient.c
Andrea Alberti: changed dispextern.h faces.el xdisp.c xfaces.c
Andrea Alberti: changed xdisp.c dispextern.h faces.el xfaces.c
Andrea Corallo: wrote [native compilation of Emacs Lisp] comp-common.el
comp-cstr-tests.el comp-cstr.el comp-run.el comp-tests.el comp.c
@ -583,7 +585,7 @@ and changed progmodes/python.el eglot.el isearch.el comint.el eldoc.el
progmodes/compile.el project.el README.md bookmark.el dired.el
dockerfile-ts-mode.el files.el font-lock.el glasses.el gnutls.el man.el
message.el message.texi misc.texi modes.texi outline.el
and 16 other files
and 17 other files
Aurélien Aptel: changed alloc.c emacs-module.h lisp.h Makefile
configure.ac cus-face.el data.c dispextern.h display.texi dynlib.c
@ -1542,7 +1544,7 @@ David Ponce: wrote bovine/grammar.el cedet.el comp.el java-tags.el
semantic/java.el semantic/wisent.el senator.el tree-widget.el
wisent/grammar.el wisent/wisent.el
and co-wrote util-modes.el
and changed subr-x.el wid-edit.el image.el w32menu.c w32term.c
and changed wid-edit.el subr-x.el image.el w32menu.c w32term.c
cl-extra.el cl-types.el close.png close.xpm cus-edit.el empty.png
empty.xpm end-guide.png end-guide.xpm files.el guide.png guide.xpm
handle.png handle.xpm keyboard.c leaf.png and 36 other files
@ -1670,7 +1672,8 @@ Dionisio E Alonso: changed eglot.el
Dirk Herrmann: co-wrote bibtex.el
Dirk-Jan C. Binnema: changed configure.ac org-agenda.el xwidget.c
Dirk-Jan C. Binnema: changed xwidget.c configure.ac org-agenda.el
process.c process.h
Dirk Ullrich: changed ispell.el
@ -1809,9 +1812,9 @@ Eli Zaretskii: wrote [bidirectional display in xdisp.c]
chartab-tests.el coding-tests.el etags-tests.el rxvt.el tty-colors.el
and co-wrote help-tests.el
and changed xdisp.c display.texi w32.c msdos.c simple.el w32fns.c
files.el fileio.c keyboard.c configure.ac emacs.c text.texi w32term.c
dispnew.c frames.texi files.texi w32proc.c xfaces.c process.c window.c
dispextern.h and 1451 other files
files.el fileio.c keyboard.c configure.ac emacs.c text.texi dispnew.c
w32term.c frames.texi files.texi w32proc.c xfaces.c process.c window.c
dispextern.h and 1453 other files
Eliza Velasquez: changed server.el simple.el
@ -2093,8 +2096,8 @@ Filipp Gunbin: changed ldap.el compilation.txt progmodes/compile.el
Filippo Argiolas: changed eglot.el eglot.texi c-ts-common.el
F. Jason Park: changed erc.el erc-tests.el erc-backend.el erc-common.el
erc-stamp.el erc-fill.el erc.texi erc-goodies.el erc-button.el
F. Jason Park: changed erc.el erc-tests.el erc-backend.el erc-stamp.el
erc-common.el erc-fill.el erc.texi erc-goodies.el erc-button.el
erc-fill-tests.el erc-networks.el foonet.eld erc-compat.el erc-match.el
erc-speedbar.el erc-dcc.el erc-scenarios-common.el erc-sasl.el
erc-networks-tests.el erc-track.el erc-goodies-tests.el
@ -2648,6 +2651,8 @@ Iwamuro Motonori: changed gnus-kill.el
Jaap-Henk Hoepman: changed mm-decode.el
Jacek Migacz: changed gnus-msg.el
Jacek Świerk: changed compilation.txt compile-tests.el
progmodes/compile.el
@ -2849,9 +2854,9 @@ Jay Sachs: changed gnus-score.el gnus-win.el
J.D. Smith: co-wrote idlw-help.el idlw-shell.el idlwave.el
and changed idlw-rinfo.el comint.el idlwave.texi loaddefs-gen.el vc.el
bibtex.el byte-run.el cl-generic.el easy-mmode.el eglot.el files.texi
functions.texi hideshow.el inline.el loading.texi misc.texi mouse.el
os.texi pcase.el repeat.el shr.el and 9 other files
bibtex.el byte-run.el cl-generic.el configure.ac easy-mmode.el eglot.el
files.texi functions.texi hideshow.el inline.el loading.texi misc.texi
mouse.el os.texi pcase.el repeat.el and 10 other files
Jean Abou Samra: changed scheme.el
@ -3054,11 +3059,11 @@ João P. L. De Carvalho: changed sh-script.el
João Távora: wrote eglot-tests.el eglot.el elec-pair.el electric-tests.el
flymake-cc.el jsonrpc-tests.el jsonrpc.el message-tests.el
shorthands.el
and changed flymake.el icomplete.el EGLOT-NEWS README.md eldoc.el
and changed flymake.el EGLOT-NEWS icomplete.el README.md eldoc.el
eglot.texi minibuffer.el flymake-proc.el flymake.texi elisp-mode.el
flymake-tests.el flymake-elisp.el electric.el elisp-mode-tests.el
lread.c text.texi Makefile flymake-ui.el progmodes/python.el project.el
xref.el and 74 other files
xref.el and 77 other files
Jochen Hein: changed gnus-art.el
@ -3314,6 +3319,8 @@ Josh Huber: changed mml-sec.el mml.el message.el gnus-msg.el mml2015.el
Joshua Datko: changed fortune.el
Joshua Murphy: changed newst-treeview.el
Joshua Varner: changed intro.texi
Jostein Kjønigsen: changed csharp-mode.el typescript-ts-mode.el eglot.el
@ -3391,7 +3398,7 @@ Juri Linkov: wrote compose.el emoji.el files-x.el misearch.el
and changed isearch.el simple.el replace.el info.el dired.el treesit.el
minibuffer.el dired-aux.el window.el outline.el progmodes/grep.el
subr.el diff-mode.el repeat.el vc.el mouse.el files.el image-mode.el
menu-bar.el project.el display.texi and 526 other files
menu-bar.el project.el display.texi and 528 other files
Jussi Lahdenniemi: changed w32fns.c ms-w32.h msdos.texi w32.c w32.h
w32console.c w32heap.c w32inevt.c w32term.h
@ -3877,9 +3884,9 @@ Lin Jian: changed Makefile.in subr.el
Lin Sun: changed python-tests.el cedet/semantic.el ediff-util.el
package.el progmodes/python.el autorevert-tests.el autorevert.el
bovine/make.el calc.el esh-mode.el eww.el find-func.el html.el
java-tags.el javascript.el lread.c ls-lisp-tests.el ls-lisp.el
master.el package-test-server.py package-tests.el and 5 other files
bovine/make.el calc.el esh-mode.el eww.el find-func.el hideshow.el
html.el java-tags.el javascript.el lread.c ls-lisp-tests.el ls-lisp.el
master.el package-test-server.py and 6 other files
Lin Zhou: changed w32fns.c w32term.h
@ -3972,7 +3979,7 @@ Manuel Giraud: changed image-dired.el xdisp.c tmm.el calendar.el
doc-view.el image.c vc.el ox-html.el bookmark.el diary-lib.el
find-dired.el gnus.el image-dired-util.el keyboard.c longlines.el
midnight.el ox-publish.el simple.el smtpmail.el buff-menu.el
cal-hebrew.el and 68 other files
cal-hebrew.el and 69 other files
Manuel Gómez: changed speedbar.el
@ -4583,9 +4590,10 @@ Mohsin Kaleem: changed cus-face.el dispextern.h eglot.el term.c
Mon Key: changed animate.el imap.el syntax.el
Morgan Smith: changed doc-view.el image-dired.el window.el battery.el
dbus.texi esh-var-tests.el esh-var.el eshell.texi gnus-group-tests.el
minibuffer-tests.el minibuffer.el url-vars.el vc-git.el
Morgan Smith: changed doc-view.el gnus-dbus.el image-dired.el window.el
battery.el dbus.texi esh-var-tests.el esh-var.el eshell.texi
gnus-group-tests.el gnus-start.el gnus.texi minibuffer-tests.el
minibuffer.el url-vars.el vc-git.el
Morgan Willcock: changed tempo.el electric.el ert-font-lock.el imenu.el
modes.texi progmodes/python.el smie.el speedbar-tests.el speedbar.el
@ -5140,7 +5148,7 @@ Philip Kaludercic: wrote epa-ks.el newcomers-presets-theme.el
and co-wrote compat.el
and changed package.el rcirc.el package.texi rcirc.texi vc.el
sgml-mode.el vc-git.el project.el which-key.el package-autosuggest.eld
package-activate.el message.el startup.el subr.el custom.texi eglot.el
package-activate.el startup.el message.el subr.el custom.texi eglot.el
simple.el bytecomp.el cus-edit.el custom.el help.el and 94 other files
Philippe Altherr: changed sh-script.el sh-script-tests.el shell.sh
@ -5232,7 +5240,7 @@ Pip Cet: wrote image-circular-tests.el
and changed pdumper.c comp.c lisp.h xdisp.c alloc.c xterm.c fns.c
configure.ac emacs.c eval.c image.c comp.el frame.c print.c
src/Makefile.in byte-opt.el conf_post.h data.c doc.c ftcrfont.c
gtkutil.c and 116 other files
gtkutil.c and 119 other files
Platon Pronko: changed tramp.el
@ -5299,8 +5307,8 @@ Raffael Mancini: changed misc.el
Raffael Stocker: changed w32.c w32console.c w32fns.c w32term.h w32xfns.c
Rahul Martim Juliato: changed markdown-ts-mode.el icomplete.el
markdown-ts-mode-x.el newst-backend.el
Rahul Martim Juliato: changed markdown-ts-mode.el markdown-ts-mode-x.el
icomplete.el newst-backend.el
Raimon Grau: changed thingatpt.el calc-fin.el eww.el replace.el
thingatpt-tests.el
@ -5430,11 +5438,11 @@ Richard Lawrence: wrote calendar-tests.el diary-icalendar.el
icalendar-ast.el icalendar-macs.el icalendar-mode.el
icalendar-parser.el icalendar-recur.el icalendar-shortdoc.el
icalendar-utils.el
and changed calendar.el icalendar.el calendar.texi
diary-icalendar-tests.el icalendar-recur-tests.el diary-lib.el
icalendar-tests.el .gitattributes cal-dst.el cal-move.el cond-star.el
diary-icalendar-resources emacs.texi gnus-icalendar-tests.el
gnus-icalendar.el icalendar-ast-tests.el icalendar-parser-tests.el
and changed calendar.el diary-icalendar-tests.el icalendar-recur-tests.el
icalendar.el calendar.texi diary-lib.el gnus-icalendar.el
icalendar-parser-tests.el icalendar-tests.el .gitattributes cal-dst.el
cal-move.el cond-star.el diary-icalendar-resources emacs.texi
gnus-icalendar-tests.el icalendar-ast-tests.el
import-legacy-function.ics import-legacy-vars.ics
import-non-recurring-all-day.ics import-rrule-anniversary.ics
and 8 other files
@ -5761,7 +5769,7 @@ and co-wrote vc-tests.el
and changed vc.el vc-git.el vc-dispatcher.el vc-hg.el vc-dir.el
diff-mode.el vc-hooks.el vc1-xtra.texi log-view.el maintaining.texi
subr.el project.el log-edit.el files.texi server.el simple.el window.el
cond-star.el dired-aux.el keyboard.c vc/vc-bzr.el and 329 other files
cond-star.el dired-aux.el keyboard.c vc/vc-bzr.el and 333 other files
Sebastian Fieber: changed gnus-art.el mm-decode.el mm-view.el
@ -6007,7 +6015,7 @@ and co-wrote font-lock.el gitmerge.el pcvs.el visual-wrap.el
and changed subr.el simple.el cl-macs.el bytecomp.el files.el keyboard.c
lisp.h vc.el eval.c xdisp.c alloc.c help-fns.el buffer.c sh-script.el
package.el tex-mode.el progmodes/compile.el lread.c keymap.c window.c
easy-mmode.el and 1744 other files
easy-mmode.el and 1745 other files
Stefano Facchini: changed gtkutil.c
@ -6035,9 +6043,9 @@ Stéphane Boucher: changed replace.el
Stephane Marks: wrote savehist-tests.el system-sleep.el system-taskbar.el
and changed frame.el frames.texi nsfns.m tab-bar.el bookmark.el frame.c
nsterm.m project.el recentf.el savehist.el subr.el vtable.el w32fns.c
display.texi ibuf-macs.el os.texi saveplace.el shell.el vtable-tests.el
androidfns.c ansi-osc.el and 32 other files
nsterm.m markdown-ts-mode.el project.el recentf.el savehist.el subr.el
vtable.el w32fns.c display.texi ibuf-macs.el os.texi saveplace.el
shell.el treesit.el vtable-tests.el and 32 other files
Stephane Zermatten: changed term-tests.el term.el ansi-osc.el
@ -6330,6 +6338,8 @@ Thomas Link: wrote filesets.el
Thomas Morgan: changed org-habit.el forms.el select.el
Thomas Mühlbacher: changed progmodes/compile.el
Thomas Neumann: co-wrote make-mode.el
and changed makefile.el
@ -6929,8 +6939,8 @@ Your Name: changed configure.ac
Yuan Fu: changed treesit.el treesit.c c-ts-mode.el parsing.texi
treesit-tests.el progmodes/python.el modes.texi js.el c-ts-common.el
typescript-ts-mode.el indent.erts treesit.h java-ts-mode.el
rust-ts-mode.el css-mode.el go-ts-mode.el sh-script.el configure.ac
csharp-mode.el treesit-admin.el cmake-ts-mode.el and 88 other files
rust-ts-mode.el css-mode.el go-ts-mode.el sh-script.el cmake-ts-mode.el
configure.ac csharp-mode.el treesit-admin.el and 89 other files
Yuanle Song: changed rng-xsd.el
@ -6997,7 +7007,8 @@ Zhang Weize: wrote ob-plantuml.el
Zhehao Lin: changed xfaces.c
Zhengyi Fu: changed bookmark.el executable.el
Zhengyi Fu: changed bookmark.el executable.el progmodes/grep.el
replace.el
Zhiwei Chen: changed hideif.el

View file

@ -32,11 +32,13 @@ New key bindings: 'k' shuts down, 'r' reconnects, 'e' visits the events
buffer, 'w' shows workspace configuration, and 'RET' invokes
'eglot-describe-connection'.
** 'eglot-documentation-renderer' replaces 'eglot-prefer-plaintext'.
** New variable 'eglot-documentation-renderer' (bug#80127)
The variable 'eglot-documentation-renderer' replaces the now-obsolete
'eglot-prefer-plaintext'. By default, the variable selects a markdown
renderer to use throughout the session.
'eglot-prefer-plaintext' and offers more control over what major mode is
used to render markdown snippets. By default, the variable is nil and
'gfm-view-mode' from NonGNU ELPA's markdown-mode package is used if
found. See docstring for more details.
* Changes in Eglot 1.23 (2/4/2026)

View file

@ -1,4 +1,4 @@
;;; elisp-scope.el --- Semantic analysis for Elisp symbols -*- lexical-binding: t; -*-
;;; elisp-scope.el --- Semantic analysis for Emacs Lisp symbols -*- lexical-binding: t; -*-
;; Copyright (C) 2025-2026 Free Software Foundation, Inc.

View file

@ -1,4 +1,4 @@
;;; timeout.el --- Throttle or debounce Elisp functions -*- lexical-binding: t; -*-
;;; timeout.el --- Throttle or debounce Emacs Lisp functions -*- lexical-binding: t; -*-
;; Copyright (C) 2023-2026 Free Software Foundation, Inc.

View file

@ -399,16 +399,18 @@ This module is local to individual buffers."
(progn
(erc--restore-initialize-priors erc-keep-place-indicator-mode
erc--keep-place-indicator-overlay (make-overlay 0 0))
(when-let* (((memq erc-keep-place-indicator-style '(t arrow)))
(ov-property (if (zerop (fringe-columns 'left))
'after-string
'before-string))
(display (if (zerop (fringe-columns 'left))
`((margin left-margin) ,overlay-arrow-string)
'(left-fringe right-triangle
erc-keep-place-indicator-arrow)))
(bef (propertize " " 'display display)))
(overlay-put erc--keep-place-indicator-overlay ov-property bef))
(when (memq erc-keep-place-indicator-style '(t arrow))
(overlay-put
erc--keep-place-indicator-overlay
(if (zerop (fringe-columns 'left)) 'after-string 'before-string)
(propertize " " 'display
(if (zerop (fringe-columns 'left))
`((margin left-margin)
,(propertize overlay-arrow-string
'font-lock-face
'erc-keep-place-indicator-arrow))
'(left-fringe right-triangle
erc-keep-place-indicator-arrow)))))
(when (memq erc-keep-place-indicator-style '(t face))
(overlay-put erc--keep-place-indicator-overlay 'face
'erc-keep-place-indicator-line)))

View file

@ -478,7 +478,7 @@ and `erc-stamp--margin-left-p', before activating the mode."
(defun erc-stamp--display-prompt-in-left-margin ()
"Show prompt in the left margin with padding."
(when (or (not erc-stamp--last-prompt) (functionp erc-prompt)
(when (or (null erc-stamp--last-prompt) (functionp erc-prompt)
(> (string-width erc-stamp--last-prompt) left-margin-width))
(let ((s (buffer-substring erc-insert-marker (1- erc-input-marker))))
;; Prevent #("abc" n m (display ((...) #("abc" p q (display...))))
@ -489,7 +489,9 @@ and `erc-stamp--margin-left-p', before activating the mode."
;; This papers over a subtle off-by-1 bug here.
(unless (equal sm s)
(setq s (concat sm (substring s -1))))))
(setq erc-stamp--last-prompt (string-pad s left-margin-width nil t))))
(setq erc-stamp--last-prompt
(propertize (string-pad s left-margin-width nil t)
'font-lock-face 'erc-prompt-face))))
(put-text-property erc-insert-marker (1- erc-input-marker)
'display `((margin left-margin) ,erc-stamp--last-prompt))
erc-stamp--last-prompt)
@ -505,12 +507,15 @@ and `erc-stamp--margin-left-p', before activating the mode."
(&context (erc-stamp--display-margin-mode (eql t))
(erc-stamp--margin-left-p (eql t))
(erc-stamp--skip-left-margin-prompt-p null))
(when-let* (((null erc--hidden-prompt-overlay))
(prompt (string-pad erc-prompt-hidden left-margin-width nil 'start))
(ov (make-overlay erc-insert-marker (1- erc-input-marker)
nil 'front-advance)))
(overlay-put ov 'display `((margin left-margin) ,prompt))
(setq erc--hidden-prompt-overlay ov)))
(unless erc--hidden-prompt-overlay
(let ((ov (make-overlay erc-insert-marker (1- erc-input-marker)
nil 'front-advance)))
(overlay-put ov 'display
`((margin left-margin)
,(propertize (string-pad erc-prompt-hidden
left-margin-width nil 'start)
'font-lock-face 'erc-prompt-face)))
(setq erc--hidden-prompt-overlay ov))))
(defun erc-insert-timestamp-left (string)
"Insert timestamps at the beginning of the line."

View file

@ -2217,6 +2217,8 @@ see `message-narrow-to-headers-or-head'."
(beginning-of-line)
(while (looking-at "[ \t]")
(forward-line -1))
;; `syntax-propertize' can't widen so make sure it won't need to (bug#81035).
(syntax-propertize (point))
(narrow-to-region
(point)
(progn
@ -8659,6 +8661,9 @@ From headers in the original article."
(save-excursion
(goto-char end-of-headers)
(insert-before-markers header))))))))
;; `syntax-propertize' can't widen so make sure it won't need to
;; (bug#81035).
(syntax-propertize end-of-headers)
(narrow-to-region end-of-headers (point-max)))))
(defun message-hide-header-p (regexps)

View file

@ -317,7 +317,8 @@ Defaults to the value of `browse-url-mozilla-arguments' at the time
"zen")
"firefox")
"The name by which to invoke Firefox or a variant of it."
:type 'string)
:type 'string
:version "31.1")
(defcustom browse-url-firefox-arguments nil
"A list of strings to pass to Firefox (or variant) as arguments."
@ -1214,8 +1215,9 @@ used instead of `browse-url-new-window-flag'."
;;;###autoload
(defun browse-url-firefox (url &optional new-window)
"Ask the Firefox WWW browser to load URL.
Defaults to the URL around or before point. Passes the strings
in the variable `browse-url-firefox-arguments' to Firefox.
Defaults to the URL around or before point. Invokes the program
specified by `browse-url-firefox-program'. Passes the strings
in the variable `browse-url-firefox-arguments' to that program.
Interactively, if the variable `browse-url-new-window-flag' is non-nil,
loads the document in a new Firefox window. A non-nil prefix argument
@ -1246,9 +1248,9 @@ instead of `browse-url-new-window-flag'."
;;;###autoload
(defun browse-url-chromium (url &optional _new-window)
"Ask the Chromium WWW browser to load URL.
Default to the URL around or before point. The strings in
variable `browse-url-chromium-arguments' are also passed to
Chromium.
Default to the URL around or before point. Invokes the program
specified by `browse-url-chromium-program'. Passes the strings in
variable `browse-url-chromium-arguments' to that program.
The optional argument NEW-WINDOW is not used."
(interactive (browse-url-interactive-arg "URL: "))
(setq url (browse-url-encode-url url))
@ -1264,9 +1266,9 @@ The optional argument NEW-WINDOW is not used."
(defun browse-url-chrome (url &optional _new-window)
"Ask the Google Chrome WWW browser to load URL.
Default to the URL around or before point. The strings in
variable `browse-url-chrome-arguments' are also passed to
Google Chrome.
Default to the URL around or before point. Invokes the program
specified by `browse-url-chrome-program'. Passes to that program
the strings in variable `browse-url-chrome-arguments'.
The optional argument NEW-WINDOW is not used."
(interactive (browse-url-interactive-arg "URL: "))
(setq url (browse-url-encode-url url))
@ -1282,8 +1284,9 @@ The optional argument NEW-WINDOW is not used."
(defun browse-url-epiphany (url &optional new-window)
"Ask the GNOME Web (Epiphany) WWW browser to load URL.
Default to the URL around or before point. The strings in variable
`browse-url-epiphany-arguments' are also passed to GNOME Web.
Default to the URL around or before point. Invokes the program
specified by `browse-url-epiphany-program'. Passes the strings
in variable `browse-url-epiphany-arguments' to that program.
When called interactively, if variable `browse-url-new-window-flag' is
non-nil, load the document in a new GNOME Web window, otherwise use a
@ -1353,7 +1356,9 @@ used instead of `browse-url-new-window-flag'."
(defun browse-url-qutebrowser (url &optional new-window)
"Ask the Qutebrowser WWW browser to load URL.
Default to the URL around or before point.
Default to the URL around or before point. Invokes the program
specified by `browse-url-qutebrowser-program'. Passes the strings
in the variable `browse-url-qutebrowser-arguments' to that program.
When called interactively, if variable `browse-url-new-window-flag' is
non-nil, load the document in a new Qutebrowser window, otherwise use a

View file

@ -3081,7 +3081,7 @@ will be used."
;; We discard hops, if existing, that's why we cannot use
;; `file-remote-p'.
(prompt (format "PS1=%s %s"
(tramp-make-tramp-file-name v)
(tramp-make-tramp-file-name v 'noloc)
tramp-initial-end-of-output))
;; We use as environment the difference to toplevel
;; `process-environment'.

View file

@ -801,19 +801,23 @@ The regexp should match at end of buffer."
(? "/[fingerprint]") ")?"
(* blank))
"Regular expression matching all yes/no queries which need to be confirmed.
The confirmation should be done with yes or no.
The confirmation should be done with \"yes\" or \"no\".
The regexp should match at end of buffer.
See also `tramp-yn-prompt-regexp'."
:type 'regexp)
(defcustom tramp-yn-prompt-regexp
(rx (| (: "Store key in cache? (y/n" (* nonl) ")")
"Update cached key? (y/n, Return cancels connection)")
"Update cached key? (y/n, Return cancels connection)"
;; distrobox.
(: "Error: no such container \"" (+ nonl) "\"\n"
"Create it now, out of image " (+ nonl) "? [Y/n]:"))
(* blank))
"Regular expression matching all y/n queries which need to be confirmed.
The confirmation should be done with y or n.
The confirmation should be done with \"y\" or \"n\".
The regexp should match at end of buffer.
See also `tramp-yesno-prompt-regexp'."
:version "31.1"
:type 'regexp)
;;;###tramp-autoload

View file

@ -11687,34 +11687,37 @@ This function might do hidden buffer changes."
(forward-char)
(c-forward-syntactic-ws)
(setq cast-end (point))
(and (looking-at c-primary-expr-regexp)
(progn
(setq pos (match-end 0))
(or
;; Check if the expression begins with a prefix keyword.
(match-beginning 2)
(if (match-beginning 1)
;; Expression begins with an ambiguous operator.
(cond
((match-beginning c-per-&*+--match)
(memq at-type '(t known found)))
((match-beginning c-per-++---match)
t)
((match-beginning c-per-\(-match)
(or
(memq at-type '(t known found))
(not inside-macro)))
(t nil))
;; Unless it's a keyword, it's the beginning of a primary
;; expression.
(not (looking-at c-keywords-regexp)))))
;; If `c-primary-expr-regexp' matched a nonsymbol token, check
;; that it matched a whole one so that we don't e.g. confuse
;; the operator '-' with '->'. It's ok if it matches further,
;; though, since it e.g. can match the float '.5' while the
;; operator regexp only matches '.'.
(or (not (looking-at c-nonsymbol-token-regexp))
(<= (match-end 0) pos))))
(or
(and (looking-at c-primary-expr-regexp)
(progn
(setq pos (match-end 0))
(or
;; Check if the expression begins with a prefix keyword.
(match-beginning 2)
(if (match-beginning 1)
;; Expression begins with an ambiguous operator.
(cond
((match-beginning c-per-&*+--match)
(memq at-type '(t known found)))
((match-beginning c-per-++---match)
t)
((match-beginning c-per-\(-match)
(or
(memq at-type '(t known found))
(not inside-macro)))
(t nil))
;; Unless it's a keyword, it's the beginning of a primary
;; expression.
(not (looking-at c-keywords-regexp)))))
;; If `c-primary-expr-regexp' matched a nonsymbol token,
;; check that it matched a whole one so that we don't
;; e.g. confuse the operator '-' with '->'. It's ok if it
;; matches further, though, since it e.g. can match the float
;; '.5' while the operator regexp only matches '.'.
(or (not (looking-at c-nonsymbol-token-regexp))
(<= (match-end 0) pos)))
(and (eq (char-after) ?\{)
(not (eq (c-looking-at-statement-block-1) t)))))
;; There should either be a cast before it or something that isn't an
;; identifier or close paren.

View file

@ -537,15 +537,12 @@ or file operation kinds not in the alist."
"If non-nil, activate Eglot in cross-referenced non-project files."
:type 'boolean)
(defcustom eglot-documentation-renderer (cond ((fboundp 'gfm-view-mode)
'gfm-view-mode)
(t
nil))
"Control rendering of LSP documentation fragments.
If set to the major mode symbol `gfm-view-mode', request
markdown-snippets and use `gfm-view-mode' to render it.
If t, always request and render plain text snippets. If set to nil,
decide dynamically."
(defcustom eglot-documentation-renderer nil
"Controls rendering of LSP documentation fragments.
If set to a major mode symbol like `gfm-view-mode', or the experimental
`markdown-ts-view-mode', request markdown snippets and use that mode to
render them. If t, request and render plain text instead. If nil,
request markdown snippets and select a renderer dynamically."
:type '(choice (const :tag "Plain text" t)
(const :tag "Auto-detect" nil)
(function :tag "Renderer"))
@ -738,16 +735,11 @@ This can be useful when using docker to run a language server.")
(declare-function treesit-grammar-location "treesit.c")
(defun eglot--builtin-mdown-p ()
(and (fboundp 'markdown-ts-view-mode)
(fboundp 'treesit-grammar-location)
(treesit-grammar-location 'markdown)))
(defun eglot--accepted-formats ()
(if (and (not (eq t eglot-documentation-renderer))
(or (fboundp 'gfm-view-mode) (eglot--builtin-mdown-p)))
["markdown" "plaintext"]
["plaintext"]))
(if (or (eq t eglot-documentation-renderer)
(not (or eglot-documentation-renderer (fboundp 'gfm-view-mode))))
["plaintext"]
["markdown" "plaintext"]))
(defconst eglot--uri-path-allowed-chars
(let ((vec (copy-sequence url-path-allowed-chars)))

View file

@ -1,4 +1,4 @@
;;; lua-mode.el --- Major-mode for editing Lua files -*- lexical-binding: t -*-
;;; lua-mode.el --- Major mode for editing Lua files -*- lexical-binding: t -*-
;; Copyright (C) 2025-2026 Free Software Foundation, Inc.

View file

@ -1,4 +1,4 @@
;;; ring-bell-fns.el --- Collection of functions for ring-bell -*- lexical-binding: t; -*-
;;; ring-bell-fns.el --- Collection of functions for ring-bell-function -*- lexical-binding: t; -*-
;; Copyright (C) 2025-2026 Free Software Foundation, Inc.

View file

@ -1404,8 +1404,16 @@ If NODE is not in a list, return -1."
"Fontify unordered list marker NODE, show a symbol when markup is hidden.
OVERRIDE, START, and END are passed through to
`treesit-fontify-with-override'."
(let* ((node-start (treesit-node-start node))
;; The tree-sitter markdown grammar includes the leading indentation
;; in the first list_marker_minus/plus/star node of a list, so skip
;; over any leading whitespace to avoid overwriting the indent with
;; the replacement glyph.
(let* ((raw-start (treesit-node-start node))
(node-end (treesit-node-end node))
(node-start (save-excursion
(goto-char raw-start)
(skip-chars-forward " \t" node-end)
(point)))
(face 'markdown-ts-list-marker))
(treesit-fontify-with-override node-start node-end face
override start end)

View file

@ -1,4 +1,4 @@
;;; tty-tip.el --- Display help in kind of tooltips on ttys -*- lexical-binding: t -*-
;;; tty-tip.el --- Display tooltip-like child frames on ttys -*- lexical-binding: t -*-
;; Copyright (C) 2024-2026 Free Software Foundation, Inc.

View file

@ -1522,7 +1522,7 @@ Throw an error if another update process is in progress."
(error "Another update process is in progress, cannot run two at a time")
(let ((def-dir default-directory)
(backend vc-dir-backend))
(when vc-dir-save-some-buffers-on-revert
(when (and vc-dir-save-some-buffers-on-revert (not non-essential))
(vc-buffer-sync-fileset `(,vc-dir-backend (,def-dir)) t))
(vc-set-mode-line-busy-indicator)
;; Call the `dir-status' backend function.

View file

@ -5393,15 +5393,19 @@ of the current file."
(vc-working-revision file)))))
(defun vc--subject-to-file-name (subject)
"Generate a file name for a patch with subject line SUBJECT."
"Generate a file name for a patch with subject line SUBJECT.
The resulting filename is similar to the names generated by \"git
format-patch\", but without the leading patch sequence number \"0001-\".
Any leading \"[PATCH 1/1]\" style strings, and any text properties are
removed from SUBJECT prior to conversion."
(let* ((stripped
(replace-regexp-in-string "\\`\\[.*PATCH.*\\]\\s-*" ""
(replace-regexp-in-string "\\`\\[[^][]*PATCH[^][]*]\\s-*" ""
subject))
(truncated (if (length> stripped 50)
(substring stripped 0 50)
stripped)))
(truncated (substring-no-properties stripped
0 (min (length stripped) 50))))
(concat
(string-trim (replace-regexp-in-string "\\W" "-" truncated)
(string-trim (replace-regexp-in-string "\\W+" "-" truncated)
"-+" "-+")
".patch")))

View file

@ -1203,8 +1203,8 @@ xg_frame_set_char_size (struct frame *f, int width, int height)
outer_height /= scale;
outer_width /= scale;
height = outer_height * scale;
width = outer_width * scale;
height = height / scale * scale;
width = width / scale * scale;
xg_wm_set_size_hint (f, 0, 0);
@ -1331,8 +1331,8 @@ xg_frame_set_size_and_position (struct frame *f, int width, int height)
outer_height /= scale;
outer_width /= scale;
height = outer_height * scale;
width = outer_width * scale;
height = height / scale * scale;
width = width / scale * scale;
x /= scale;
y /= scale;

View file

@ -7662,6 +7662,12 @@ child_signal_notify (void)
static void dummy_handler (int sig) {}
static signal_handler_t volatile lib_child_handler;
/* True if Glib installs its own SIGCHLD handler that Emacs must work
around. Determined once in init_process_emacs; consulted elsewhere
(e.g. xwidget.c) to decide whether the about:blank load workaround
is needed. */
bool glib_installs_sigchld_handler;
/* Handle a SIGCHLD signal by looking for known child processes of
Emacs whose status have changed. For each one found, record its
new status.
@ -8724,6 +8730,7 @@ init_process_emacs (int sockfd)
if (lib_child_handler != dummy_handler)
{
/* The hacky workaround is needed on this platform. */
glib_installs_sigchld_handler = true;
signal_handler_t lib_child_handler_glib = lib_child_handler;
catch_child_signal ();
eassert (lib_child_handler == dummy_handler);

View file

@ -263,6 +263,8 @@ pset_gnutls_cred_type (struct Lisp_Process *p, Lisp_Object val)
/* True means don't run process sentinels. This is used
when exiting. */
extern bool inhibit_sentinels;
/* True means that Glib clobbers Emacs SIGCHLD handler. */
extern bool glib_installs_sigchld_handler;
/* Exit statuses for GNU programs that exec other programs. */
enum

View file

@ -361,13 +361,26 @@ fails. */)
g_signal_connect (G_OBJECT (ctx),
"download-started",
G_CALLBACK (webkit_download_cb), xw);
/* In process.c:init_process_emacs(), we determine whether GLib
overrides Emacs' SIGCHLD handler (based on Glib version
and kernel; see process.c for details).
webkit_web_view_load_uri (WEBKIT_WEB_VIEW (xw->widget_osr),
"about:blank");
/* webkitgtk uses GSubprocess which sets sigaction causing
Emacs to not catch SIGCHLD with its usual handle setup in
'catch_child_signal'. This resets the SIGCHLD sigaction. */
catch_child_signal ();
webkit_web_view_load_uri() is potentially affected by this
(through GSubProcess), so as a workaround we load a minimal
about:blank url and restore the SIGCHLD handler afterward.
With PGTK, this workaround has the unfortunate side-effect of
making the first load of an URI not work immediately (it needs
a refresh), so avoid the workaround when we can.
See thread
<https://lists.gnu.org/archive/html/emacs-devel/2026-04/msg00810.html>. */
if (glib_installs_sigchld_handler)
{
webkit_web_view_load_uri (WEBKIT_WEB_VIEW (xw->widget_osr),
"about:blank");
catch_child_signal ();
}
}
else
{

View file

@ -421,13 +421,14 @@
(pcase-let ((`((margin left-margin) ,displayed)
(get-text-property erc-insert-marker 'display)))
(should (equal-including-properties
displayed #(" ERC>" 4 8
( read-only t
front-sticky t
field erc-prompt
erc-prompt t
rear-nonsticky t
font-lock-face erc-prompt-face)))))
displayed #(" ERC>"
0 4 (font-lock-face erc-prompt-face)
4 8 ( read-only t
front-sticky t
field erc-prompt
erc-prompt t
rear-nonsticky t
font-lock-face erc-prompt-face)))))
(erc-fill-tests--compare "stamps-left-01")
(ert-info ("Shrink left margin by 1 col")
@ -437,13 +438,14 @@
(pcase-let ((`((margin left-margin) ,displayed)
(get-text-property erc-insert-marker 'display)))
(should (equal-including-properties
displayed #(" ERC>" 3 7
( read-only t
front-sticky t
field erc-prompt
erc-prompt t
rear-nonsticky t
font-lock-face erc-prompt-face))))))))))
displayed #(" ERC>"
0 3 (font-lock-face erc-prompt-face)
3 7 ( read-only t
front-sticky t
field erc-prompt
erc-prompt t
rear-nonsticky t
font-lock-face erc-prompt-face))))))))))
(ert-deftest erc-fill--wrap-massage-legacy-indicator-type ()
(let (calls

View file

@ -2299,6 +2299,7 @@ being the result.")
(tramp-default-proxies-alist tramp-default-proxies-alist)
(tramp-show-ad-hoc-proxies t))
(cl-letf* (((symbol-function #'read-string) #'ignore) ; Suppress password.
((symbol-function #'y-or-n-p) #'ignore) ; distrobox.
((tramp-file-name-host vec) "example.com.invalid"))
(should-error
(file-exists-p (tramp-make-tramp-file-name vec))