]> git.eshelyaron.com Git - emacs.git/log
emacs.git
3 years agoMerge from origin/emacs-28
Glenn Morris [Wed, 27 Oct 2021 14:59:28 +0000 (07:59 -0700)]
Merge from origin/emacs-28

2bdd5732aa (origin/emacs-28) ; * etc/NEWS: Fix last change.
492b927909 Fix help commands for menu-bar menus
9589be772d ; * etc/NEWS: Fix typos.
d353fc4a00 ; Explain why "kinds of atom" isn't a typo
47a3750162 ; * etc/NEWS: Improve wording of the Emoji entry.
b814712796 ; Checkdoc fixes in image-dired.el
e45b3fc521 Improve function documentation with text from XDG BDS spec
284c77eeb6 * lisp/transient.el: Update to package version 0.3.7.
40400e6977 ; Revert parts of "Use string-replace instead of replace-r...
214c2e268c ; Revert parts of "Use string-search instead of string-mat...

# Conflicts:
# etc/NEWS

3 years agoSimplify string-pixel-width
Lars Ingebrigtsen [Wed, 27 Oct 2021 14:50:40 +0000 (16:50 +0200)]
Simplify string-pixel-width

* lisp/emacs-lisp/subr-x.el (string-pixel-width): Simplify --
save-window-excursion saves dedication status (and the code was
buggy).

3 years ago; * etc/NEWS: Fix last change.
Eli Zaretskii [Wed, 27 Oct 2021 14:13:59 +0000 (17:13 +0300)]
; * etc/NEWS: Fix last change.

3 years agoFix parsing of erts files
Lars Ingebrigtsen [Wed, 27 Oct 2021 14:13:30 +0000 (16:13 +0200)]
Fix parsing of erts files

* lisp/emacs-lisp/ert.el (ert-test-erts-file): Fix progress
through a test file (bug#51409).

3 years agoHarden ert-resource-directory against errors
Lars Ingebrigtsen [Wed, 27 Oct 2021 14:04:31 +0000 (16:04 +0200)]
Harden ert-resource-directory against errors

* lisp/emacs-lisp/ert-x.el (ert-resource-directory): Be more
resilient -- don't bug out if called from a file that's not
visiting a directory.

3 years agoBe more efficient when checking for a matching client in server.el
Jim Porter [Wed, 27 Oct 2021 13:54:42 +0000 (15:54 +0200)]
Be more efficient when checking for a matching client in server.el

lisp/server.el (server-handle-delete-frame): Use 'seq-some' to
determine if another frame for the current client exists.
(server-kill-emacs-query-function): Use 'seq-some' to determine if
another live client exists (bug#51420).

3 years agoAdd new function 'string-pixel-width'
Lars Ingebrigtsen [Wed, 27 Oct 2021 13:41:18 +0000 (15:41 +0200)]
Add new function 'string-pixel-width'

* doc/lispref/display.texi (Size of Displayed Text): Mention it.
* lisp/emacs-lisp/shortdoc.el (string): Mention it.

* lisp/emacs-lisp/subr-x.el (string-pixel-width): New function.

3 years agoAllow matching non-.git gitlab and gitea URLs in bug-reference
Miha Rihtaršič [Tue, 26 Oct 2021 08:54:54 +0000 (10:54 +0200)]
Allow matching non-.git gitlab and gitea URLs in bug-reference

* lisp/progmodes/bug-reference.el
(bug-reference--build-forge-setup-entry): Allow matching non-.git
gitlab and gitea URLs, with and without slashes (bug#51316).

3 years ago; * src/atimer.c (init_atimer): Fix a typo in a comment.
Eli Zaretskii [Wed, 27 Oct 2021 13:14:55 +0000 (16:14 +0300)]
; * src/atimer.c (init_atimer): Fix a typo in a comment.

3 years agoFix help commands for menu-bar menus
Eli Zaretskii [Wed, 27 Oct 2021 13:09:47 +0000 (16:09 +0300)]
Fix help commands for menu-bar menus

* lisp/help.el (help--analyze-key): Fix "C-h c" and "C-h k" on
menu-bar menu items.  (Bug#51421)

3 years agoAlways start the SIGALRM atimers
Lars Ingebrigtsen [Wed, 27 Oct 2021 12:58:08 +0000 (14:58 +0200)]
Always start the SIGALRM atimers

* src/atimer.c (init_atimer): Always start the SIGALRM alarms,
even if we're using timerfd (bug#19776).  See long, long
discussion in the bug report for why this is necessary.

3 years agoRedisplay after changing to the hourglass mouse pointer
Lars Ingebrigtsen [Wed, 27 Oct 2021 12:56:50 +0000 (14:56 +0200)]
Redisplay after changing to the hourglass mouse pointer

* src/xterm.c (x_show_hourglass): Do a redisplay after changing to
the hourglass pointer -- otherwise it won't be displayed until a
keyboard/mouse event arrives (bug#19776).

3 years ago; * etc/NEWS: Fix typos.
Michael Albinus [Wed, 27 Oct 2021 12:11:09 +0000 (14:11 +0200)]
; * etc/NEWS: Fix typos.

3 years ago; Explain why "kinds of atom" isn't a typo
Eli Zaretskii [Wed, 27 Oct 2021 11:33:42 +0000 (14:33 +0300)]
; Explain why "kinds of atom" isn't a typo

* doc/lispintro/emacs-lisp-intro.texi (Lisp Atoms): Add a comment
explaining why "kinds of atom" isn't a typo.

3 years ago; * etc/NEWS: Improve wording of the Emoji entry.
Eli Zaretskii [Wed, 27 Oct 2021 11:32:18 +0000 (14:32 +0300)]
; * etc/NEWS: Improve wording of the Emoji entry.

3 years agoimage-dired: Set line-spacing to match horizontal space
Stefan Kangas [Wed, 27 Oct 2021 05:51:35 +0000 (07:51 +0200)]
image-dired: Set line-spacing to match horizontal space

* lisp/image-dired.el (image-dired-thumbnail-mode): Set value of
'line-spacing' to approximately match horizontal space.  This makes
the thumbnail view look better.

3 years ago; * test/lisp/files-tests.el: Fix last commit.
Stefan Kangas [Wed, 27 Oct 2021 05:05:33 +0000 (07:05 +0200)]
; * test/lisp/files-tests.el: Fix last commit.

3 years agoimage-dired: Add support for bookmark.el
Stefan Kangas [Wed, 27 Oct 2021 04:05:39 +0000 (06:05 +0200)]
image-dired: Add support for bookmark.el

* lisp/image-dired.el (image-dired-thumbnail-mode): Add bookmark.el support.
(bookmark-make-record-default, bookmark-prop-get): Declare.
(image-dired-bookmark-name, image-dired-bookmark-make-record)
(image-dired-bookmark-jump): New defuns.

3 years agoAdd test for file-name-base
Stefan Kangas [Wed, 27 Oct 2021 03:34:52 +0000 (05:34 +0200)]
Add test for file-name-base

* test/lisp/files-tests.el (files-tests-file-name-base): New test.

3 years ago; * lisp/image-dired.el: Move obsolete things to "Obsolete" section
Stefan Kangas [Wed, 27 Oct 2021 03:16:05 +0000 (05:16 +0200)]
; * lisp/image-dired.el: Move obsolete things to "Obsolete" section

3 years ago; Checkdoc fixes in image-dired.el
Stefan Kangas [Wed, 27 Oct 2021 02:53:41 +0000 (04:53 +0200)]
; Checkdoc fixes in image-dired.el

3 years agoimage-dired: Improve mouse behaviour
Stefan Kangas [Wed, 27 Oct 2021 02:34:25 +0000 (04:34 +0200)]
image-dired: Improve mouse behaviour

* lisp/image-dired.el (image-dired-thumbnail-mode-map): Improve mouse
behaviour: ignore dragging, as it currently doesn't do anything
useful, and make all clicks just select the thumbnail.
(image-dired-mouse-display-image)
(image-dired-mouse-select-thumbnail): Move point to closest image
after clicking in buffer.

3 years agoimage-dired: Don't ding at beginning or end of buffer
Stefan Kangas [Wed, 27 Oct 2021 01:43:21 +0000 (03:43 +0200)]
image-dired: Don't ding at beginning or end of buffer

* lisp/image-dired.el
(image-dired--display-thumb-properties-fun): New defun.
(image-dired-forward-image, image-dired-backward-image): Don't ding
when moving past first or last image; instead show a message, wait a
second and then show image properties.

3 years agoimage-dired: Add new commands for beginning/end of buffer
Stefan Kangas [Wed, 27 Oct 2021 01:23:49 +0000 (03:23 +0200)]
image-dired: Add new commands for beginning/end of buffer

* lisp/image-dired.el (image-dired-beginning-of-buffer)
(image-dired-end-of-buffer): New commands.
(image-dired-thumbnail-mode-map): Bind new beginning of buffer command
to '<' and 'M-<', and end of buffer command to '>' and 'M->'.

3 years agoAdd new function image-at-point-p
Stefan Kangas [Wed, 27 Oct 2021 01:22:09 +0000 (03:22 +0200)]
Add new function image-at-point-p

* lisp/image.el (image-at-point-p): New defun.
* doc/lispref/display.texi (Showing Images): Document above new defun.

3 years agoimage-dired: Use an evenly spaced grid for thumbnails
Stefan Kangas [Wed, 27 Oct 2021 00:36:57 +0000 (02:36 +0200)]
image-dired: Use an evenly spaced grid for thumbnails

* lisp/image-dired.el (image-dired-line-up): Use an evenly spaced
grid for thumbnails, even if image sizes differ.

3 years ago; * lisp/image-dired.el (image-dired-cmd-pngnq-options): Fix :version.
Stefan Kangas [Wed, 27 Oct 2021 00:07:35 +0000 (02:07 +0200)]
; * lisp/image-dired.el (image-dired-cmd-pngnq-options): Fix :version.

3 years agoimage-dired: Use example.org in examples
Stefan Kangas [Wed, 27 Oct 2021 00:00:24 +0000 (02:00 +0200)]
image-dired: Use example.org in examples

* lisp/image-dired.el (image-dired-gallery-image-root-url)
(image-dired-gallery-thumb-image-root-url): Use example.org to be
RFC 2606 compliant.

3 years agoimage-dired: Increase number of asynch thumbnail generation jobs
Stefan Kangas [Tue, 26 Oct 2021 23:32:58 +0000 (01:32 +0200)]
image-dired: Increase number of asynch thumbnail generation jobs

* lisp/image-dired.el (image-dired-queue-active-limit): Increase the
number of asynchronous thumbnail generation jobs to a maximum of 4 or
processor count divided by 2.  This makes thumbnail generation around
30 % faster when benchmarking this on my machine (8 cores/4 jobs).

(image-dired-debug): New defvar.
(image-dired-debug-message): New defun.

(image-dired--generate-thumbs-start): New defvar.
(image-dired-create-thumb-1, image-dired-display-thumbs): Display time
spent on thumbnail generation if 'image-dired-debug' is non-nil.

3 years agoImprove function documentation with text from XDG BDS spec
Stefan Kangas [Tue, 26 Oct 2021 21:17:29 +0000 (23:17 +0200)]
Improve function documentation with text from XDG BDS spec

* lisp/xdg.el (xdg-config-home, xdg-cache-home, xdg-data-home)
(xdg-runtime-dir, xdg-config-dirs, xdg-data-dirs): Copy in the
text from the XDG Base Directory Specification to better explain
what these functions return.

3 years agoCC Mode: minor amendments more accurately to handle virtual semicolons, etc.
Alan Mackenzie [Tue, 26 Oct 2021 20:13:18 +0000 (20:13 +0000)]
CC Mode: minor amendments more accurately to handle virtual semicolons, etc.

* lisp/progmodes/cc-engine.el (c-laomib-loop): Check for a virtual semicolon
as well as a ;.
(c-guess-basic-syntax): CASE 5D - Use c-crosses-statement-barrier-p to check
whether we've gone back past a virtual semicolon.

3 years ago* lisp/progmodes/cc-engine.el (c-fontify-new-found-type): Declare near BO File
Alan Mackenzie [Tue, 26 Oct 2021 16:54:01 +0000 (16:54 +0000)]
* lisp/progmodes/cc-engine.el (c-fontify-new-found-type): Declare near BO File

3 years ago* test/infra/gitlab-ci.yml (build-image-inotify): Increase timeout.
Michael Albinus [Tue, 26 Oct 2021 16:52:39 +0000 (18:52 +0200)]
* test/infra/gitlab-ci.yml (build-image-inotify): Increase timeout.

(test-native-comp-speed0): Adapt make_params.

3 years ago* lisp/progmodes/xref.el (xref-pop-marker-stack): Don't obsolete.
Mattias Engdegård [Tue, 26 Oct 2021 08:10:02 +0000 (10:10 +0200)]
* lisp/progmodes/xref.el (xref-pop-marker-stack): Don't obsolete.

3 years ago; * test/lisp/progmodes/elisp-mode-tests.el: repair test failure
Mattias Engdegård [Tue, 26 Oct 2021 08:04:24 +0000 (10:04 +0200)]
; * test/lisp/progmodes/elisp-mode-tests.el: repair test failure

The test used an internal variable that has been renamed; use the new
name.  (Any variable would do here.)

3 years agoRename `xref-pop-marker-stack` to `xref-go-back` (bug#38797)
Mattias Engdegård [Mon, 25 Oct 2021 18:38:31 +0000 (20:38 +0200)]
Rename `xref-pop-marker-stack` to `xref-go-back` (bug#38797)

It is the natural name after the addition of `xref-go-forward`.
The old name is retained as an alias.

* lisp/progmodes/xref.el (xref-pop-marker-stack): Rename.
(xref-go-forward, xref-quit-and-pop-marker-stack)
(xref-find-definitions):
* lisp/menu-bar.el (menu-bar-goto-menu):
* lisp/progmodes/etags.el (find-tag-marker-ring, pop-tag-mark):
* lisp/progmodes/prog-mode.el (prog-context-menu):
* doc/emacs/maintaining.texi (Looking Up Identifiers):
* etc/NEWS:
Use the new name.

3 years ago; * lisp/menu-bar.el (menu-bar-goto-menu): Adjust new item position
Mattias Engdegård [Mon, 25 Oct 2021 18:21:25 +0000 (20:21 +0200)]
; * lisp/menu-bar.el (menu-bar-goto-menu): Adjust new item position

3 years ago* lisp/transient.el: Update to package version 0.3.7.
Jonas Bernoulli [Mon, 25 Oct 2021 18:19:52 +0000 (20:19 +0200)]
* lisp/transient.el: Update to package version 0.3.7.

3 years ago; Revert parts of "Use string-replace instead of replace-regexp-in-string"
Jonas Bernoulli [Mon, 25 Oct 2021 18:16:54 +0000 (20:16 +0200)]
; Revert parts of "Use string-replace instead of replace-regexp-in-string"

"transient.el" is also distributed as a separate package, which
supports Emacs versions as old as 25.1 (see "Package-Requires").

3 years ago; Revert parts of "Use string-search instead of string-match[-p]"
Jonas Bernoulli [Mon, 25 Oct 2021 18:15:28 +0000 (20:15 +0200)]
; Revert parts of "Use string-search instead of string-match[-p]"

"transient.el" is also distributed as a separate package, which
supports Emacs versions as old as 25.1 (see "Package-Requires").

3 years agoIMAP search should only use charset utf-8 with multibyte strings
Eric Abrahamsen [Mon, 25 Oct 2021 16:39:52 +0000 (09:39 -0700)]
IMAP search should only use charset utf-8 with multibyte strings

Background: Exchange servers cannot accept "charset utf-8" search
strings. The code originally set that charset for any server with
literal+ capability, borking all searches on an Exchange server. This
code only sets utf-8 for multibyte search strings in particular, which
would be borken for Exchange anyway.

* lisp/gnus/gnus-search.el (gnus-search-imap-search-command): Ensure
we're only doing the literal+ dance for multibyte strings (multibyte
strings will have had newlines inserted in an earlier step).

3 years agoMerge from origin/emacs-28
Glenn Morris [Mon, 25 Oct 2021 16:34:37 +0000 (09:34 -0700)]
Merge from origin/emacs-28

a2c17e115e (origin/emacs-28) Merge branch 'emacs-28' of git.savannah....
fde56eeb76 Revert "Fix a typo in emacs-lisp-intro.texi"
4779d3ba19 * doc/lispref/functions.texi (Mapping Functions): Use #' w...
85ea3f7f47 Fix issue with interpreting ANSI codes in eshell
50f9436146 image-dired: Doc fix to better explain thumbnail generation
bb475e10b9 Clarify two image-dired docstrings
f5b4bb4a6f Fix flymake example backend conditions in the manual
0771d8939a * etc/PROBLEMS: Mention problems with regexp matcher.  (Bu...
ee579033b9 * test/lisp/repeat-tests.el: New file.
7385a7667f * lisp/tab-bar.el (tab-bar-move-repeat-map): Fix alias bin...
56caf1c9b8 Use restrictive umask when creating image-dired data
3b5de7f991 ; lisp/transient.el: Revert some misguided stylistic fixes.

3 years ago; Merge from origin/emacs-28
Glenn Morris [Mon, 25 Oct 2021 16:34:37 +0000 (09:34 -0700)]
; Merge from origin/emacs-28

The following commit was skipped:

3f763898aa Fix compilation errors with MinGW64 GCC 11

3 years agoMerge from origin/emacs-28
Glenn Morris [Mon, 25 Oct 2021 16:34:37 +0000 (09:34 -0700)]
Merge from origin/emacs-28

817c929eda Doc fix for concat
3eca2ad2a1 * lisp/image-dired.el (image-dired-external-viewer): Suppo...

3 years ago* doc/misc/cc-mode.texi (Font Locking): Fix menu.
Glenn Morris [Mon, 25 Oct 2021 16:33:11 +0000 (17:33 +0100)]
* doc/misc/cc-mode.texi (Font Locking): Fix menu.

3 years agoMerge branch 'emacs-28' of git.savannah.gnu.org:/srv/git/emacs into emacs-28
Eli Zaretskii [Mon, 25 Oct 2021 16:19:55 +0000 (19:19 +0300)]
Merge branch 'emacs-28' of git.savannah.gnu.org:/srv/git/emacs into emacs-28

3 years agoRevert "Fix a typo in emacs-lisp-intro.texi"
Eli Zaretskii [Mon, 25 Oct 2021 16:11:06 +0000 (19:11 +0300)]
Revert "Fix a typo in emacs-lisp-intro.texi"

This reverts commit 98eb6d783a482cd7ebca7ec656b0775b82c68e57.
I've consulted with Richard Stallman about this, and he says
that the original wording, "kinds of atom", is both correct
and more elegant writing.  So I'm restoring the original text.
* doc/lispintro/emacs-lisp-intro.texi (Lisp Atoms): Undo the
fix of a "typo" that wasn't a typo.  (Bug#51271)

3 years agoAdd the "always" zsh builtin to zsh mode
Lars Ingebrigtsen [Mon, 25 Oct 2021 15:41:52 +0000 (17:41 +0200)]
Add the "always" zsh builtin to zsh mode

* lisp/progmodes/sh-script.el (sh-builtins): Add the "always" zsh
keyword (bug#51387).

3 years agoAdd xref forward history (bug#38797)
Mattias Engdegård [Tue, 19 Oct 2021 11:26:19 +0000 (13:26 +0200)]
Add xref forward history (bug#38797)

Make it possible to go forward as well as back in the Xref history.
The new `xref-go-forward` is bound to `C-M-,`.

* lisp/progmodes/etags.el (find-tag-marker-ring-length): Update.
(tags-location-ring-length): New.
(find-tag-marker-ring): Keep as dummy.
(tags-location-ring, tags-reset-tags-tables):
Use `tags-location-ring-length` instead of `xref-marker-ring-length`.
* lisp/progmodes/xref.el (xref-marker-ring-length, xref-marker-ring)
(xref-set-marker-ring-length):
Make obsolete.
(xref--history, xref-go-forward, xref-forward-history-empty-p): New.
(xref-push-marker-stack, xref-pop-marker-stack)
(xref-clear-marker-stack, xref-marker-stack-empty-p):
Use `xref--history`.
* lisp/menu-bar.el (menu-bar-goto-menu): Add Forward entry.
* doc/emacs/maintaining.texi (Looking Up Identifiers): Document.
* etc/NEWS: Announce.

3 years agoAllow viewing .heic images via image-convert
Lars Ingebrigtsen [Mon, 25 Oct 2021 15:19:32 +0000 (17:19 +0200)]
Allow viewing .heic images via image-convert

* lisp/files.el (auto-mode-alist): Support the Apple .heic/HEIF
image format (bug#51381).

3 years agoChange the with-delayed-message syntax to allow future extensibility
Lars Ingebrigtsen [Mon, 25 Oct 2021 15:10:34 +0000 (17:10 +0200)]
Change the with-delayed-message syntax to allow future extensibility

* doc/lispref/display.texi (Progress): Document it.
* lisp/subr.el (with-delayed-message): Change the syntax to allow
future extensibility.

* lisp/net/eww.el (eww-display-html): Use it.

3 years agoHeed the EMACS_IGNORE_TIMERFD environment variable
Lars Ingebrigtsen [Mon, 25 Oct 2021 14:49:48 +0000 (16:49 +0200)]
Heed the EMACS_IGNORE_TIMERFD environment variable

* src/emacs.c (main): Call init_atimer after setting up the
environment so that the EMACS_IGNORE_TIMERFD environment variable
is actually heeded.

3 years ago* doc/lispref/functions.texi (Mapping Functions): Use #' when mapping.
Robert Pluim [Mon, 25 Oct 2021 13:34:48 +0000 (15:34 +0200)]
* doc/lispref/functions.texi (Mapping Functions): Use #' when mapping.

3 years agoFix issue with interpreting ANSI codes in eshell
Miha Rihtaršič [Mon, 25 Oct 2021 13:24:29 +0000 (15:24 +0200)]
Fix issue with interpreting ANSI codes in eshell

* lisp/eshell/esh-mode.el (eshell-mode): Make window point advance on
insertion.
(eshell-output-filter): Don't use insert-before-markers (bug#45380).

3 years ago; Fix mangled indentation in 'display-buffer' doc-string
Martin Rudalics [Mon, 25 Oct 2021 09:26:33 +0000 (11:26 +0200)]
; Fix mangled indentation in 'display-buffer' doc-string

3 years agoAllow 'display-buffer' to set up body size of chosen window (Bug#17065)
Martin Rudalics [Mon, 25 Oct 2021 08:42:17 +0000 (10:42 +0200)]
Allow 'display-buffer' to set up body size of chosen window (Bug#17065)

* doc/lispref/windows.texi (Buffer Display Action Alists):
Describe new possible values for 'window-height', 'window-width'
and 'window-size' action alist entries.
* lisp/window.el (window--display-buffer): Handle new values for
'window-height', 'window-width' and 'window-size' ALIST entries.
(display-buffer): Update doc-string for new values of some
action alist entries.
* etc/NEWS: Mention new values of some action alist entries.

3 years agoNew function xdg-state-home
Stefan Kangas [Mon, 25 Oct 2021 05:51:02 +0000 (07:51 +0200)]
New function xdg-state-home

* lisp/xdg.el (xdg-state-home): New function.  This returns
$XDG_STATE_HOME according to the XDG Base Directory Specification
version 0.8 (08th May 2021).

3 years agoimage-dired: Improve XDG compliance
Stefan Kangas [Mon, 25 Oct 2021 04:44:30 +0000 (06:44 +0200)]
image-dired: Improve XDG compliance

* lisp/image-dired.el (xdg): Require.
(image-dired-main-image-directory): Prefer XDG_PICTURES_HOME.
(image-dired-thumb-name): Simplify by using 'xdg-cache-home'.

3 years agoDouble value of image-dired-show-all-from-dir-max-files
Stefan Kangas [Mon, 25 Oct 2021 03:47:56 +0000 (05:47 +0200)]
Double value of image-dired-show-all-from-dir-max-files

* lisp/image-dired.el (image-dired-show-all-from-dir-max-files):
Double the amount of files in directory before prompting.  This could
be even higher, as the thumbnails are generated asynchronously and are
small by default.

3 years agoimage-dired: Doc fix to better explain thumbnail generation
Stefan Kangas [Mon, 25 Oct 2021 02:48:12 +0000 (04:48 +0200)]
image-dired: Doc fix to better explain thumbnail generation

* doc/emacs/dired.texi (Image-Dired): Improve description by
explaining that the generation of thumbnails is asynchronous.

3 years agoimage-dired: Add support for GraphicsMagick
Stefan Kangas [Mon, 25 Oct 2021 01:50:04 +0000 (03:50 +0200)]
image-dired: Add support for GraphicsMagick

* lisp/image-dired.el (image-dired-cmd-create-thumbnail-program)
(image-dired-cmd-create-thumbnail-options)
(image-dired-cmd-create-temp-image-program)
(image-dired-cmd-create-temp-image-options)
(image-dired-cmd-rotate-thumbnail-program)
(image-dired-cmd-rotate-thumbnail-options): Add support for the
GraphicsMagick command line tool ("gm convert", "gm mogrify").

3 years agoFix issues with type casting in delayed message functions
Lars Ingebrigtsen [Mon, 25 Oct 2021 00:19:39 +0000 (02:19 +0200)]
Fix issues with type casting in delayed message functions

* src/eval.c (with_delayed_message_display)
(with_delayed_message_cancel, Ffuncall_with_delayed_message): Fix
some type confusion.

3 years agoSupport new Thumbnail Managing Standard sizes in image-dired
Stefan Kangas [Mon, 25 Oct 2021 00:12:48 +0000 (02:12 +0200)]
Support new Thumbnail Managing Standard sizes in image-dired

* lisp/image-dired.el
(image-dired--thumbnail-managing-standard-sizes): New defconst.
(image-dired-thumbnail-storage)
(image-dired-thumb-name, image-dired-insert-thumbnail)
(image-dired-thumb-size, image-dired-create-thumb-1): Support larger
thumbnail sizes mandated by new version of the Thumbnail Managing
Standard (December 2020, Version 0.9.0).

3 years agoClarify two image-dired docstrings
Stefan Kangas [Mon, 25 Oct 2021 00:12:34 +0000 (02:12 +0200)]
Clarify two image-dired docstrings

* lisp/image-dired.el (image-dired-dir): Doc fix; clarify that
thumbnails will be saved in "$XDG_CACHE_HOME/thumbnails", as per the
Thumbnail Managing Standard.
(image-dired-thumb-size): Doc fix; clarify that this option will be
ignored when using the Thumbnail Managing Standard.

3 years agoFix flymake example backend conditions in the manual
Lars Ingebrigtsen [Sun, 24 Oct 2021 23:25:13 +0000 (01:25 +0200)]
Fix flymake example backend conditions in the manual

* doc/misc/flymake.texi (An annotated example backend): Also react
to `signal' process statuses (bug#51380).

3 years ago* etc/PROBLEMS: Mention problems with regexp matcher. (Bug#18577)
Stefan Kangas [Sun, 24 Oct 2021 21:56:46 +0000 (23:56 +0200)]
* etc/PROBLEMS: Mention problems with regexp matcher.  (Bug#18577)

3 years agoUse SHA1 when creating thumbnail file name
Stefan Kangas [Sun, 24 Oct 2021 21:25:07 +0000 (23:25 +0200)]
Use SHA1 when creating thumbnail file name

* lisp/image-dired.el (image-dired-thumb-name): Improve docstring.
Use SHA1 for hashing when creating file name.  SHA1 is slightly faster
than MD5, and has a few more bits.

3 years agoRemove debugging in with_delayed_message_display
Lars Ingebrigtsen [Sun, 24 Oct 2021 21:04:31 +0000 (23:04 +0200)]
Remove debugging in with_delayed_message_display

* src/eval.c (with_delayed_message_display): Remove debugging.

3 years agoDisplay a message if HMTL rendering takes a long time
Lars Ingebrigtsen [Sun, 24 Oct 2021 20:21:04 +0000 (22:21 +0200)]
Display a message if HMTL rendering takes a long time

* lisp/net/eww.el (eww-display-html): Display a message if HTML
rendering takes a long time (bug#19776).

3 years agoAdd new macro `with-delayed-message'
Lars Ingebrigtsen [Sun, 24 Oct 2021 20:20:19 +0000 (22:20 +0200)]
Add new macro `with-delayed-message'

* doc/lispref/display.texi (Progress): Document it.
* lisp/subr.el (with-delayed-message): New macro.

* src/eval.c (with_delayed_message_display)
(with_delayed_message_cancel): Helper functions.
(Ffuncall_with_delayed_message): New function (bug#19776).

3 years agoCC Mode: Fontify "found types" which are recognized after being first scanned
Alan Mackenzie [Sun, 24 Oct 2021 19:59:18 +0000 (19:59 +0000)]
CC Mode: Fontify "found types" which are recognized after being first scanned

This aims to fix the scenario where on jit-lock's first scan of a type, it is
not recognized as such, and only later does this happen.  The fontification of
such found types is now done by background scanning in short time slices
immediately after initialising the mode.

* lisp/progmodes/cc-engine.el (c-add-type-1): New function.
(c-add-type): Extract c-add-type-1 from it, and reformulate the mechanism for
protecting c-found-types from excessive partial identifiers.

* lisp/progmodes/cc-fonts.el (c-font-lock-complex-decl-prepare): Remove the
code which cleared c-found-types on fontification at BOB.
(c-find-types-background): New function, based on c-font-lock-declarations).
(c-type-finder-timer-func): New function.
(c-re-redisplay-timer): New variable.
(c-force-redisplay, c-fontify-new-found-type): New functions.

* lisp/progmodes/cc-mode.el (c-type-finder-timer, c-inhibit-type-finder): New
variables.
(c-leave-cc-mode-mode): Nullify c-post-command-hook, c-post-gc-hook, and
c-type-finder-timer when the last CC Mode buffer of a session is killed.
(c-type-finder-pos): New variable.
(c-basic-common-init): Initialize/Install c-post-command, c-c-type-finder-pos,
c-type-finder-timer, and c-post-gc-hook.
(c-new-id-start, c-new-id-end, c-new-id-is-type): New variables.
(c-update-new-id): New function.
(c-post-command): New post command hook function, used for checking moving
away from partially typed identifiers, and making them full identifiers.
(c-post-gc-hook): New hook to prevent CC Mode activity immediately following
GC, thus allowing keyboard/mouse input to be registered.
(c-before-change): Add code to clear c-found-types on a buffer change at BOB.
(c-after-change): Call c-update-new-id to keep track of partially typed
identifiers.

* doc/misc/cc-mode.texi (Found Types): New @section in the @Chapter Font
Locking.

* lisp/progmodes/cc-vars.el (c-type-finder-time-slot)
(c-type-finder-repeat-time, c-type-finder-chunk-size): New customizable
options.

3 years ago* test/lisp/repeat-tests.el: New file.
Juri Linkov [Sun, 24 Oct 2021 19:21:31 +0000 (22:21 +0300)]
* test/lisp/repeat-tests.el: New file.

3 years ago* lisp/tab-bar.el (tab-bar-move-repeat-map): Fix alias binding of tab-move.
Juri Linkov [Sun, 24 Oct 2021 19:20:15 +0000 (22:20 +0300)]
* lisp/tab-bar.el (tab-bar-move-repeat-map): Fix alias binding of tab-move.

(tab-bar-move-tab-backward): Put 'repeat-map' symbol property.

3 years agoFix mouse buttons in dired--make-directory-clickable
Lars Ingebrigtsen [Sun, 24 Oct 2021 19:21:25 +0000 (21:21 +0200)]
Fix mouse buttons in dired--make-directory-clickable

* lisp/dired.el (dired--make-directory-clickable): Adjust mouse
clicks to conform to our standards.

3 years agoUse restrictive umask when creating image-dired data
Stefan Kangas [Sun, 24 Oct 2021 19:20:16 +0000 (21:20 +0200)]
Use restrictive umask when creating image-dired data

* lisp/image-dired.el (image-dired-dir)
(image-dired-sane-db-file): Create thumbnail directory and
.image-dired_db with umask 077.  This avoids creating world readable
copies of private data, and is in fact mandated by the Thumbnail
Managing Standard that we aim to support.

3 years ago; lisp/transient.el: Revert some misguided stylistic fixes.
Jonas Bernoulli [Sun, 24 Oct 2021 13:35:05 +0000 (15:35 +0200)]
; lisp/transient.el: Revert some misguided stylistic fixes.

These aren't actual modes.  Set checkdoc-symbol-words to avoid
false-positives.  The first line of doc-strings of methods do
not need to end with period.

3 years agoDon't unhide first thread if entering without selecting article
Lars Ingebrigtsen [Sun, 24 Oct 2021 18:25:12 +0000 (20:25 +0200)]
Don't unhide first thread if entering without selecting article

* lisp/gnus/gnus-sum.el (gnus-summary-first-unread-subject)
(gnus-summary-first-unseen-subject)
(gnus-summary-first-unseen-or-unread-subject): Use it.
(gnus-summary--goto-and-possibly-unhide): New function -- don't
unhide the first thread unless necessary (bug#51344).

3 years agoImprove documentation of image-dired thumbnails
Stefan Kangas [Sun, 24 Oct 2021 16:36:09 +0000 (18:36 +0200)]
Improve documentation of image-dired thumbnails

* lisp/image-dired.el: Fix documentation on thumbnail file format to
correctly say that it can be either PNG or JPEG; not just JPEG.  Also
fix inconsistent formatting in comments.
* lisp/image-dired.el (image-dired-thumbnail-storage): Improve
docstring.

3 years agoAdd support for pngquant to image-dired
Stefan Kangas [Sun, 24 Oct 2021 16:28:20 +0000 (18:28 +0200)]
Add support for pngquant to image-dired

* lisp/image-dired.el (image-dired-cmd-pngnq-program)
(image-dired-cmd-pngnq-options): Add support for pngquant.
Prefer, in this order: pngquant, pngnq-s9, pngnq-s for reasons of
speed and how actively maintained the projects seem to be.

3 years agoFix compilation errors with MinGW64 GCC 11
Eli Zaretskii [Sun, 24 Oct 2021 17:45:56 +0000 (20:45 +0300)]
Fix compilation errors with MinGW64 GCC 11

* lib-src/ntlib.c (IS_DIRECTORY_SEP): Remove redundant macro.

* lib-src/ntlib.c (DEFER_MS_W32_H):
* nt/addpm.c (DEFER_MS_W32_H):
* nt/cmdproxy.c (DEFER_MS_W32_H):
* nt/ddeclient.c (DEFER_MS_W32_H):
* nt/preprep.c (DEFER_MS_W32_H):
* nt/runemacs.c (DEFER_MS_W32_H): Fix a typo.
* nt/Makefile.in (BASE_CFLAGS): Add -I switches to pick up
config.h and lib/attribute.h.

3 years agoInclude <config.h> first in MS-Windows source
Paul Eggert [Sun, 24 Oct 2021 03:35:18 +0000 (20:35 -0700)]
Include <config.h> first in MS-Windows source

3 years agoFix compilation errors with MinGW64 GCC 11
Eli Zaretskii [Sun, 24 Oct 2021 17:19:47 +0000 (20:19 +0300)]
Fix compilation errors with MinGW64 GCC 11

* lib-src/ntlib.c (_GL_ATTRIBUTE_MALLOC)
(_GL_ATTRIBUTE_DEALLOC_FREE): Define to avoid compilation errors
with MinGW64 GCC 11.  Suggested by Andy Moreton
<andrewjmoreton@gmail.com>.  Do not merge to master.

3 years agoFix define-erc-response-handler indentation
Lars Ingebrigtsen [Sun, 24 Oct 2021 16:54:27 +0000 (18:54 +0200)]
Fix define-erc-response-handler indentation

* lisp/erc/erc-backend.el (define-erc-response-handler): Add
proper indentation.

3 years ago; Unbreak creating thumbnails in image-dired
Stefan Kangas [Sun, 24 Oct 2021 16:18:43 +0000 (18:18 +0200)]
; Unbreak creating thumbnails in image-dired

* lisp/image-dired.el (image-dired-insert-thumbnail): Unbreak
creating thumbnails after my previous commit.

3 years ago; * etc/NEWS: Fix typos.
Michael Albinus [Sun, 24 Oct 2021 15:46:23 +0000 (17:46 +0200)]
; * etc/NEWS: Fix typos.

3 years agoAdd new option help-link-key-to-documentation
Stefan Kangas [Sun, 24 Oct 2021 14:47:22 +0000 (16:47 +0200)]
Add new option help-link-key-to-documentation

* lisp/help.el (help-link-key-to-documentation): New user option.
(substitute-command-keys): Add a link from keys to the command they
are bound to, if the above new option is non-nil.  (Bug#8951)
* etc/NEWS: Announce the new option.

3 years agoMake dired directory components clickable
William Xu [Sun, 24 Oct 2021 14:15:12 +0000 (16:15 +0200)]
Make dired directory components clickable

* lisp/dired.el (dired-readin): Use it.

* lisp/dired.el (dired-make-directory-clickable): New user option.

* lisp/dired.el (dired--make-directory-clickable): New function
(bug#21973).

3 years agoDon't use obsolete variable `find-tag-marker-ring`
Mattias Engdegård [Sun, 24 Oct 2021 10:15:31 +0000 (12:15 +0200)]
Don't use obsolete variable `find-tag-marker-ring`

* lisp/progmodes/js.el (js-find-symbol):
* lisp/progmodes/octave.el (octave-find-definition):
Call `xref-push-marker-stack` instead of manipulating the obsolete
variable `find-tag-marker-ring`.

3 years agoTweak bug-reference-tests
Lars Ingebrigtsen [Sun, 24 Oct 2021 13:18:33 +0000 (15:18 +0200)]
Tweak bug-reference-tests

* test/lisp/progmodes/bug-reference-tests.el: Tweak tests a bit.

3 years agoClean up duplicated setting in scheme-mode-variables
Lars Ingebrigtsen [Sun, 24 Oct 2021 13:07:32 +0000 (15:07 +0200)]
Clean up duplicated setting in scheme-mode-variables

* lisp/progmodes/scheme.el (scheme-mode-variables): Remove
repeated setting.

3 years agoAllow matching non-.git URLs in bug-reference
Lars Ingebrigtsen [Sun, 24 Oct 2021 12:14:42 +0000 (14:14 +0200)]
Allow matching non-.git URLs in bug-reference

* lisp/progmodes/bug-reference.el
(bug-reference--build-forge-setup-entry): Allow matching non-.git
URLs, with and without slashes (bug#51316).

3 years agoDoc fix for concat
Ihor Radchenko [Thu, 24 Jun 2021 14:33:08 +0000 (22:33 +0800)]
Doc fix for concat

* src/fns.c (Fconcat): Note that composition values may not remain eq
in return value of concat.  (Bug#48740)

3 years agoDon't hard-code image-dired thumbnail type
Stefan Kangas [Sun, 24 Oct 2021 10:26:39 +0000 (12:26 +0200)]
Don't hard-code image-dired thumbnail type

* lisp/image-dired.el (image-dired-insert-thumbnail): Detect thumbnail
image type instead of hard-coding it.

3 years ago* lisp/image-dired.el (image-dired-external-viewer): Support feh.
Stefan Kangas [Sun, 24 Oct 2021 10:20:35 +0000 (12:20 +0200)]
* lisp/image-dired.el (image-dired-external-viewer): Support feh.

3 years agoExpand tests for image-type-from-file-header
Stefan Kangas [Sun, 24 Oct 2021 10:07:48 +0000 (12:07 +0200)]
Expand tests for image-type-from-file-header

* test/lisp/image-tests.el (image-tests--files): New defconst.
(image-tests--type-from-file-header): New defun.
(image-type-from-file-header-test/jpeg)
(image-type-from-file-header-test/pbm)
(image-type-from-file-header-test/png)
(image-type-from-file-header-test/svg)
(image-type-from-file-header-test/tiff)
(image-type-from-file-header-test/webp)
(image-type-from-file-header-test/xbm)
(image-type-from-file-header-test/xpm): New tests.
(image-type-from-file-header-test): Delete test.

3 years agoAdd tests for gif to src/image-tests.el
Stefan Kangas [Sun, 24 Oct 2021 10:05:37 +0000 (12:05 +0200)]
Add tests for gif to src/image-tests.el

* test/src/image-tests.el (image-tests--images): Rename from
image-tests-files.  Add gif.
(image-tests-image-size/gif)
(image-tests-image-mask-p/gif)
(image-tests-image-metadata/gif): New tests.
* test/data/image/black.gif: New file.

3 years agoMerge from origin/emacs-28
Glenn Morris [Sun, 24 Oct 2021 08:55:45 +0000 (01:55 -0700)]
Merge from origin/emacs-28

c7f53824a8 (origin/emacs-28) Update publicsuffix.txt from upstream
9a50f760e9 ; * doc/lispref/modes.texi (Hooks): Clarify wording.  (Bug...
e154fd9119 Refer to the info node on keymaps in map-keymap docstring
4fd5c8df67 Clarify abnormal hook documentation
6fa5206770 Update to Org 9.5-59-g52e6f1
39413a45bf ; * doc/lispref/functions.texi (Calling Functions): Fix la...
43914ab01f Improve documentation of cl-reduce
ef37a86cac Improve documentation of apply-partially
1e8be48738 Fix typos
8c5fbd712b Revert commit 225ca617b7, and apply another fix
cdbd03345d Fix documentation of posn-at-x-y
598732c899 ; * src/vm-limit.c (get_lim_data): Fix a typo.  (Bug#18238)
efdffd86c5 ; * etc/refcards/README: Prefer HTTPS in link.

# Conflicts:
# etc/NEWS

3 years agoUpdate publicsuffix.txt from upstream
Stefan Kangas [Sun, 24 Oct 2021 08:37:57 +0000 (10:37 +0200)]
Update publicsuffix.txt from upstream

* etc/publicsuffix.txt: Update from
https://publicsuffix.org/list/public_suffix_list.dat
dated 2021-10-16 16:33:47 GMT.

3 years ago; * doc/lispref/modes.texi (Hooks): Clarify wording. (Bug#34588)
Eli Zaretskii [Sun, 24 Oct 2021 06:44:18 +0000 (09:44 +0300)]
; * doc/lispref/modes.texi (Hooks): Clarify wording.  (Bug#34588)

3 years agoMake dired-x-guess-file-name-at-point obsolete
Stefan Kangas [Sun, 24 Oct 2021 06:34:52 +0000 (08:34 +0200)]
Make dired-x-guess-file-name-at-point obsolete

* lisp/dired-x.el (dired-x-guess-file-name-at-point): Make
obsolete in favour of 'thing-at-point'.
(dired-x-read-filename-at-point): Use 'thing-at-point' instead of
above obsolete function.