1
0
mirror of https://git.savannah.gnu.org/git/emacs.git synced 2024-12-16 09:50:25 +00:00
Commit Graph

143599 Commits

Author SHA1 Message Date
Lars Ingebrigtsen
5cea77af41 Partially revert previous define-minor-mode change
* lisp/emacs-lisp/easy-mmode.el (easy-mmode--arg-docstring):
Only document the values we want to support, not the ones we
actually support.
(define-minor-mode): Partially revert to previous behaviour.
2020-11-02 10:17:08 +01:00
Stefan Kangas
5ab5504def Fix mistake in Lisp conversion of describe-map-tree
* lisp/help.el (describe-map-tree): Fix mistake in conversion to Lisp
from the C function describe_map_tree; make the condition match the
now removed C code.  (Bug#44360)
2020-11-01 22:52:02 +01:00
Juri Linkov
030ab2dad5 Transient input methods bound to 'C-x \' (bug#44266)
* lisp/international/mule-cmds.el (ctl-x-map): Bind 'C-x \' to
'transient-input-method'.
(input-method-function): New defcustom.
(transient-input-method): New command.

* doc/emacs/mule.texi (Select Input Method): Document transient-input-method.
2020-11-01 23:35:41 +02:00
Juri Linkov
1a1019f99f * lisp/leim/quail/compose.el: New input method (bug#44267). 2020-11-01 23:25:10 +02:00
Juri Linkov
43d5b79a69 Show nobreak-space face for more blank characters in describe-char.
* lisp/descr-text.el (describe-char): Handle more non-ASCII whitespace
characters added in f018cffca0 (bug#44236)
2020-11-01 23:20:53 +02:00
Stefan Kangas
7baf8cae0f Don't auto-insert "@c file ends here" in .texi files
* lisp/autoinsert.el (auto-insert-alist): Don't insert "@c file ends
here" at the end of new .texi files.
2020-11-01 18:58:12 +01:00
Stefan Kangas
8ad9932f11 Don't bind standard-output in substitute-command-keys
This fixes a regression with regards to the old C version of
substitute-command-keys.

* lisp/help.el (substitute-command-keys): Don't bind standard-output.
See Bug#39149.
* test/lisp/help-tests.el
(help-tests--was-in-buffer): New variable.
(help-substitute-command-keys/menu-filter-in-correct-buffer): New
test.
2020-11-01 18:58:12 +01:00
Glenn Morris
8761c155e4 * lisp/emacs-lisp/easy-mmode.el (easy-mmode--arg-docstring): Doc typo. 2020-11-01 09:39:44 -08:00
Mattias Engdegård
d85e0df7ad Add missing side-effect-free and error-free properties
Any function that is pure is also side-effect-free and some are also
error-free.  Right now these have to be declared separately.

* lisp/emacs-lisp/byte-opt.el (side-effect-free-fns): Add
bool-vector-count-consecutive, bool-vector-count-population,
bool-vector-subsetp, copysign, isnan, lax-plist-get, ldexp, memql,
regexp-opt and string-to-syntax.
(side-effect-and-error-free-fns): Add type-of.
* lisp/subr.el (kbd, string-replace): Declare side-effect-free.
2020-11-01 18:22:11 +01:00
Mattias Engdegård
d860168493 * lisp/emacs-lisp/byte-opt.el (pure-fns): Fix typos. 2020-11-01 16:00:49 +01:00
Stefan Kangas
ce1856ec09 Insert describe-map-tree header into original buffer
* lisp/help.el (describe-map-tree): Insert header into the original
buffer, not in standard-output.
* test/src/keymap-tests.el
(describe-buffer-bindings/header-in-current-buffer)
(describe-buffer-bindings/returns-nil): New tests.
Ref: https://debbugs.gnu.org/39149#31
2020-11-01 15:53:43 +01:00
Basil L. Contovounesios
5ce37da355 ; * doc/emacs/custom.texi (Keymaps): Fix typo. 2020-11-01 14:46:22 +00:00
Glenn Morris
ed70be7a18 ; Auto-commit of loaddefs files. 2020-11-01 06:28:38 -08:00
Lars Ingebrigtsen
2a4b0da28c Make minor mode ARG work as documented
* lisp/emacs-lisp/easy-mmode.el (easy-mmode--arg-docstring):
Clarify when minor modes are switched on/off when called from lisp
(bug#44341).
(define-minor-mode): Make calls from Lisp switch the mode on/off
as documented.
2020-11-01 15:00:44 +01:00
Mauro Aranda
ecec9a259b Fix saving a face setting with Customize
* lisp/cus-edit.el (custom-face-save): Make sure we back up into the
:shown-value property what the user has edited so far, if we are going
to recreate the custom-face widget.  (Bug#44331)
2020-11-01 10:10:08 -03:00
Yasuhiro KIMURA
43a1b79f56 Recover the contents of the schemas.xml file
* etc/schema/schemas.xml: Recover the file, which was apparently
(mostly) removed by mistake by commit 165f738382 (bug#42851).

Copyright-paperwork-exempt: yes
2020-11-01 14:01:31 +01:00
Lars Ingebrigtsen
7a3d8559c9 Doc string clarification for cl-some
* lisp/emacs-lisp/cl-extra.el (cl-some): Clarify the return value
(bug#44330).
2020-11-01 13:55:29 +01:00
Lars Ingebrigtsen
76d522e59e custom-theme-set-variables more resilient against removed libraries
* lisp/custom.el (custom-theme-set-variables): Don't bug out on
  settings that require a library that has been removed (bug#38843).
2020-11-01 13:14:41 +01:00
Lars Ingebrigtsen
a0a60321fe Mention non-ASCII C-c LETTER bindings in the lispref manual
* doc/lispref/tips.texi (Key Binding Conventions): Mention
non-ASCII C-c LETTER (bug#15917).
2020-11-01 12:51:17 +01:00
Lars Ingebrigtsen
7602ed6b82 Mention the C-c LETTER keybinding convention
* doc/emacs/custom.texi (Keymaps): Reintroduce the text about C-c
LETTER (bug#15917), and clarify.
2020-11-01 12:48:40 +01:00
Michael Albinus
06585bb939 Trash remote files to local trash (Bug#44216)
* doc/misc/tramp.texi (Frequently Asked Questions): Add trashing.

* lisp/net/tramp-adb.el (tramp-adb-handle-delete-directory)
(tramp-adb-handle-delete-file):
* lisp/net/tramp-gvfs.el (tramp-gvfs-handle-delete-directory)
(tramp-gvfs-handle-delete-file):
* lisp/net/tramp-sh.el (tramp-sh-handle-delete-directory)
(tramp-sh-handle-delete-file):
* lisp/net/tramp-smb.el (tramp-smb-handle-delete-directory)
(tramp-smb-handle-delete-file):
* lisp/net/tramp-sudoedit.el (tramp-sudoedit-handle-delete-directory)
(tramp-sudoedit-handle-delete-file): Implement local trash.  (Bug#44216)

* lisp/net/tramp-crypt.el (tramp-crypt-handle-delete-directory)
(tramp-crypt-handle-delete-file): Do not trash.

* lisp/net/tramp.el (tramp-skeleton-delete-directory): New defmacro.

* test/lisp/net/tramp-tests.el (tramp-test07-file-exists-p)
(tramp-test14-delete-directory): Add trashing.
2020-11-01 12:42:29 +01:00
Michael Albinus
881eeeef94 * etc/NEWS: Add trashing of remote files. Fix typos. 2020-11-01 12:40:30 +01:00
Lars Ingebrigtsen
47addaea9f Fix error message in feedmail
* lisp/mail/feedmail.el (feedmail-buffer-to-smtpmail): Remove
superfluous %s in insert string
2020-11-01 12:21:05 +01:00
Lars Ingebrigtsen
9405cd84a6 Fix a segfault in the new svg code
* src/image.c (svg_load_image): Don't pass in a NULL for the
logical rect, because that will sometimes segfault.
2020-11-01 00:10:30 +01:00
Juri Linkov
5d9e456c3e New variable integer-output-format to print integers as characters (bug#44155)
* doc/lispref/streams.texi (Output Variables): Add integer-output-format.

* src/print.c (print_object): In case of Lisp_Int, print integers
as characters when Vinteger_output_format is Qt, and in hex format
when Vinteger_output_format is 16.
(Vinteger_output_format): New variable.

* test/src/print-tests.el (print-integer-output-format): New test.
2020-10-31 22:11:02 +02:00
Mauro Aranda
c307c9648d Give the scroll-bar face a non-trivial spec
* lisp/faces.el (scroll-bar): Give it a non-trivial spec, so when
resetting it to its face-defface-spec, we effectively reset it.
(Bug#13476)
2020-10-31 17:07:59 -03:00
Juri Linkov
80a87af135 Improve goto-line in regard to narrowed buffers (bug#44294)
* lisp/simple.el (goto-line): Rewrite to first find the position
of the line where to go, then later don't widen the buffer
when the found position is still inside narrowed part of buffer.

* lisp/isearch.el (isearch-message-prefix): Warn about narrowed	buffer
in case of no more matches found.
2020-10-31 21:39:28 +02:00
Juri Linkov
71795c6c4a Reimplement commit 46b3db5579 (bug#44294)
* lisp/progmodes/etags.el (etags-goto-tag-location): Revert change from
commit 46b3db5579.
(xref-location-marker): Use the same change as was made in elisp-mode.el in
commit 46b3db5579 to widen before going
to the found position.
2020-10-31 21:39:28 +02:00
Stefan Kangas
f9cac26dc1 * test/README: Document TEST_BACKTRACE_LINE_LENGTH. 2020-10-31 20:27:39 +01:00
Amin Bandali
ca3b199ad5
; * etc/NEWS: Tweak the wording for the newly added entry 2020-10-31 14:39:36 -04:00
Amin Bandali
ae9f234dd9
; * etc/NEWS: Add entry for my last change 2020-10-31 14:30:30 -04:00
Amin Bandali
694c82ab1a
Replace irc.freenode.net with chat.freenode.net
chat.freenode.net has been the preferred address for connecting to the
freenode IRC network for years now.  Replace the occurrences of
irc.freenode.net with chat.freenode.net.
2020-10-31 14:09:29 -04:00
Mattias Engdegård
0ef5bbd5d4 Fix eshell glob modifiers
Modified globbing such as *.txt(W) for all world-writable files ending
in .txt apparently never worked correctly.

* lisp/eshell/em-pred.el (eshell-predicate-alist): Use correct
elisp syntax for octal constants.
(eshell-pred-file-mode): Return a boolean, not a number.
2020-10-31 18:03:38 +01:00
Andreas Schwab
596802c063 wdired: fix error handling of set-file-modes
* lisp/wdired.el (wdired-perms-to-number): Return decimal number.
(wdired-do-perm-changes): Handle error from set-file-modes.
(wdired-finish-edit): Remove `rename' from error message.
(Bug#44343)
2020-10-31 16:37:01 +01:00
Eli Zaretskii
283b8d274b * etc/HELLO: Enlarge tab-width to account for "tofu". 2020-10-31 16:05:03 +02:00
Mattias Engdegård
0cbcc6223a 'assoc' is not side-effect-free; constprop its pure subset
Since a supplied test function can do anything, assoc is not
side-effect-free (bug#44018).  However, with only two arguments it is
pure and should be optimised accordingly.

* lisp/emacs-lisp/byte-opt.el (side-effect-free-fns): Remove 'assoc'.
(byte-optimize-assoc): Constant-propagate through 2-arg assoc calls.
* test/lisp/emacs-lisp/bytecomp-tests.el
(byte-opt-testsuite-arith-data): Add test cases.
2020-10-31 14:31:43 +01:00
Eli Zaretskii
8d72075aeb Improve support for displaying Javanese script
* lisp/international/fontset.el (setup-default-fontset)
(script-representative-chars): Add Javanese entries.

* etc/HELLO: Fix the Javanese text.  See
https://omniglot.com/language/phrases/javanese.php for the
source.
2020-10-31 15:20:18 +02:00
Stefan Monnier
7103192cd2 * src/xdisp.c (syms_of_xdisp) <"scroll-minibuffer-conservatively">: New var
Fix bug#44070, which causes the minibuffer display to jump upon minor edit

(redisplay_window): Obey it.
* lisp/simple.el (end-of-buffer): Obey it.

* test/src/xdisp-tests.el (xdisp-tests--in-minibuffer): New macro,
extracted from `xdisp-tests--minibuffer-resizing`.
(xdisp-tests--minibuffer-resizing): Use it.
(xdisp-tests--minibuffer-scroll): New test.
2020-10-31 09:07:53 -04:00
Mattias Engdegård
c3a20804a8 Trim and explain set of safe forms for 'unsafep' (bug#44018)
* lisp/emacs-lisp/unsafep.el:
Add comment explaining the policy for which forms can be considered
'safe' in the sense of unsafep.  Remove ones that didn't make the cut:

 play-sound-file (large attack surface)
 catch, throw (alter program flow, inject data)
 replace-regexp-in-string (execute arbitary code)
 error, signal (deceptive messages)

* test/lisp/emacs-lisp/unsafep-tests.el (unsafep-tests--unsafe):
Add test cases.
* etc/NEWS: Announce the change.
2020-10-31 13:42:07 +01:00
Mattias Engdegård
a78c6141bc Parse GDB/MI results directly instead of going via JSON (bug#44173)
Translating GDB/MI into JSON is an unnecessary and fragile detour
that made it hard to deal with octal escapes in strings correctly.
Parse GDB/MI directly instead.

* lisp/progmodes/gdb-mi.el (gdb-mi-decode-strings): Adjust doc string.
(gdb-mi-decode, gud-gdbmi-marker-filter): Remove gdb-mi-decode.
(gdb-jsonify-buffer): Remove.
(gdb-mi--parse-tuple-or-list, gdb-mi--parse-c-string)
(gdb-mi--parse-value, gdb-mi--parse-result-or-value)
(gdb-mi--parse-results, gdb-mi--fix-key, gdb-mi--extend-fullname)
(gdb-mi--c-string-from-string): New functions.
(gdb-json-read-buffer, gdb-json-string, gdb-json-partial-output):
Rename to gdb-mi--read-buffer, gdb-mi--from-string and
gdb-mi--partial-output respectively.  Remove useless FIX-LIST
argument.  FIX-KEY is now a symbol, not a string. All callers updated.
(gdb-tooltip-print, gdbmi-bnf-log-stream-output, gdb-internals)
(gdb-console, gdb-done-or-error, gdb-get-source-file-list)
(gdb-get-prompt, gdb-get-source-file):
Use gdb-mi--c-string-from-string instead of 'read'.
* test/lisp/progmodes/gdb-mi-tests.el: New file.
2020-10-31 13:42:07 +01:00
Eli Zaretskii
7f30bf7206 * etc/HELLO: Add Egyptian Hieroglyphs. 2020-10-31 13:02:52 +02:00
Eli Zaretskii
66ceb148c7 Support prettified display of fractional numbers
* lisp/composite.el (composition-function-table): Define an entry
for U+2044 FRACTION SLASH, for prettier display of fractional
numbers.
2020-10-31 12:40:25 +02:00
Michael Albinus
dc16c70bad Check also for "DragonFly" remote systems in Tramp
* lisp/net/tramp-sh.el (tramp-open-connection-setup-interactive-shell):
Check also for "DragonFly".
2020-10-31 11:29:06 +01:00
Eli Zaretskii
96ec034071 Speed up ls-lisp
This speeds up Dired by 25% in large directories.
* lisp/ls-lisp.el (ls-lisp--time-locale): New defvar.
(ls-lisp-format-time): calculate the locale for formatting times
only once and cache the value in 'ls-lisp--time-locale'.
(Bug#44273)
2020-10-31 11:41:53 +02:00
Eli Zaretskii
41c4f337c8 * doc/lispref/commands.texi (Key Sequence Input): Fix indexing. 2020-10-31 10:01:44 +02:00
Jared Finder
a105db13e1 Updating docs with all special window prefix keys.
* doc/lispref/commands.texi (Key Sequence Input): Add documentation for
missing special window areas.  Explicitly call out window or frame.
2020-10-31 09:59:16 +02:00
Jared Finder
2a6337a6c4 Fix unit tests broken by changes to xt-mouse.el
* test/lisp/xt-mouse-tests.el (xt-mouse-tracking-basic)
(xt-mouse-tracking-utf-8): Update expected escape sequence.
2020-10-31 09:57:00 +02:00
Eli Zaretskii
8800d8c640 Revert "Temporarily mark two failing tests"
This reverts commit a8426f4672.
A proper fix for the test is about to be installed shortly.
2020-10-31 09:56:14 +02:00
Thien-Thi Nguyen
73bc7b543b Make hideshow.el work with Mhtml mode
Suggested by Ian Williams <norbekian9@gmail.com>.

* lisp/textmodes/mhtml-mode.el: Require ‘pcase’ when compiling.
(mhtml-forward): New func.
* lisp/progmodes/hideshow.el (hs-special-modes-alist):
Add entry for ‘mhtml-mode’.
2020-10-30 22:40:11 -04:00
João Távora
74c45a62e1 Shoosh byte-compilation warning in lisp/emacs-lisp/eldoc.el
Per bug#43609, elisp-eldoc-documentation-function is again in master,
but since it's now officially obsoleted, this backward compatibility
shim in eldoc--eval-expression-setup shouldn't unnecessarily trigger
warnings in master's code.

* lisp/emacs-lisp/eldoc.el (eldoc--eval-expression-setup): Shoosh
by-compilation warning.
2020-10-30 22:31:20 +00:00