1
0
mirror of https://git.savannah.gnu.org/git/emacs.git synced 2025-01-18 18:05:07 +00:00
Commit Graph

9922 Commits

Author SHA1 Message Date
Andrea Corallo
8fb9463013 Merge remote-tracking branch 'savannah/master' into HEAD 2020-12-27 17:54:57 +01:00
Daniel Martín
80420faf49 Improve "find definition" in *Help* buffers
* lisp/emacs-lisp/find-func.el (find-function-search-for-symbol): If
our regexp algorithm could not find a location for the symbol
definition, resort to find-function--search-by-expanding-macros.
* test/lisp/emacs-lisp/find-func-tests.el: Add a automatic test for a
function and variable generated by a macro.
* etc/NEWS: Advertise the improved functionality (bug#45443).
2020-12-27 09:04:56 +01:00
Lars Ingebrigtsen
0f790464d5 Add new predicates for sequence lengths
* doc/lispref/sequences.texi (Sequence Functions): Document them.
* lisp/emacs-lisp/byte-opt.el (side-effect-free-fns): Mark them as
side-effect-free.

* lisp/emacs-lisp/shortdoc.el (list): Mention them.

* src/fns.c (Flength): Mention them in the doc string.
(length_internal): New function.
(Flength_less, Flength_greater, Flength_equal): New defuns.
(syms_of_fns): Sym them.
2020-12-27 09:00:23 +01:00
Michael Albinus
fd658b8100 Rename Tramp method "media" to "mtp" (Bug#45402)
* doc/misc/tramp.texi (Quick Start Guide, GVFS-based methods):
Rename "media" to "mtp".  (Bug#45402)

* etc/NEWS: Rename Tramp method "media" to "mtp".  Fix typos.

* lisp/net/tramp-gvfs.el (tramp-gvfs-methods, tramp-media-methods)
(tramp-gvfs-activation-uri)
(tramp-gvfs-handler-volumeadded-volumeremoved)
(tramp-get-media-devices, top): Rename "media" to "mtp".  (Bug#45402)
2020-12-26 12:39:10 +01:00
Glenn Morris
90ec81f5b2 Merge from origin/emacs-27
b242bbb073 (origin/emacs-27) ; lisp/org/org.el: Fix Version header.
e0fc939c5f Add more details to the "word processor" section
fda9b3e83a * src/Makefile.in (DO_CODESIGN): Fix expected architecture...
2020-12-25 10:36:48 -08:00
Glenn Morris
2e20749e57 Merge from origin/emacs-27
5d46593568 Support build of Emacs on ARM Macos machines
7f8793e5f1 Update to Org 9.4.4
7b3367a0b5 * lisp/so-long.el: Decrease use of passive voice.
a90836c638 * doc/misc/efaq.texi (New in Emacs 27): Add section.
711fe70dd8 * doc/misc/efaq.texi (Latest version of Emacs): Bump version.
52b30834fb * lisp/face-remap.el (face-remap-set-base): Doc fix.  (Bug...
b3fe0ac62e Correct argument order in comment
2020-12-25 10:36:48 -08:00
Eli Zaretskii
3649160f61 ; * etc/NEWS: Announce the last change. 2020-12-25 16:11:49 +02:00
Eli Zaretskii
e0fc939c5f Add more details to the "word processor" section
* etc/TODO (Emacs as word processor): Add more details based on
recent discussions.
2020-12-25 10:30:02 +02:00
Thibault Polge
174327cefa Make `remove-hook' interactive
* lisp/subr.el (remove-hook): Make `remove-hook' interactive
(bug#45393).
2020-12-25 06:44:40 +01:00
Lars Ingebrigtsen
269cec13a2 Remove `string-slice' -- it's not very well defined
* doc/lispref/strings.texi (Creating Strings): Ditto.

* lisp/emacs-lisp/subr-x.el (string-slice): Remove.
2020-12-25 05:16:46 +01:00
TEC
3be0dc659f authinfo-mode: add option to not hide any elements (and add font-lock)
* lisp/auth-source.el (authinfo-hide-elements): New user option.
(authinfo--keywords): New variable.
(authinfo-mode): Use it.
(authinfo--hide-passwords): Use doc-face instead of warning for
the passwords.
(authinfo--toggle-display): Ditto.
2020-12-23 22:34:35 +01:00
Adam Porter
33210c8dc0 * lisp/tab-line.el: New options, faces, and functions
* lisp/tab-line.el:
(tab-line-tab-face-functions): New option.
(tab-line-tab-inactive-alternate): New face.
(tab-line-tab-special): New face.
(tab-line-tab-face-inactive-alternating): New function.
(tab-line-tab-face-special): New function.
(tab-line-format-template): Use them.

* etc/NEWS: Update.

With thanks to Juri Linkov and Eli Zaretskii for their guidance.
2020-12-23 23:05:55 +02:00
Andrea Corallo
b99a474482 Merge remote-tracking branch 'savannah/master' into HEAD 2020-12-23 19:49:58 +01:00
Philipp Stephani
3cbd4169d6 Reject filenames containing NUL bytes.
Such filenames are dangerous, as Emacs would silently only use the
part up to the first NUL byte.  Reject them explicitly instead.

* src/coding.c (encode_file_name_1): New helper function.
(encode_file_name): Check that encoded filename doesn't contain a
NUL byte.
(syms_of_coding): Define 'filenamep' symbol.

* test/src/fileio-tests.el (fileio-tests/null-character): New unit
test.

* etc/NEWS: Document change.
2020-12-23 12:00:46 +01:00
Alan Mackenzie
9920929e7b Re-order the items in `profiler-report' output.
Putting the usage figures first on the line will eliminate the truncation of
function names.

lisp/profiler.el (profiler-version): Change to "28.1".
(profiler-format): Enhance, so that a width of zero means print the string
without padding or truncation.
(profiler-report-cpu-line-format, profiler-report-memory-line-format): Amend
for the new layout.  The number of places for the cpu samples has been reduced
from 19 to 12 (enough for ~30 years at 1,000 samples per second).
(profiler-report-line-format, profiler-report-describe-entry): Amend for the
new order of arguments to profiler-format.

etc/NEWS (Specialized Modes): Add an entry documenting this change.

doc/lispref/debugging.texi (Profiling): Describe the new ordering of the items
in place of the old ordering.
2020-12-22 12:06:21 +00:00
Lars Ingebrigtsen
f329a3180e Add string-chop-newline
* doc/lispref/strings.texi (Creating Strings): Document it.
* lisp/emacs-lisp/subr-x.el (string-chop-newline): Add new function.
2020-12-21 22:05:37 +01:00
Basil L. Contovounesios
e967ba3018 ; Fix recent string utility additions
* etc/NEWS: Fix typo.
* lisp/emacs-lisp/subr-x.el (string-limit): Fix typos in docstring.
Simplify.
(string-slice): Improve docstring wording.
(string-pad): Simplify.
2020-12-21 20:51:29 +00:00
Lars Ingebrigtsen
cf2e832185 Rename slice-string to string-slice
* lisp/emacs-lisp/subr-x.el (string-slice): Rename from slice-string.
* doc/lispref/strings.texi (Creating Strings): Ditto.
2020-12-21 20:18:57 +01:00
Lars Ingebrigtsen
b3dec31766 Add `string-pad'
* doc/lispref/strings.texi (Creating Strings): Document it.
* lisp/emacs-lisp/shortdoc.el (string): Add example.

* lisp/emacs-lisp/subr-x.el (string-pad): New function.
2020-12-21 20:01:28 +01:00
Lars Ingebrigtsen
87e422f104 Beef up the Emacs string utility set a bit
* doc/lispref/strings.texi (Modifying Strings): Document them.
* lisp/emacs-lisp/shortdoc.el (string): Add examples.

* lisp/emacs-lisp/subr-x.el (string-clean-whitespace)
(string-fill, string-limit, string-lines, slice-string): New
functions.
2020-12-21 18:53:40 +01:00
Andrea Corallo
f244c21902 Merge remote-tracking branch 'savannah/master' into HEAD 2020-12-20 22:08:42 +01:00
Michael Albinus
ecb5ebf156 Improve make-process in Tramp
* doc/misc/tramp.texi (Remote processes): Remove INSIDE_EMACS
restriction.
(Frequently Asked Questions, External packages): Add indices.

* etc/NEWS: 'start-process-shell-command' and
'start-file-process-shell-command' do not support the old calling
conventions any longer.

* lisp/subr.el (start-process-shell-command)
(start-file-process-shell-command): Remove old calling conventions.

* lisp/net/tramp-compat.el (remote-file-error): Remove, it isn't
necessary.

* lisp/net/tramp.el (tramp-handle-make-process): Remove special shell
handling.  Support environment variables.

* test/lisp/net/tramp-tests.el
(tramp--test--deftest-direct-async-process): Skip for mock method.
(tramp--test-async-shell-command): Suppress `shell-command-sentinel'.
(tramp-test32-shell-command, tramp-test33-environment-variables):
Adapt tests.
(tramp-test32-shell-command-direct-async)
(tramp-test33-environment-variables-direct-async): New tests.
2020-12-20 19:45:11 +01:00
Basil L. Contovounesios
1a0a11f7d2 Inhibit buffer hooks in temporary buffers
Give get-buffer-create an optional argument to inhibit buffer hooks
in internal or temporary buffers for efficiency (bug#34765).

* etc/NEWS: Announce new parameter of get-buffer-create and
generate-new-buffer, and that with-temp-buffer and with-temp-file
now inhibit buffer hooks.

* doc/lispref/buffers.texi (Buffer Names): Fix typo.
(Creating Buffers): Document new parameter of get-buffer-create and
generate-new-buffer.
(Buffer List, Killing Buffers): Document when buffer hooks are
inhibited.
(Current Buffer):
* doc/lispref/files.texi (Writing to Files): Document that
with-temp-buffer and with-temp-file inhibit buffer hooks.
* doc/lispref/internals.texi (Buffer Internals): Document
inhibit_buffer_hooks flag.  Remove stale comment.
* doc/misc/gnus-faq.texi (FAQ 5-8):
* lisp/simple.el (shell-command-on-region): Fix indentation.

* lisp/files.el (kill-buffer-hook): Document when hook is inhibited.
(create-file-buffer):
* lisp/gnus/gnus-uu.el (gnus-uu-unshar-article):
* lisp/international/mule.el (load-with-code-conversion):
* lisp/mh-e/mh-xface.el (mh-x-image-url-fetch-image):
* lisp/net/imap.el (imap-open):
* lisp/net/mailcap.el (mailcap-maybe-eval):
* lisp/progmodes/flymake-proc.el
(flymake-proc--read-file-to-temp-buffer)
(flymake-proc--copy-buffer-to-temp-buffer): Simplify.

* lisp/subr.el (generate-new-buffer): Forward new optional argument
to inhibit buffer hooks to get-buffer-create.
(with-temp-file, with-temp-buffer, with-output-to-string):
* lisp/json.el (json-encode-string): Inhibit buffer hooks in buffer
used.

* src/buffer.c (run_buffer_list_update_hook): New helper function.
(Fget_buffer_create): Use it.  Add optional argument to set
inhibit_buffer_hooks flag instead of comparing the buffer name to
Vcode_conversion_workbuf_name.  All callers changed.
(Fmake_indirect_buffer, Frename_buffer, Fbury_buffer_internal)
(record_buffer): Use run_buffer_list_update_hook.
(Fkill_buffer): Document when buffer hooks are inhibited.  Use
run_buffer_list_update_hook.
(init_buffer_once): Inhibit buffer hooks in Vprin1_to_string_buffer.
(Vkill_buffer_query_functions, Vbuffer_list_update_hook): Document
when hooks are inhibited.
* src/buffer.h (struct buffer): Update inhibit_buffer_hooks
commentary.
* src/coding.h (Vcode_conversion_workbuf_name):
* src/coding.c (Vcode_conversion_workbuf_name): Make static again
since it is no longer needed in src/buffer.c.
(code_conversion_restore, code_conversion_save, syms_of_coding):
Prefer boolean over integer constants.
* src/fileio.c (Finsert_file_contents): Inhibit buffer hooks in
" *code-converting-work*" buffer.
* src/window.c (Fselect_window): Fix grammar.  Mention
window-selection-change-functions alongside buffer-list-update-hook.

* test/src/buffer-tests.el: Fix requires.
(buffer-tests-inhibit-buffer-hooks): New test.
2020-12-20 17:32:24 +00:00
Vasilij Schneidermann
b3fe0ac62e Correct argument order in comment
* etc/ETAGS.EBNF (position): Correct comment.
2020-12-19 19:41:18 +02:00
Roland Winkler
9f7e0a3e7d bibtex-mode: Permit user-defined schemes for sorting entries.
* lisp/textmodes/bibtex.el (bibtex-maintain-sorted-entries):
New allowed value (INDEX-FUN PREDICATE).
(bibtex-entry-index, bibtex-lessp): Use it.
(bibtex-init-sort): Rename from bibtex-init-sort-entry-class-alist.
2020-12-18 22:26:40 -06:00
Glenn Morris
8d2d8d7f53 Merge from origin/emacs-27
48b9c47805 Minor fixes in authors.el and in tarball-making instructions
d7a4ceaa1e ; Add a new item to TODO
64fe805b19 Improve documentation of 'query-replace'
7cacf5da47 Update to Org 9.4.3

# Conflicts:
#	admin/authors.el
2020-12-18 08:55:06 -08:00
Eli Zaretskii
37eba74d60 Update files for the 27.1.90 pretest
* README:
* configure.ac:
* nt/README.W32:
* msdos/sed2v2.inp: Bump Emacs version to 27.1.90.
* lisp/ldefs-boot.el: Update from loaddefs.el
2020-12-18 10:13:53 -05:00
Eli Zaretskii
d7a4ceaa1e ; Add a new item to TODO
* etc/TODO (redisplay): Add an item for making redisplay cycle
more scalable when there are many frames.
2020-12-17 16:22:05 +02:00
Glenn Morris
cbdd48a07b Merge from origin/emacs-27
668f0a7f84 Fix point location when completing in gdb-mi.el
2dbc95063b Update to Org 9.4.2
f22856a5c5 Update to Org 9.4.1

# Conflicts:
#	doc/misc/org.texi
#	lisp/org/ob-core.el
#	lisp/org/ob-ruby.el
#	lisp/org/ob-screen.el
#	lisp/org/ol-gnus.el
#	lisp/org/ol.el
#	lisp/org/org.el
2020-12-15 09:24:21 -08:00
Michael Albinus
c0c6cd2d5d Add 'remote-file-error' for Tramp
* doc/lispref/errors.texi (Standard Errors): Add 'remote-file-error'.

* etc/NEWS: Mention 'remote-file-error'.

* lisp/net/ange-ftp.el (ftp-error): Add error condition
`remote-file-error'.

* lisp/net/tramp-cmds.el (tramp-cleanup-all-connections): Do not set
`tramp-locked'.

* lisp/net/tramp-compat.el (remote-file-error): Define if it
doesn't exist.

* lisp/net/tramp-sh.el (tramp-timeout-session): Check for "locked"
property.
(tramp-maybe-open-connection): Simplify.

* lisp/net/tramp.el (tramp-locked, tramp-locker): Remove them.
(tramp-file-name-handler): Do not set them.
(with-tramp-locked-connection): New defmacro.
(tramp-accept-process-output, tramp-send-string): Use it.

* src/fileio.c (Qremote_file_error): New error symbol.

* test/lisp/net/tramp-tests.el (tramp-test43-asynchronous-requests):
Adapt test.  Remove :unstable tag.
2020-12-14 19:30:01 +01:00
Tim Ruffing
e5348f125f * etc/emacs.service:
* etc/emacs.service (ExecStart): Make Emacs exit from systemd work
better (bug#45181).

The problem here is the exit code 15, which emacs will return *only* if
it has received SIGTERM. I believe what's happening here is that
emacsclient will call kill-emacs but not wait until the emacs server
has properly shut down. However, it's supposed to wait for the shutdown
as an "ExecStop" command according to "man systemd.service". So since
the process is still alive when emacsclient comes back, systemd will
still issue SIGTERM, making emacs return 15 (maybe after calling kill-
emacs again?!).

Copyright-paperwork-exempt: yes
2020-12-14 17:59:58 +01:00
Daniel Martín
0dd8d53344 Make goto-char offer the number at point as default
* lisp/subr.el (read-natnum-interactive): New function to read natural
numbers for interactive functions.
* src/editfns.c (Fgoto_char): Call read-natnum-interactive from the
interactive definition of goto-char to offer the number at point as
default.  Also expand the docstring to document this new interactive
behavior.
* doc/emacs/basic.texi (Moving Point): Expand the Emacs manual to
document this new behavior.
* etc/NEWS: And announce it (bug#45199).
2020-12-14 17:16:00 +01:00
Lars Ingebrigtsen
252366866b Add a new recursively bound `current-minibuffer-command' variable
* doc/lispref/commands.texi (Command Loop Info): Document it
(bug#45177).

* src/callint.c (Fcall_interactively): Bind it.

* src/keyboard.c (syms_of_keyboard): Define
current-minibuffer-command.
2020-12-14 16:44:00 +01:00
Torsten Hilbrich
c42965745d Merge branch 'feature/integration-of-dictionary-el'
b6227446d9 Importing dictionary module
658ec3ccee Renamed connection.el
e2ebffdd62 Renamed link.el
723906c444 Removed some compability parts in dictionary
5dc17d73b0 Add :version tag to defcustom statement
49c250b388 Dont't check coding-system-list for existence
99a7e918c8 Don't check for existence of defface
1773b9b687 Dictionary now uses button
329b6a0210 Adding details page for dictionary
837505075c Fix dictionary tooltip mode
2f1e4fbc42 Support nil value for dictionary-server
91ff1c8f7c Move placement of dictionary-tooltip-mouse-event
28fe134971 Remove text property from empty line
7ca331a4f9 Add history of search words to read-string
d5a4da25b0 * lisp/net/dictionary.el: Remove remnants of package
cc5f280378 * lisp/net/dictionary.el: Add lexical-binding:t
09952ce434 Removed useless check for popup-menu
81ebe86d8d Show error message when asking to match for nothing
0044a2e888 * lisp/net/dictionary-connection.el: Add lexical-binding:t
f58443780c * lisp/net/dictionary-connection.el: Remove obsolete Version
54a3964e29 Update GPL version
a557a103cc * lisp/net/dictionary-connection.el: Prefer defsubst
ffa7d6671d * lisp/net/dictionary.el: Prefer defsubst over defmacro
4deb8618e4 * lisp/net/dictionary.el (dictionary-mode): Use setq-local
d30618cbc1 * lisp/net/dictionary.el (dictionary-tooltip-mode): Use ...
a25a12ddaf Use when where else case returns nil
89e9c1686e * lisp/net/dictionary.el (dictionary-display-more-info): ...
d466231c3e A number of docstring fixes
b18217eb87 A number of docstring fixes
ca0de4d1e0 * etc/NEWS: Add entry for dictionary.el
62d14e10f9 * lisp/net/dictionary.el (dictionary-pre-buffer): Unify casing
2020-12-14 12:09:41 +01:00
Torsten Hilbrich
ca0de4d1e0 * etc/NEWS: Add entry for dictionary.el 2020-12-14 11:45:24 +01:00
Juri Linkov
dc6e616dfe Don't show matches with no input for nil icomplete-show-matches-on-no-input
* lisp/icomplete.el (icomplete-show-matches-on-no-input): Fix docstring.
(icomplete--initial-input): New internal variable.
(icomplete-minibuffer-setup): Set buffer-local
icomplete--initial-input to icomplete--field-string.
(icomplete-ret, icomplete-force-complete-and-exit)
(icomplete--sorted-completions, icomplete-exhibit):
Compare icomplete--initial-input with icomplete--field-string
to detect no input.  (Bug#19031)

etc/NEWS: Remove duplicate entry.
2020-12-14 10:44:04 +02:00
Bastien Guerry
2dbc95063b Update to Org 9.4.2
Mostly fixing compiler warnings.
2020-12-13 22:26:51 +01:00
Bastien Guerry
f22856a5c5 Update to Org 9.4.1 2020-12-13 13:44:15 +01:00
Eric Abrahamsen
8a220d7c8f New option gnus-registry-register-all
* lisp/gnus/gnus-registry.el (gnus-registry-register-all): If nil,
the registry won't automatically create new entries for all seen
messages. Defaults to t to preserve previous behavior.
(gnus-registry-handle-action): Don't automatically create entries; if
one doesn't exist, don't handle anything.
(gnus-registry-register-message-ids): Only register if this option is
t.
(gnus-registry-get-or-make-entry): Add optional no-create argument.
(gnus-registry-get-id-key): This "get" operation should only create an
entry if this option is t.
* doc/misc/gnus.texi: Documentation and news.
2020-12-12 09:03:13 -08:00
Stefan Monnier
d165b5a46b New variable redisplay_adhoc_scroll_in_resize_mini_windows
* src/xdisp.c (syms_of_xdisp): Define it.
(resize_mini_window): Obey it.
2020-12-12 10:16:42 -05:00
Andrea Corallo
0474fda62d Merge remote-tracking branch 'savannah/master' into HEAD 2020-12-12 15:31:33 +01:00
Zajcev Evgeny
f45ce78c40 Explicitly specify svg base_uri using `:base-uri' image property
* src/image.c (svg_load): Check `:base-uri' image property to
explicitly set base_uri for images embedded into SVG
(enum svg_keyword_index):
(svg_format): Add :base-uri.
* lisp/svg.el (svg-embed-base-uri-image): New function to embed images
located relative to images `:base-uri'
2020-12-12 12:48:32 +00:00
Pankaj Jangid
dba74cb5ec Allow customizing the Gnus summary thread indicators
* doc/misc/gnus.texi (Summary Buffer Lines): Document them.

* lisp/gnus/gnus-sum.el (gnus-summary-prepare-threads): Use them.

* lisp/gnus/gnus-sum.el (gnus-sum-opening-bracket)
(gnus-sum-closing-bracket, gnus-sum-opening-bracket-adopted)
(gnus-sum-closing-bracket-adopted): New variables.
2020-12-12 11:47:17 +01:00
Stefan Monnier
78607f21b5 * lisp/play/dunnet.el: Make it so loading the file is harmless
Move comments into docstrings while at it.

(dun-batch): New function.
2020-12-11 19:06:55 -05:00
Lars Ingebrigtsen
004d7e97e2 Add a new command `memory-report'
* doc/lispref/internals.texi (Garbage Collection): Document it.
* lisp/emacs-lisp/memory-report.el: New package.
2020-12-11 14:49:53 +01:00
Lars Ingebrigtsen
aa7e5ce651 Add new function `object-intervals'
* doc/lispref/text.texi (Examining Properties): Document it.
* src/fns.c (Fobject_intervals): New defun.
(collect_interval): New function.
2020-12-11 14:40:20 +01:00
Lars Ingebrigtsen
9d598ef93c Add new function 'image-cache-size'
* src/image.c (Fimage_cache_size): New defun.
(image_frame_cache_size): New function.
2020-12-11 14:30:44 +01:00
Lars Ingebrigtsen
14ffab8263 Add a new function `button-buttonize'
* doc/lispref/display.texi (Manipulating Buttons): Document it.

* lisp/button.el (button-buttonize): Implement it.
2020-12-11 14:25:20 +01:00
Juri Linkov
303f0a19cc Support highlighting of ripgrep output (bug#44983)
* etc/grep.txt: Add ripgrep samples.

* lisp/progmodes/grep.el (grep-match-regexp): Highlight ripgrep matches too.
(grep-regexp-alist): Remove $ to highlight ripgrep binary file matches.
2020-12-09 21:16:03 +02:00
Glenn Morris
4adc79641f Merge from origin/emacs-27
c0b3e38d7c Update publicsuffix.txt from upstream
3fe6cea6e0 * lisp/vc/vc.el: Update args of backend API calls in the h...
2020-12-09 08:50:12 -08:00