* lisp/dired-aux.el (dired-dwim-target-next): Add arg ALL-FRAMES.
(dired-dwim-target-next-visible): New function.
* doc/emacs/dired.texi (Operating on Files): Describe function value
of dired-dwim-target. (Bug#35385)
* lisp/files.el (move-file-to-trash): Fix file name in
trash-can when another deleted file under the same name is
already stored there. (Bug#37922)
Copyright-paperwork-exempt: yes.
* lisp/gnus/gnus-icalendar.el (gnus-icalendar-insert-button):
* lisp/gnus/gnus-art.el (gnus-insert-mime-button)
(gnus-mime-display-alternative, gnus-insert-prev-page-button)
(gnus-insert-next-page-button)
(gnus-insert-mime-security-button): Make button-1 work on all the
Gnus buttons (bug#38144).
When using this option and editing input, some transient situations
may arise that lead to file-name shadowing, but that shouldn't
necessarily lead to auto-delete behaviour, which will be suprising.
In '/foo/x/bar', if the user deletes the 'x', shadowing occurs, but
probably shouldn't. So, somewhat like ido-mode, only auto-tidy
shadowed file names if the user is inserting text at end of input.
* lisp/icomplete.el (icomplete-exhibit): Check this-command.
(icomplete-tidy-shadowed-file-names): Tweak docstring.
This avoids running doc-view-mode on files that are actually text
files.
* lisp/files.el (auto-mode-alist): Don't use doc-view-mode-maybe
for .doc (but continue to do so for .docx).
(magic-fallback-mode-alist): Add signature for .doc files.
* lisp/dframe.el (dframe-frame-mode): Use 'set-window-buffer'
instead of 'switch-to-buffer’ to avoid that
'switch-to-buffer-obey-display-actions' butts in (Bug#37840).
Also prefer setf over oset.
(semanticdb-abstract-table-list): Always define.
(semanticdb--inhibit-make-directory): Fix name of declaration to match
name of variable actually used.
(semanticdb-with-match-any-mode): Use `declare`. Add Edebug spec.
(semanticdb-project-roots): Remove redundant :group.
* lisp/reposition.el (repos-count-screen-lines): Narrow without
changing point-min. It wasn't necessary for vertical-motion to
work, and it had some adverse effects on how font-lock rules were
applied
(https://lists.gnu.org/archive/html/emacs-devel/2019-11/msg00522.html).
This can also be an alternative fix for bug#38049.
This (along with a suggestion to the OP to set
open-paren-in-column-0-is-defun-start to nil) fixes bug #37910. It may also
have fixed bug #5490 and bug #18072.
* lisp/progmodes/cc-engine.el (c-state-cache-non-literal-place): Remove thi
non-sensical function, replacing it with ....
(c-state-cache-lower-good-pos): New function.
(c-renarrow-state-cache, c-append-lower-brace-pair-to-state-cache)
(c-remove-stale-state-cache, c-remove-stale-state-cache-backwards): Instead of
altering the state-cache list structure with setcar and setcdr, use setq and
consing.
(c-parse-state-1): Call c-state-cache-lower-good-pos rather than
c-state-cache-non-literal-place.
* so-long.el (so-long-version, so-long--latest-version): New variables.
This enables users to safely load version 1.0 of so-long.el on top of
an earlier version, as well as making provisions for doing likewise
following any incompatible changes arising in future versions.
* so-long.el (so-long-inhibit-whitespace-mode)
(so-long-make-buffer-read-only, so-long-revert-buffer-read-only)
(so-long-inhibit-global-hl-line-mode): Restore dummy definitions of
now-obsolete hook functions used by earlier versions of so-long.el,
to support users who have saved these symbols in their customized
values for the hooks in question.
* lisp/so-long.el (so-long-invisible-buffer-function): New user option.
(so-long--set-auto-mode): Use so-long-invisible-buffer-function.
(so-long-deferred): New function/value for so-long-invisible-buffer-function.
(so-long, so-long--disable): Support for so-long-deferred.
* test/lisp/so-long-tests/autoload-longlines-mode-tests.el
* test/lisp/so-long-tests/autoload-major-mode-tests.el
* test/lisp/so-long-tests/autoload-minor-mode-tests.el
* test/lisp/so-long-tests/so-long-tests.el:
Support for so-long-deferred.
Pre-existing tests have been updated to ensure the buffer is already
displayed in cases where a call to `normal-mode' is the (potential)
trigger for `so-long'.
* lisp/so-long.el: Documentation fixes. For the purposes of
consistency, this reverts some of the changes made in commit
41ba8231ef, including one which
had introduced inconsistent spelling.
ispell configuration and LocalWords have been added such that
`ispell-buffer' should find no misspellings for this library.
* test/lisp/so-long-tests/spelling-tests.el (so-long-spelling):
New test to check the spelling using `ispell-buffer'.
* lisp/mail/rfc2047.el
(rfc2047-quote-special-characters-in-quoted-strings): Remove function.
(rfc2047-encode-message-header, rfc2047-encode-region): Don't use it.
* lisp/vc/vc.el (vc-default-update-on-retrieve-tag): New function.
(vc-retrieve-tag): Call `update-on-retrieve-tag' backend function
to determine if prompt for update buffers is needed; Include tag
name into the "Retrieving tag" message.
* lisp/vc/vc-git.el (vc-git-update-on-retrieve-tag):
* lisp/vc/vc-hg.el (vc-hg-update-on-retrieve-tag):
* lisp/vc/vc-svn.el (vc-svn-udate-on-retrieve-tag): New functions.
Buffers update prompt on `vc-retrieve-tag' is omitted (bug#38156).
* lisp/emacs-lisp/edebug.el (edebug-remove-instrumentation):
Prompt the user for what functions to remove instrumentation from
a la cancel-edebug-on-entry (bug#38195).
* time-stamp.el (time-stamp-string-preprocess): Change new format for
numeric time zone from %:z to %5z to match format-time-string better.
(time-stamp-format): Document support for numeric time zone.
See discussion in bug#32931.
* NEWS: Mention time-stamp-format %5z.
Otherwise we would lose things like C-r (isearch-backward) when doing
simple stuff like non-icomplete pp-eval-expression.
* lisp/icomplete.el (icomplete--fido-mode-setup): Restrict setup
to when icomplete-mode really kicks in.
(tab-line-tabs-buffer-list): New function.
(tab-line-tabs-mode-buffers, tab-line-tabs-buffer-groups):
Call tab-line-tabs-mode-buffers.
(tab-line-tabs-buffer-groups): Add 'close' function that uses
kill-buffer instead of bury-buffer that makes no sense here.
(tab-line-format): Don't show the close button when a tab
has no 'close' function or buffer.
(tab-line-switch-to-prev-tab, tab-line-switch-to-next-tab):
Support tabs with 'buffer' properties.
(tab-line-close-tab): Call 'close' function when defined.
* lisp/dired.el (dired-dwim-target): Add choices
dired-dwim-target-next and dired-dwim-target-recent.
* lisp/dired-aux.el (dired-dwim-target-next)
(dired-dwim-target-recent): New functions.
(dired-dwim-target-directories): Call either of them.
* doc/emacs/dired.texi (Operating on Files): Mention new
preferences in dired-dwim-target.
* lisp/international/titdic-cnv.el (tit-process-header):
In generated doc strings, escape \, ", ', and ` properly.
Currently only ' appears but we might as well future-proof this.
* lisp/progmodes/verilog-mode.el (verilog-read-decls): Fix to skip
over base64-encoded protected data while reading AUTO declarations.
Reported by Berend Ozceri.
(verilog-auto-inst-port, verilog-auto-inst-vector): Support 'unsigned'
in `verilog-auto-inst-vector'. Reported by Jeff Riley.
(verilog-read-decls): Fix to ignore `line in AUTOINST, git
bug18. Reported by Berend Ozceri.
(verilog-library-extensions): Support .va /.vah/.sva/.svah file
extensions to load verilog-mode for Verilog-AMS. Reported by Shareef
Jalloq.
(verilog-read-sub-decls-expr): Fix AUTOOUTPUT etc misparsing Verilog
casts, bug1526. Reported by Udi Finkelstein.
* doc/lispref/numbers.texi (Float Basics):
* doc/misc/cl.texi (Implementation Parameters):
* lisp/emacs-lisp/cl-lib.el (cl-most-positive-float)
(cl-least-positive-float)
(cl-least-positive-normalized-float, cl-float-epsilon)
(cl-float-negative-epsilon):
Document IEEE floating point better. Don’t suggest that Emacs
might use some floating-point format other than IEEE format, as
Emacs currently assumes IEEE in several places and there seems
little point in removing those assumptions.
* lisp/autorevert.el (auto-revert-handler): Use 'minibuffer-message'
instead of 'message'. Call it from the original window's buffer
that in case of the minibuffer should be current, so
minibuffer-message could add a message to it. (Bug#34614)
* lisp/emacs-lisp/ert-x.el (ert--make-message-advice): Add nil to
the list of values to not use for format-message, because
minibuffer-message calls 'message' with nil argument, and tests fail.
* lisp/man.el (Man-bgproc-sentinel): Postpone displaying the message
and deleting the buffer until exiting the code block with
with-current-buffer. Use minibuffer-message to display message
to handle possibly active minibuffer.
* lisp/subr.el (do-after-load-evaluation): Use minibuffer-message
to not obscure a possibly active minibuffer.
* lisp/minibuffer.el (minibuffer-message):
Record message in the *Messages* buffer.
* lisp/files.el (hack-local-variables-confirm):
Use read-char-from-minibuffer instead of read-char-choice.
Remove special handling of original window scrolling
that is now supported in the minibuffer. This fixes
https://lists.gnu.org/archive/html/emacs-devel/2019-10/msg01020.html
(files--ask-user-about-large-file): Use read-char-from-minibuffer
instead of read-char-choice.
* lisp/simple.el (read-char-history):
Rename from read-char-from-minibuffer-history. (Bug#38076)
(read-char-from-minibuffer-insert-char):
Rename from read-char-from-minibuffer-self-insert.
(read-char-from-minibuffer-map-hash): New defconst.
(read-char-from-minibuffer-insert-other): New command.
(read-char-from-minibuffer): Add optional args CHARS and HISTORY.
(zap-to-char): Use 'read-char-history as HISTORY arg of
read-char-from-minibuffer.
* lisp/emacs-lisp/map-ynp.el (read-answer): Use sit-for instead of sleep-for.
Replace short answer history yes-or-no-p-history with read-char-history.
* doc/lispref/minibuf.texi (Yes-or-No Queries): Update the fact
that y-or-n-p uses the minibuffer.
* lisp/subr.el (y-or-n-p-history-variable): New variable.
(y-or-n-p-map): New keymap.
(y-or-n-p-insert-y, y-or-n-p-insert-n, y-or-n-p-insert-other):
New commands.
(y-or-n-p): Rewrite to use read-from-minibuffer and make-composed-keymap
with y-or-n-p-map and query-replace-map.
* lisp/minibuffer.el (with-minibuffer-selected-window): New macro.
(minibuffer-recenter-top-bottom, minibuffer-scroll-up-command)
(minibuffer-scroll-down-command, minibuffer-scroll-other-window):
(minibuffer-scroll-other-window-down): New commands.
(minibuffer-local-map): Remap recenter/scroll symbols to their
minibuffer wrappers: recenter-top-bottom to minibuffer-recenter-top-bottom.
* src/window.c (Fother_window_for_scrolling): Use 'lambda' value for
MINIBUF arg of Fnext_window, so minibuffer-scroll-other-window and
minibuffer-scroll-other-window-down doesn't try to scroll the
minibuffer window.
* lisp/international/mule-cmds.el (select-safe-coding-system):
Treat no-conversion-multibyte that came from find-auto-coding
the same as no-conversion for the purposes of encoding. The
same logic that considers no-conversion always safe should do
the same with no-conversion-multibyte. (Bug#38155)
* lisp/icomplete.el (icomplete-fido-kill)
(icomplete-fido-delete-char, icomplete-fido-ret)
(icomplete-fido-backward-updir): Rename from icomplete-magic-ido-*
versions.
(icomplete-fido-mode-map): Use new command names.
* lisp/progmodes/cc-mode (c-font-lock-fontify-region): Widen in this function,
to ensure that the CC Mode font locking mechanism can examine characters
outside the given region.
This fixes bug #4192.
* etc/NEWS: Add a new entry.
* lisp/progmodes/cc-defs.el (c-font-lock-flush): New macro.
* lisp/progmodes/cc-cmds.el (c-toggle-comment-style): On toggling the comment
style, invoke c-font-lock-flush when c-mark-wrong-style-of-comment is non-nil,
to cause that marking to be done instead on the other style of comment.
* lisp/progmodes/cc-fonts.el (c-maybe-font-lock-wrong-style-comments): New
function.
(c-cpp-matchers): Call c-maybe-font-lock-wrong-style-comments when
appropriate.
* lisp/progmodes/cc-vars.el (c-mark-wrong-style-of-comment): New customizable
option.
* doc/misc/cc-mode.texi (top level, Indentation Commands, Guessing the Style,
Custom Macros): For some opening quote marks, correct '' to ``.
(Minor Modes): Add an xref to the new page "Wrong Comment Style" in a
footnote.
(Wrong Comment Style): New page.
* lisp/simple.el (goto-history-element)
(next-history-element): Fix quoting of "future history".
* doc/lispref/minibuf.texi (Minibuffer Commands)
(Text from Minibuffer): Add index entry and cross-reference
for "future history". (Bug#38026)
Since we use `url-handler-mode` to deal with URLs, `read-file-name`
works just as well, with the added benefit that it interacts correctly
with packages that rebind `read-file-name-function`, such as Helm.
(ffap-read-url-internal, ffap-read-file-or-url-internal): Remove, unused.
* lisp/icomplete.el (icomplete-completions): Don't use ellipsis when
truncating determ in fido-mode. Highlight the center part of
determ with icomplete-first-match.
This is the way the basic completion styles work. This fixes
candidate highlighting in icomplete.
* lisp/minibuffer.el (completion-pcm--hilit-commonality): Apply
faces to 'face property, not font-lock-face.
This reverts commit 49fc040077.
It turns out that the fix for a minor aesthetical annoyance
caused much more serious bugs: bug#31038, bug#35726, Bug#37097,
Allow not to kill buffers when pdbtracking session is finished.
Pdbtracking session considered finished judging from the user input.
* lisp/progmodes/python.el (python-pdbtrack-kill-buffers): New
customizable variable.
(python-pdbtrack-set-tracked-buffer): Use it.
(python-pdbtrack-unset-tracked-buffer)
(python-pdbtrack-tracking-finish): New functions.
(python-pdbtrack-continue-command, python-pdbtrack-exit-command):
New customizable variables.
(python-pdbtrack-process-sentinel): New function. Finish
pdbtracking session when process is killed.
(python-pdbtrack-prev-command-continue): New variable.
(python-pdbtrack-comint-input-filter-function): New function.
Finish pdbtracking session based on commands sent to pdb.
(python-pdbtrack-comint-output-filter-function): Unset/set
tracking buffer if looking at pdb prompt; finish pdbtracking
session if filename of current stack frame starts with
"<" e.g. "<stdin>".
(python-pdbtrack-comint-output-filter-function): Don't override
overlay-arrow-string.
(python-pdbtrack-setup-tracking): New function.
(inferior-python-mode): Use it.
(python-pdbtrack-stacktrace-info-regexp): Default value is changed.
Must also match lines with filename like "<stdin>" and "<string>".
* etc/NEWS: Mention python-pdbtrack-kill-buffers
* lisp/net/ange-ftp.el (ange-ftp-repaint-minibuffer): Use empty message.
(ange-ftp-quote-string): Unquote the string.
(ange-ftp-substitute-in-file-name, ange-ftp-access-file)
(ange-ftp-copy-directory, ange-ftp-make-symbolic-link)
(ange-ftp-add-name-to-file): New defuns. Set 'ange-ftp property.
(ange-ftp-real-substitute-in-file-name)
(ange-ftp-real-copy-directory): New defuns.
(ange-ftp-file-name-as-directory): Care about `non-essential'.
(ange-ftp-file-attributes): Handle ID-STRING.
(ange-ftp-copy-file-internal, ange-ftp-rename-file)
(ange-ftp-make-directory): Improve error handling.
(ange-ftp-insert-directory): Initialize SWITCHES if they are nil.
* test/lisp/net/tramp-tests.el (ange-ftp-make-backup-files): Declare.
(tramp-test39-make-nearby-temp-file, tramp--test-ange-ftp-p): New defun.
(tramp-test05-expand-file-name-relative)
(tramp-test06-directory-file-name, tramp-test10-write-region)
(tramp-test11-copy-file, tramp-test12-rename-file)
(tramp-test17-insert-directory)
(tramp-test26-file-name-completion)
(tramp-test37-make-auto-save-file-name)
(tramp-test38-find-backup-file-name)
(tramp--test-special-characters): Use it.
* lisp/emacs-lisp/package.el (package--ensure-package-menu-mode):
Extract function to warn about incorrect major mode...
(package-menu-toggle-hiding, package-menu-refresh)
(package-menu-execute): ...from here.
(package-menu--mark-upgrades-1): And here, but move call...
(package-menu-mark-upgrades): ...here instead.
(package-menu-hide-package, package-menu-mark-delete)
(package-menu-mark-install, package-menu-mark-unmark)
(package-menu-quick-help, package-menu-get-status)
(package-menu-filter-by-keyword, package-menu-filter-by-name)
(package-menu-clear-filter): Add call to new function. (Bug#37891)
(dired-rename-file): Call vc-rename-file when dired-vc-rename-file is non-nil.
* lisp/vc/vc.el (vc-rename-file): Allow renaming added files.
Call vc-file-clearprops on new file too for the case when
old and new files were renamed to each other back and forth.
https://lists.gnu.org/archive/html/emacs-devel/2019-11/msg00069.html
* lisp/tab-line.el (tab-line-tabs-buffer-group-function)
(tab-line-tabs-buffer-group-sort-function)
(tab-line-tabs-buffer-groups-sort-function): New defvars.
(tab-line-tabs-buffer-group-name): Rename from
tab-line-tabs-buffer-groups--name and use tab-line-tabs-buffer-group-function.
(tab-line-tabs-buffer-groups): Use tab-line-tabs-buffer-groups-sort-function
and tab-line-tabs-buffer-group-sort-function.
(tab-line-new-tab): Let bind tab-line-tabs-buffer-groups to
mouse-buffer-menu-mode-groups.
This will allow js.el to work after maintenance changes in CC Mode, e.g. the
fix to bug #11165.
* lisp/progmodes/js.el (top level): Create a CC Mode derived language called
js-mode and based on Java Mode.
(js-mode): call c-init-language-vars for js-mode. Remove the direct settings
of several CC Mode language variables which are now defined through the
derived language mechanism. Call c-set-style and set up the needed style
variables c-block-comment-prefix and c-comment-prefix-regexp.
* time-stamp.el: Implement %:z as expanding to the numeric time zone
offset, to address the feature request of bug#32931. Do not document it
yet, to discourage compatibility problems in mixed Emacs 26 and Emacs 27
environments. Documentation will be added in a subsequent release at
least two years later. (We cannot yet use %z for numeric time zone
because in Emacs 26 it was documented to do something else.)
* time-stamp-tests.el (time-stamp-test-format-time-zone): expand this
test and break it into two tests, time-stamp-test-format-time-zone-name
and time-stamp-test-format-time-zone-offset.
* lisp/emacs-lisp/package.el (package-menu--refresh-archives): Rename
from duplicated name package-menu--refresh. (Bug#38084)
(package-menu-mode, list-packages): Use new name.
* lisp/emacs-lisp/package.el (package--activated): New variable to
avoid changing value of defcustom 'package-enable-at-startup'.
(package-initialize): Don't set 'package-enable-at-startup'.
(package-initialize, package-activate-all): Set 'package--activated'
instead of 'package-enable-at-startup'.
(package--initialized): Add doc string.
* lisp/startup.el (command-line): Check if 'package--activated' is
non-nil before activating packages.
* doc/lispref/package.texi (Packaging Basics): Update docs.
* lisp/emacs-lisp/package.el (package-menu--refresh): Rename from
'package-menu-refresh', make internal and non-interactive.
(package-menu-mode-map, package-menu-mode-menu, package-menu-mode)
(list-packages): Use the above. (Bug#35504)
(package-menu-refresh): Redefine as obsolete fuction alias for
'revert-buffer'.
* doc/emacs/package.texi (Package Menu): Document it.
* etc/NEWS: Announce it.
Suggested by Drew Adams.
* lisp/frame.el
(next-multiframe-window): Define as obsolete alias for...
(next-window-any-frame): ...new function name.
(previous-multiframe-window): Define as obsolete alias for...
(previous-window-any-frame): ...new function name. (Bug#12436)
* lisp/term/ns-win.el (global-map): Use new command name.
* doc/emacs/windows.texi (Other Window): Document it.
* etc/NEWS: Announce it.
Also don't send :error field on non-errors.
* lisp/jsonrpc.el (jsonrpc--reply): Don't send :result and :error
if none supplied.
(Version): Bump to 1.0.8
* lisp/tab-line.el (tab-line-tabs-function): Add option
tab-line-tabs-buffer-groups.
(tab-line-tabs-buffer-groups): New defvar defaulted to
mouse-buffer-menu-mode-groups.
(tab-line-tabs-buffer-groups--name, tab-line-tabs-buffer-groups):
New functions.
(tab-line-format): Support tabs in the format '(tab (name . "name") ...)'.
(tab-line-select-tab): Move part of code to tab-line-select-tab-buffer.
(tab-line-select-tab-buffer): New function.
(tab-line-tab-current): Rename from tab-line-tab-selected.
* lisp/net/network-stream.el
(network-stream-use-client-certificates): New user option.
(open-network-stream): If 'network-stream-use-client-certificates'
is t, and the user hasn't specified :client-certificate, do
certificate lookups via 'auth-source'.
(network-stream-certificate): Only return key and certificate
files that exist.
* doc/lispref/processes.texi (Network): Document new
client-certificate behavior.
* etc/NEWS: Document 'network-stream-use-client-certificates'.
(files.el subr.el): Fix some grammar errors in doc strings and comments.
(frame.c fringe.c image.c xfns.c xterm.c): Fix some English grammar
errors in doc strings.
* lisp/tab-bar.el (tab-bar-history-limit): Increase to 10 since wc
is not saved to the desktop file anymore, so doesn't affect its size.
(tab-bar-history--pre-change, tab-bar--history-change):
Store wc before possibly entering the minibuffer.
* lisp/tab-bar.el (frameset-filter-tabs): New function
added to 'frameset-filter-alist' for frame parameter 'tabs'.
(tab-bar--tab): Remove ws-bl/ws-bbl that are not needed because
frameset doesn't save frame buffer-list to desktop anyway.
(tab-bar-select-tab): Remove ws-bl/ws-bbl related code.
* lisp/emacs-lisp/seq.el (seq-reduce): Add autoload cookie.
* lisp/cus-edit.el (custom-group--draw-horizontal-line): New
function to draw horizontal lines which handles a non-nil value of
'truncate-lines'. (Bug#25308)
(custom-group-value-create): Use it.
Co-authored-by: Jonas Bernoulli <jonas@bernoul.li>
* lisp/international/mule-diag.el (describe-font): This function
can be used on unloaded fonts, so remove that restriction from the
doc string (bug#16815). Also allow completion over all fonts on
the system.
* src/font.c (Ffont_info): Ditto for the doc string.
Eglot, a third-party package which uses Flymake, has its own
diagnostic types such as 'eglot-error', 'eglot-warning', etc... While
not being too long, they will not fit in the type column of the "list
all diagnostics" buffer. This commit allows diagnostic types to have
user-defined names and also assigns names to the default categories.
* doc/misc/flymake.texi (Flymake error types): Describe
flymake-type-name prop.
* lisp/progmodes/flymake.el (flymake--diagnostics-buffer-entries):
Use type names.
(flymake-error, flymake-warning, flymake-note): Give these
diagnostic categories default type names.
This fixes bug #10149.
* lisp/progmodes/cc-fonts.el (c-font-lock-single-decl) Limit the search by
c-go-up-list-backwards to 500 non-literal characters.
* lisp/faces.el (set-face-font):
* doc/emacs/frames.texi (Fonts):
* doc/lispref/display.texi (Face Attributes)
(Attribute Functions): Clarify and correct the documentation
of set-face-font and related descriptions of font
specifications. (Bug#14647)
* lisp/icomplete.el (rfn-eshadow): Require it.
(icomplete-tidy-shadowed-file-names): New variable.
(icomplete-exhibit): Use icomplete-tidy-shadowed-file-names.
If there is no minibuffer input, but the user has already cycled some
pre-calculated completions, we should be calling
minibuffer-force-complete-and-exit instead of
minibuffer-complete-and-exit. The former is guaranteed to be fast in
this situation and yields the desired "selected" completion, while the
latter will just give us the default, ignoring all the cycling of
icomplete-{forward|backward}-completions.
* lisp/icomplete.el (icomplete-force-complete-and-exit): Add
comments and fix for empty input but some completions calculated.
* lisp/emacs-lisp/package.el (package-buffer-info): Don't signal an
error when the "footer line" is missing. Warn only. (Bug#26490)
* etc/NEWS: Announce it.
* lisp/progmodes/compile.el: Make ant regexp accept filenames that may
occur on Cygwin (like c:/test) and optional additional severity level
after task name.
* etc/compilation.txt: Add sample.
* lisp/cedet/semantic/texi.el (semantic-analyze-possible-completions),
lisp/cedet/srecode/srt-mode.el (semantic-analyze-possible-completions),
lisp/cedet/semantic/bovine/make.el (semantic-analyze-possible-completions):
Add `flags` arg.
* lisp/cedet/semantic/grammar.el (semantic-analyze-possible-completions):
Add `flags` arg. Reverse the found prefix.
(semantic-ctxt-current-class-list): Include token tags as things to
appear in non-lisp context.
'mouse-drag-region' leaves the region active around the dragged text,
so a straight undo did not revert the entire operation. To remedy
this, inhibit undo-in-region when the last command was
mouse-drag-region. (Method suggested by Stefan Monnier.)
* lisp/mouse.el (undo-drag-region): Set the undo-inhibit-region property.
* lisp/simple.el (undo): Inhibit undo-in-region if the last command
had the undo-inhibit-region property set.
* doc/lispref/symbols.texi (Standard Properties):
* doc/lispref/text.texi (Undo): Document undo-inhibit-region.
* etc/NEWS: Announce the property.
* lisp/font-lock.el (font-lock-set-defaults): Ensure that the font
lock variables are buffer-local even when nil, so that they're
copied correctly by mhtml mode when changing sub-modes (bug#33937).
* lisp/progmodes/sh-script.el (sh-syntax-propertize-function):
Tweak previous \ #foo change to work on all quoted characters, but
check that the backslash itself is not backslashed. Regexp from
Stefan Monnier.
* lisp/net/tramp-gvfs.el (tramp-gvfs-maybe-open-connection):
Check, that `tramp-password-save-function' is a function.
* lisp/net/tramp-smb.el (tramp-smb-handle-file-system-info):
Check, that there is a share.
* lisp/net/tramp.el (outline-regexp): Declare.
(tramp-get-debug-buffer): Let-bind `signal-hook-function'.
* test/lisp/net/tramp-tests.el (tramp-test04-substitute-in-file-name):
Skip some tests for Emacs 24 and 25; they let Emacs crash.
This adds create/snapshot bindings to the stash button even when there
are no stashes, and extends the stash menu bindings.
* etc/NEWS: Announce the bindings.
* lisp/vc/vc-git.el (vc-git-stash-shared-map): New keymap. Holds
shared bindings between stash button and stash list.
(vc-git-stash-map): Inherit from vc-git-stash-shared-map.
(vc-git-stash-button-map): New keymap. Holds button bindings,
inherit from vc-git-stash-shared-map.
(vc-git-stash-shared-help, vc-git-stash-list-help): New
defconsts. Abstract out list/button help texts.
(vc-git--make-button-text): Set keymap property to
vc-git-stash-button-map.
(vc-git-make-stash-button): Use vc-git-stash-shared-help.
(vc-git-stash-menu-map): Add items for vc-git-stash and
vc-git-stash-snapshot.
(vc-git-dir-extra-headers): Use vc-git-stash-list-help and
vc-git-stash-shared-help. Add vc-git-stash and
vc-git-stash-snapshot bindings to text shown when there are no stashes.
* lisp/dired.el (dired-font-lock-keywords): Font-lock symlinks
differently based on whether they point at a directory or not
(bug#17064). Based on code from Michael Heerdegen.
* lisp/textmodes/tex-mode.el (tex-font-lock-keywords-1):
\url{http://foo.org/bar%zot} shouldn't be fontified as having a
comment, so make the tex-verbatim face overwrite the
already-applied syntactical comment bits (bug#37134).
* lisp/vc/vc-git.el (vc-git-stash-map): Give `vc-git-stash' a
keystroke, because it's a useful command.
When there are no stashes, there's no way to use that keystroke (since
it's only bound on the stash lines), so perhaps that should also be
fixed somehow.
* lisp/progmodes/m4-mode.el (m4-font-lock-keywords): "dnl"
comments should override any previous syntax-based highlighting
(37132). This makes "dnl foo#bar" be highlighted correctly.
* lisp/emacs-lisp/syntax.el (syntax-ppss): Move the description of
the return value from...
* src/syntax.c (Fparse_partial_sexp): ... here because
`syntax-ppss' is what's called over the place, and jumping through
an indirection to get to the value description is inconvenient.
* lisp/simple.el (read-char-from-minibuffer-history):
Rename from read-char-with-history--history.
(read-char-from-minibuffer-map):
Rename from read-char-with-history--map.
(read-char-from-minibuffer): Rename from read-char-with-history.
(read-char-from-minibuffer-self-insert): New command.
(zap-to-char): Use read-char-from-minibuffer.
* lisp/simple.el (read-char-with-history): Reimplement based on
read-from-minibuffer.
* lisp/simple.el (read-char-with-history--map): New variable
(bug#10477).
* lisp/tab-bar.el (tab-bar--tab): Store additionally point-marker,
frame parameters buffer-list and buried-buffer-list, both for wc and ws.
Use seq-filter.
(tab-bar-select-tab): Restore point-marker after restoring
window-configuration. Also restore frame parameters buffer-list
and buried-buffer-list both for window-configuration and window-state.
(tab-bar-history-limit, tab-bar-history--minibuffer-depth): New variables.
(tab-bar-history-current): Rename from tab-bar-history--pre-change.
(tab-bar-history--pre-change): Set tab-bar-history-current.
(tab-bar--history-change): Use seq-take for tab-bar-history-limit.
(tab-bar-history-back, tab-bar-history-forward): Restore point-marker.
(tab-bar-list-noselect): Use seq-remove.
* lisp/emacs-lisp/seq.el (seq-take, seq-filter): Add autoload cookie.
* doc/lispref/errors.texi (Standard Errors): Mention the new error.
* lisp/files.el (auto-mode-alist): Add a bunch of image suffixes
to the list (bug#37972) based on the output from "gm convert -list
format" (i.e., graphicsmagick).
* lisp/image-mode.el (image-mode): Rewrite to possibly notify the
user about image-use-external-converter.
(image-mode--setup-mode): Factor out into own function and don't
run under `condition-case' as there's nothing here that should
error.
* lisp/image.el (unknown-image-type): New error.
(image-type): Signal that error so that image-mode can offer
sensible feedback to the user.
(completion-metadata): Always return a fresh new cons cell.
(completion--nth-completion): Don't bother calling adjust-metadata
if the result won't be used.
(completion-pcm--hilit-commonality): Revert recent change which had
removed support for `completions-first-difference` in `substring` and
`partial-completion` styles.
(completion--flex-adjust-metadata): Treat the arg as immutable.
Sometimes, when finding files with icomplete-mode, backward-deleting
the previous word or sexp (to move up a directory) doesn't actually
refresh the file list of the new directory. Forcing redisplay in
icomplete-exhibit misteriously fixes the problem.
* lisp/icomplete.el (icomplete-exhibit): Add call to redisplay.
This tries (not particularly hard) to emulate Ido's magic C-k, C-d,
RET and DEL. For now, the new commands have to be explicitly added to
an active map by the user, using something like this:
(let ((imap icomplete-minibuffer-map))
(define-key imap (kbd "C-k") 'icomplete-magic-ido-kill)
(define-key imap (kbd "C-d") 'icomplete-magic-ido-delete-char)
(define-key imap (kbd "RET") 'icomplete-magic-ido-ret)
(define-key imap (kbd "DEL") 'icomplete-magic-ido-backward-updir))
* lisp/icomplete.el (icomplete-magic-ido-kill)
(icomplete-magic-ido-delete-char, icomplete-magic-ido-ret)
(icomplete-magic-ido-backward-updir): New commands.
* lisp/tab-bar.el (tab-bar-history--pre-change): Store also minibuffer-depth.
(tab-bar-history-change): Check stored minibuffer-depth for zero.
(tab-bar-history-mode): Use prefix -- for internal functions.
* lisp/progmodes/python.el (python-rx): Use `rx-let' instead of
`rx-constituents'. This allows for some slight redundancy reduction,
since `rx-let' definitions are expanded inside `not' (bug#37849).
Reorder some `or' forms for more efficient matching.
* lisp/erc/erc.el (erc-hide-current-message-p): Make
erc-channel-hide-list work (bug#37879) by getting matching on the
channel name instead of the ERC client name.
* lisp/gnus/gnus-cus.el (gnus-group-customize): Decoding is
superfluous here -- everything is utf-8 already.
(gnus-group-customize-done): Don't double-encode the text (bug#37901).
* lisp/net/tramp-sh.el (tramp-maybe-open-connection):
`tramp-encoding-command-interactive' must be the last command-line
switch, at least for bash. (Bug#37953)
Copyright-paperwork-exempt: yes
* lisp/tab-bar.el (tab-bar-back-button, tab-bar-forward-button):
New variables.
(tab-bar-make-keymap-1): Show these buttons in tab-bar-history-mode.
(tab-bar--tab): Add history-back and history-forward.
(tab-bar-select-tab): Restore history-back and history-forward.
(tab-bar-history-omit, tab-bar-history-back)
(tab-bar-history-forward, tab-bar-history-pre-change): New variables.
(tab-bar-history-pre-change, tab-bar-history-change)
(tab-bar-history-back, tab-bar-history-forward)
(tab-bar-history-mode): New functions.
This is so minibuffer.el can make use of cl-generic
* lisp/minibuffer.el (minibuffer-local-completion-map):
Move switch-to-completions bindings here from...
* lisp/simple.el (minibuffer-local-completion-map): ... here.
* time-stamp.el (time-stamp-time-zone): Support customization with
an integer offset (a new possible value of the ZONE argument to
format-time-string in Emacs 27).
Update the safe-local-variable predicate from string-or-null-p
(describing time-stamp-time-zone's domain before 2015) to new
predicate time-stamp-zone-type-p (describing the current domain).
* time-stamp-tests.el (time-stamp-test-helper-zone-type-p): New test.
* lisp/emacs-lisp/tabulated-list.el (tabulated-list-print):
Don't use count-screen-lines, as it is unreliable when lines
are truncated and the region ends before a newline (the root
cause is in vertical-motion, but is very hard to fix there).
Instead, use vertical-motion directly, as the problems with
counting/not counting the newline that ends the region are not
relevant to what we need in this function, which is simply the
number of the current window line. (Bug#37941)
Often, when using icomplete with icomplete-show-matches-on-no-input
and commands like C-h f, icomplete-exhibit will take a long time (like
several seconds) to show all the completions.
However, if there is a non-nil default value, like when the C-h f is
performed exactly on a function name, the minibuffer prompt will
reflect that immediately. If the user immediately presses RE
(icomplete-force-complete-and-exit) we take that to mean "use the
default" and avoid the long wait.
As an extra performance tweak, this commit also removes an unneeded
call to icomplete-exhibit in icomplete-minibuffer-setup.
* lisp/icomplete.el (icomplete-force-complete-and-exit): Short-circuit
possibility of non-nil minibuffer-default.
(icomplete-minibuffer-setup): No need to explicitly icomplete-exhibit
here since icomplete-post-command-hook will call it unconditionally.
* lisp/net/tramp.el (tramp-call-process): `result' can also be nil.
* test/lisp/net/tramp-tests.el (tramp--test-timeout-handler):
Improve trace format.