Lin Jian [Mon, 29 Jan 2024 22:12:43 +0000 (06:12 +0800)]
Remove an unneeded sed command for emacs.service
After commit e5348f125ff03ac70713e5b227f9e51f759a587b on
2020-12-14, there is no ExecStop in etc/emacs.service.
* Makefile.in (install-etc): Remove an unneeded sed command for
etc/emacs.service.
Thuna [Fri, 18 Nov 2022 14:56:38 +0000 (15:56 +0100)]
Highlight multiple symbols in single quotes in CL strings
* lisp/emacs-lisp/lisp-mode.el (lisp-cl-font-lock-keywords-2): When
multiple space-delimited symbols are single quoted together (e.g "`foo
bar'"), highlight them. (Bug#59360)
Thuna [Mon, 19 Dec 2022 08:33:29 +0000 (09:33 +0100)]
Fix 'rcirc-buffer-process' not working on channel buffers
* lisp/net/rcirc.el (rcirc-buffer-process): Look at BUFFER's
'rcirc-server-buffer's 'rcirc-process' instead. Signal an error if it
has none. (Bug#60191)
Trevor Arjeski [Wed, 27 Nov 2024 07:12:07 +0000 (10:12 +0300)]
Fix Gnus logo color customization
Fix a bug where customizing `gnus-logo-color-style' from use-package's
:custom keyword did not set `gnus-logo-colors' before Gnus is launched.
This patch does the following:
- Implements a :set keyword on `gnus-logo-color-style' which will
correctly set `gnus-logo-colors'
- Exposes `gnus-logo-colors' using `defcustom' for more fine-grained
customization
- Uses :set-after on `gnus-logo-colors' so that it is set after
`gnus-logo-color-style'
Manuel Giraud [Mon, 15 Jul 2024 15:33:21 +0000 (17:33 +0200)]
Remove `smtpmail-address-buffer' temporary buffer
* lisp/mail/smtpmail.el (smtpmail-address-buffer): Remove variable.
(smtpmail-send-it):
(smtpmail-deduce-address-list): Replace `smtpmail-address-buffer' with a
temporary buffer. Set `smtpmail-recipient-address-list' only in
caller. (Bug#72128)
Juri Linkov [Tue, 11 Feb 2025 17:42:33 +0000 (19:42 +0200)]
Improve outline-predicate of ts-modes (bug#74448)
* lisp/progmodes/c-ts-mode.el (c-ts-mode--outline-predicate):
Simplify since 'treesit-outline-search' was fixed in 302274b1862.
Use 'treesit-parent-until' to handle the case with "pointer_declarator".
Stefan Kangas [Tue, 11 Feb 2025 08:12:07 +0000 (09:12 +0100)]
; Don't document a complicated default
* doc/misc/message.texi (Superseding): Don't document the default value
of 'message-ignored-supersedes-headers' here; the list was out-of-date,
and is likely to become out-of-date again in the future if updated.
It's also easy enough to look up for users outside of Info.
* lisp/progmodes/project.el:
(project-remember-projects-under): Correct grammar for the singular
case. Rather than "1 projects were found", say "1 project was found".
(project-forget-projects-under): Ditto. (Bug#76016)
Stefan Kangas [Tue, 11 Feb 2025 06:13:31 +0000 (07:13 +0100)]
Update webjump.el example links
* lisp/net/webjump.el (webjump-sample-sites): Don't recommend some
defunct or otherwise non-privacy respecting websites. Prefer HTTPS to
HTTP.
(webjump-to-iwin, webjump-state-to-postal-alist): Make obsolete, as this
functionality seems to no longer work due to broken links.
Stefan Kangas [Tue, 11 Feb 2025 05:10:39 +0000 (06:10 +0100)]
Add new function lm-package-version
* lisp/emacs-lisp/lisp-mnt.el (lm-package-version): New function.
* lisp/emacs-lisp/package.el (package-buffer-info)
(package-get-version): Use above new function.
(lm-package-version): Declare.
Paul Eggert [Sat, 8 Feb 2025 23:56:04 +0000 (15:56 -0800)]
Pacify gcc -Wswitch-enum in bidi.c
* src/bidi.c (bidi_get_type, bidi_resolve_explicit)
(bidi_find_bracket_pairs, bidi_resolve_brackets)
(bidi_resolve_neutral): Use ‘switch (INT_PROMOTE (E))’
to indicate that it’s intended that we not enumerate all the enum
values.
* lisp/ansi-osc.el (ansi-osc-directory-tracker):
If 'default-directory' is a remote-file form, retain that form
when 'default-directory' changes are detected.
Martin Rudalics [Mon, 10 Feb 2025 09:58:05 +0000 (10:58 +0100)]
Implement tab line dragging with mouse (Bug#76084)
* lisp/mouse.el (mouse-drag-line): Allow tab line dragging if
there's a window above. Consider tab line height when
calculating 'position'. Add 'tab-line' binding to transient
map.
(mouse-drag-tab-line): Have it drag the tab line only (and not
the entire frame) when the tab line is between two windows.
Martin Rudalics [Mon, 10 Feb 2025 09:36:38 +0000 (10:36 +0100)]
Fix handling of visibility on tty frames (Bug#76031)
* src/frame.h (FRAME_REDISPLAY_P): Remove. Use the new function
frame_redisplay_p instead. Extern frame_redisplay_p.
* src/frame.c (frame_redisplay_p): New function to replace
FRAME_REDISPLAY_P macro.
(make_terminal_frame): Don't tinker with frame visibility and
don't make the new frame the terminal's top frame.
(do_switch_frame): Make sure frame switched to and any of its
ancestors are visible. Don't reset the visibility of other
frames.
(other_frames): Do not assume tty frames are by default visible.
(Fmake_frame_invisible): When making the selected tty frame
invisible, explicitly select the next visible frame.
* src/dispnew.c (Fredraw_display): Use frame_redisplay_p instead
of FRAME_REDISPLAY_P.
* src/xdisp.c (clear_garbaged_frames, echo_area_display)
(prepare_menu_bars, redisplay_internal, display_and_set_cursor)
(gui_clear_cursor): Use frame_redisplay_p instead of
FRAME_REDISPLAY_P.
* src/keyboard.c (tty_read_avail_input): When storing an event
and the selected frame is a child frame whose root is its
terminal's top frame, set the frame_or_window slot to the child
frame since otherwise the next switch frame event will select
the top frame instead.
* lisp/gnus/gnus-registry.el (gnus-registry-unload-function):
* lisp/gnus/spam-stat.el (spam-stat-unload-function):
* lisp/gnus/spam.el (spam-unload-function): ...to this. Don't set the
corresponding variables, always return nil, update callers, and leave
old name as obsolete function aliases.
Ref: https://lists.gnu.org/r/emacs-devel/2025-02/msg00294.html
Stefan Kangas [Sun, 9 Feb 2025 21:16:09 +0000 (22:16 +0100)]
Use unload-function instead of unload-hook in ert
* lisp/emacs-lisp/ert.el
(ert-unload-function): Rename from 'ert--unload-function'.
(ert--unload-function): Make into obsolete function alias for the above.
* lisp/textmodes/html-ts-mode.el (html-ts-mode--defun-name):
Get a grandchild 'tag_name' from 'element' that was already
defined by 'treesit-defun-type-regexp'.
(html-ts-mode--outline-predicate): New function.
(html-ts-mode): Add "comment" to the 'list' thing
in 'treesit-thing-settings'. Use "tag_name" and "attribute"
in 'sentence' to conform to sentence navigating arguments
in other ts-modes. Remove unnecessary heading
from 'treesit-simple-imenu-settings' and use "element"
supported by 'html-ts-mode--defun-name'.
Set 'treesit-outline-predicate' to 'html-ts-mode--outline-predicate'.
* lisp/textmodes/yaml-ts-mode.el (yaml-ts-mode--defun-name)
(yaml-ts-mode--outline-predicate): New functions.
(yaml-ts-mode): Set 'treesit-defun-type-regexp',
'treesit-defun-name-function', 'treesit-defun-tactic'.
Add 'sentence' to 'treesit-thing-settings'.
Set 'treesit-simple-imenu-settings' and 'treesit-outline-predicate'.
Use 'kill-local-variable' for 'forward-sexp-function'
and 'show-paren-data-function' instead of resetting their value.
* lisp/treesit.el (treesit-outline-search): Check for the thing
before the end of the line to support such case when the thing
fits on the current line and ends before the end of the line
such as e.g. '<h1>...</h1>' in html-ts-mode.
(treesit-hs-find-next-block, treesit-hs-inside-comment-p):
Use anchors for "\\`comment\\'" (bug#75609).
Put the property 'mode-class' with the value 'special' on the symbol
'diff-mode'. This fixes the case when 'view-read-only' is non-nil
by disabling activation of 'view-mode' that overrides single keys
from 'diff-mode-shared-map' (bug#75993).
Po Lu [Sun, 9 Feb 2025 04:06:52 +0000 (12:06 +0800)]
Fix program execution on Android 15 QPR2 Beta
* exec/trace.c (process_vm_readv, process_vm_writev): New
function pointers. Attempt to load them on recent Android
systems when `exec' was not linked with a sufficiently
up-to-date libc.
(read_memory, user_copy): Always use process_vm_readv and
process_vm_writev if available.
(handle_openat): Write trailing NULL byte of filename to user
buffer.
(exec_init): Attempt to dlsym process_vm_readv and
process_vm_writev.
shipmints [Fri, 7 Feb 2025 19:25:50 +0000 (14:25 -0500)]
Eliminate savehist duplicated symbols
* lisp/savehist.el (savehist-save): Do not save symbols
duplicated between 'savehist-minibuffer-history-variables'
and 'savehist-additional-variables'. (Bug#76123)
* test/lisp/savehist-tests.el: New file.
Jared Finder [Thu, 6 Feb 2025 22:32:00 +0000 (14:32 -0800)]
Cleanup tool-bar-mode documentation
* doc/emacs/frames.texi (Tool Bars): Downcase concept index
text.
* lisp/cus-start.el (standard): Copy custom :tag strings
from window-tool-bar-style's, which are more descriptive.
(Bug#75844)
Jared Finder [Sun, 2 Feb 2025 18:11:20 +0000 (10:11 -0800)]
Update window-tool-bar
Add support for the remaining tool bar item specs, new user
option `window-tool-bar-style', and add support for older
Emacs versions.
* doc/emacs/windows.texi (Window Tool Bar): Add documentation
for new user option `window-tool-bar-style'.
* lisp/window-tool-bar.el
(customize-package-emacs-version-alist): Add package-version to
Emacs version mapping.
(window-tool-bar-string): Do not show spacers after hidden
buttons.
(window-tool-bar--keymap-entry-to-string): Call new function
`window-tool-bar--style'. Add handling for :visible, :filter,
:button, :vert-only, and :help item specs. Show key bindings.
(window-tool-bar--last-command-triggers-refresh-p): Use "cannot"
in comment.
(window-tool-bar--allow-images): Delete this, it is replaced by
new user option `window-tool-bar-style'.
(window-tool-bar--use-images): Delete this, it is replaced by
new function `window-tool-bar--style'.
(window-tool-bar--turn-on): Move earlier in file, no changes.
(window-tool-bar-style): New user option supporting all values
`tool-bar-style' supports as well as inheriting from
tool-bar-style.
(window-tool-bar--style): New function to calculate active tool
bar style based on `window-tool-bar-style', `tool-bar-style',
and frame capabilities.
(global-window-tool-bar-mode, window-tool-bar-button)
(window-tool-bar-button-hover, window-tool-bar-button-disabled):
Retroactively add package-version.
(window-tool-bar-button-checked)
(window-tool-bar-button-checked-hover): New faces for :button
item spec.
(window-tool-bar--get-keymap): Call new function
`window-tool-bar--style'. (Bug#75844)
Björn Bidar [Tue, 21 Jan 2025 23:28:22 +0000 (01:28 +0200)]
Add 'nnregistry-request-group' function for 'gnus-refer-article'
nnregistry doesn't handle any servers or groups; however we have to
define the dummy function so Gnus-registry works as refer article
method, as the `gnus-check-group-server' function requires it.
The latter function is called when referring to articles to check the
source group first before actually requesting any articles.
* lisp/gnus/nnregistry.el (nnregistry-request-group): New deffoo.
(Bug#22414)
Nicolas Despres [Sat, 21 Dec 2024 11:45:12 +0000 (12:45 +0100)]
Prioritize split along the longest edge by default.
Currently, `split-window-sensibly' prefers to try to split
vertically first, disregarding the actual shape of the frame
or the user preferences. This is a good default when Emacs
is taller than wider. However, when Emacs is in full-screen
(landscape screen layout), trying to split vertically may not
be what the user expected, since there is plenty of space
available on the right.
Typical scenario: Emacs is in landscape layout, one buffer is
open in a window covering the entire frame. Another buffer is
opened in a second window (C-x 4 f). Both splits are feasible
but users may prefer the horizontal one.
This patch preserves the behavior of the `split-height-threshold'
and `split-width-threshold' variables. Splitting continues not
to be permitted if the edge length is below the threshold.
* lisp/window.el (split-window-sensibly): First tried split
direction follows user preferences.
* etc/NEWS: Add an entry for new variable
`split-window-preferred-direction'.
* doc/emacs/windows.texi: Document new variable.
F. Jason Park [Sat, 8 Feb 2025 02:54:22 +0000 (18:54 -0800)]
; Make ERC test fixture more robust
* test/lisp/erc/erc-tests.el (erc-tests--assert-printed-in-subprocess):
Scan for sentinel before reading.
(erc--find-mode, erc--essential-hook-ordering): Use contrived :result
protocol expected by `erc-tests--assert-printed-in-subprocess'.
* test/lisp/erc/resources/erc-tests-common.el
(erc-tests-common-create-subprocess): Divert stderr to messages buffer.
F. Jason Park [Tue, 4 Feb 2025 14:11:50 +0000 (06:11 -0800)]
More clearly define local module behavior in ERC
* doc/misc/erc.texi (Modules): Label all local modules as being such.
Move `querypoll' to the auxiliary section. Rework entire "Local
Modules" portion.
* lisp/erc/erc-goodies.el (erc-keep-place-indicator-mode)
(erc-command-indicator-mode): Mention what buffer types they operate in.
* lisp/erc/erc-nicks.el (erc-nicks-mode): Mention the mode is enabled in
all buffers.
* lisp/erc/erc-notify.el (erc-querypoll-mode): Mention which buffers it
operates in.
* lisp/erc/erc-sasl.el (erc-sasl-mode): Disable completely in target
buffers so its mode variable is nil.
* lisp/erc/erc-services.el (erc-services-regain-mode): Disable in target
buffers.
* lisp/erc/erc.el (erc-open): When activating local modules, skip those
that have just been enabled by a fellow module. Do this even though
their setup code is meant to be idempotent.
* test/lisp/erc/erc-scenarios-base-local-modules.el
(erc-scenarios-base-local-modules--toggle-helpers): Revise to assert
current behavior. (Bug#57955)