1
0
mirror of https://git.savannah.gnu.org/git/emacs.git synced 2024-12-04 08:47:11 +00:00
Commit Graph

439 Commits

Author SHA1 Message Date
Mattias Engdegård
3b7b181bde Use string-search instead of string-match[-p]
`string-search` is easier to understand, less error-prone, much
faster, does not pollute the regexp cache, and does not mutate global
state.  Use it where applicable and obviously safe (erring on the
conservative side).

* admin/authors.el (authors-canonical-file-name)
(authors-scan-change-log):
* lisp/apropos.el (apropos-command)
(apropos-documentation-property, apropos-symbols-internal):
* lisp/arc-mode.el (archive-arc-summarize)
(archive-zoo-summarize):
* lisp/calc/calc-aent.el (math-read-factor):
* lisp/calc/calc-ext.el (math-read-big-expr)
(math-format-nice-expr, math-format-number-fancy):
* lisp/calc/calc-forms.el (math-read-angle-brackets):
* lisp/calc/calc-graph.el (calc-graph-set-range):
* lisp/calc/calc-keypd.el (calc-keypad-press):
* lisp/calc/calc-lang.el (tex, latex, math-read-big-rec):
* lisp/calc/calc-prog.el (calc-fix-token-name)
(calc-user-define-permanent, math-define-exp):
* lisp/calc/calc.el (calc-record, calcDigit-key)
(calc-count-lines):
* lisp/calc/calcalg2.el (calc-solve-for, calc-poly-roots)
(math-do-integral):
* lisp/calc/calcalg3.el (calc-find-root, calc-find-minimum)
(calc-get-fit-variables):
* lisp/cedet/ede/speedbar.el (ede-tag-expand):
* lisp/cedet/semantic/java.el (semantic-java-expand-tag):
* lisp/cedet/semantic/sb.el (semantic-sb-show-extra)
(semantic-sb-expand-group):
* lisp/cedet/semantic/wisent/python.el
(semantic-python-instance-variable-p):
* lisp/cus-edit.el (get):
* lisp/descr-text.el (describe-text-sexp):
* lisp/dired-aux.el (dired-compress-file):
* lisp/dired-x.el (dired-make-relative-symlink):
* lisp/dired.el (dired-glob-regexp):
* lisp/dos-fns.el (dos-convert-standard-filename, dos-8+3-filename):
* lisp/edmacro.el (edmacro-format-keys):
* lisp/emacs-lisp/eieio-opt.el (eieio-sb-expand):
* lisp/emacs-lisp/eieio-speedbar.el (eieio-speedbar-object-expand):
* lisp/emacs-lisp/lisp-mnt.el (lm-keywords-list):
* lisp/emacs-lisp/warnings.el (display-warning):
* lisp/emulation/viper-ex.el (viper-ex-read-file-name)
(ex-print-display-lines):
* lisp/env.el (read-envvar-name, setenv):
* lisp/epa-mail.el (epa-mail-encrypt):
* lisp/epg.el (epg--start):
* lisp/erc/erc-backend.el (erc-parse-server-response):
* lisp/erc/erc-dcc.el (erc-dcc-member):
* lisp/erc/erc-speedbar.el (erc-speedbar-expand-server)
(erc-speedbar-expand-channel, erc-speedbar-expand-user):
* lisp/erc/erc.el (erc-send-input):
* lisp/eshell/em-glob.el (eshell-glob-entries):
* lisp/eshell/esh-proc.el (eshell-needs-pipe-p):
* lisp/eshell/esh-util.el (eshell-convert):
* lisp/eshell/esh-var.el (eshell-envvar-names):
* lisp/faces.el (x-resolve-font-name):
* lisp/ffap.el (ffap-file-at-point):
* lisp/files.el (wildcard-to-regexp, shell-quote-wildcard-pattern):
* lisp/forms.el (forms--update):
* lisp/frameset.el (frameset-filter-unshelve-param):
* lisp/gnus/gnus-art.el (article-decode-charset):
* lisp/gnus/gnus-kill.el (gnus-kill-parse-rn-kill-file):
* lisp/gnus/gnus-mlspl.el (gnus-group-split-fancy):
* lisp/gnus/gnus-msg.el (gnus-summary-resend-message-insert-gcc)
(gnus-inews-insert-gcc):
* lisp/gnus/gnus-rfc1843.el (rfc1843-decode-article-body):
* lisp/gnus/gnus-search.el (gnus-search-indexed-parse-output)
(gnus-search--complete-key-data):
* lisp/gnus/gnus-spec.el (gnus-parse-simple-format):
* lisp/gnus/gnus-sum.el (gnus-summary-refer-article):
* lisp/gnus/gnus-util.el (gnus-extract-address-components)
(gnus-newsgroup-directory-form):
* lisp/gnus/gnus-uu.el (gnus-uu-grab-view):
* lisp/gnus/gnus.el (gnus-group-native-p, gnus-short-group-name):
* lisp/gnus/message.el (message-check-news-header-syntax)
(message-make-message-id, message-user-mail-address)
(message-make-fqdn, message-get-reply-headers, message-followup):
* lisp/gnus/mm-decode.el (mm-dissect-buffer):
* lisp/gnus/nnheader.el (nnheader-insert):
* lisp/gnus/nnimap.el (nnimap-process-quirk)
(nnimap-imap-ranges-to-gnus-ranges):
* lisp/gnus/nnmaildir.el (nnmaildir--ensure-suffix):
* lisp/gnus/nnmairix.el (nnmairix-determine-original-group-from-path):
* lisp/gnus/nnrss.el (nnrss-match-macro):
* lisp/gnus/nntp.el (nntp-find-group-and-number):
* lisp/help-fns.el (help--symbol-completion-table-affixation):
* lisp/help.el (help-function-arglist):
* lisp/hippie-exp.el (he-concat-directory-file-name):
* lisp/htmlfontify.el (hfy-relstub):
* lisp/ido.el (ido-make-prompt, ido-complete, ido-copy-current-word)
(ido-exhibit):
* lisp/image/image-converter.el (image-convert-p):
* lisp/info-xref.el (info-xref-docstrings):
* lisp/info.el (Info-toc-build, Info-follow-reference)
(Info-backward-node, Info-finder-find-node)
(Info-speedbar-expand-node):
* lisp/international/mule-diag.el (print-fontset-element):
* lisp/language/korea-util.el (default-korean-keyboard):
* lisp/linum.el (linum-after-change):
* lisp/mail/ietf-drums.el (ietf-drums-parse-address):
* lisp/mail/mail-utils.el (mail-dont-reply-to):
* lisp/mail/rfc2047.el (rfc2047-encode-1, rfc2047-decode-string):
* lisp/mail/rfc2231.el (rfc2231-parse-string):
* lisp/mail/rmailkwd.el (rmail-set-label):
* lisp/mail/rmailsum.el (rmail-header-summary):
* lisp/mail/smtpmail.el (smtpmail-maybe-append-domain)
(smtpmail-user-mail-address):
* lisp/mail/uce.el (uce-reply-to-uce):
* lisp/man.el (Man-default-man-entry):
* lisp/mh-e/mh-alias.el (mh-alias-gecos-name)
(mh-alias-minibuffer-confirm-address):
* lisp/mh-e/mh-comp.el (mh-forwarded-letter-subject):
* lisp/mh-e/mh-speed.el (mh-speed-parse-flists-output):
* lisp/mh-e/mh-utils.el (mh-collect-folder-names-filter)
(mh-folder-completion-function):
* lisp/minibuffer.el (completion--make-envvar-table)
(completion-file-name-table, completion-flex-try-completion)
(completion-flex-all-completions):
* lisp/mpc.el (mpc--proc-quote-string, mpc-cmd-special-tag-p)
(mpc-constraints-tag-lookup):
* lisp/net/ange-ftp.el (ange-ftp-send-cmd)
(ange-ftp-allow-child-lookup):
* lisp/net/mailcap.el (mailcap-mime-types):
* lisp/net/mairix.el (mairix-search-thread-this-article):
* lisp/net/pop3.el (pop3-open-server):
* lisp/net/soap-client.el (soap-decode-xs-complex-type):
* lisp/net/socks.el (socks-filter):
* lisp/nxml/nxml-outln.el (nxml-highlighted-qname):
* lisp/nxml/rng-cmpct.el (rng-c-expand-name, rng-c-expand-datatype):
* lisp/nxml/rng-uri.el (rng-uri-file-name-1):
* lisp/obsolete/complete.el (partial-completion-mode)
(PC-do-completion):
* lisp/obsolete/longlines.el (longlines-encode-string):
* lisp/obsolete/nnir.el (nnir-compose-result):
* lisp/obsolete/terminal.el (te-quote-arg-for-sh):
* lisp/obsolete/tpu-edt.el (tpu-check-search-case):
* lisp/obsolete/url-ns.el (isPlainHostName):
* lisp/pcmpl-unix.el (pcomplete/scp):
* lisp/play/dunnet.el (dun-listify-string2, dun-get-path)
(dun-unix-parse, dun-doassign, dun-cat, dun-batch-unix-interface):
* lisp/progmodes/ebnf2ps.el: (ebnf-eps-header-footer-comment):
* lisp/progmodes/gdb-mi.el (gdb-var-delete)
(gdb-speedbar-expand-node, gdbmi-bnf-incomplete-record-result):
* lisp/progmodes/gud.el (gud-find-expr):
* lisp/progmodes/idlw-help.el (idlwave-do-context-help1):
* lisp/progmodes/idlw-shell.el (idlwave-shell-mode)
(idlwave-shell-filter-hidden-output, idlwave-shell-filter):
* lisp/progmodes/idlwave.el (idlwave-skip-label-or-case)
(idlwave-routine-info):
* lisp/progmodes/octave.el (inferior-octave-completion-at-point):
* lisp/progmodes/sh-script.el (sh-add-completer):
* lisp/progmodes/sql.el (defun):
* lisp/progmodes/xscheme.el (xscheme-process-filter):
* lisp/replace.el (query-replace-compile-replacement)
(map-query-replace-regexp):
* lisp/shell.el (shell--command-completion-data)
(shell-environment-variable-completion):
* lisp/simple.el (display-message-or-buffer):
* lisp/speedbar.el (speedbar-dired, speedbar-tag-file)
(speedbar-tag-expand):
* lisp/subr.el (split-string-and-unquote):
* lisp/tar-mode.el (tar-extract):
* lisp/term.el (term-command-hook, serial-read-name):
* lisp/textmodes/bibtex.el (bibtex-print-help-message):
* lisp/textmodes/ispell.el (ispell-lookup-words, ispell-filter)
(ispell-parse-output, ispell-buffer-local-parsing):
* lisp/textmodes/reftex-cite.el (reftex-do-citation):
* lisp/textmodes/reftex-parse.el (reftex-notice-new):
* lisp/textmodes/reftex-ref.el (reftex-show-entry):
* lisp/textmodes/reftex.el (reftex-compile-variables):
* lisp/textmodes/tex-mode.el (tex-send-command)
(tex-start-tex, tex-append):
* lisp/thingatpt.el (thing-at-point-url-at-point):
* lisp/tmm.el (tmm-add-one-shortcut):
* lisp/transient.el (transient-format-key):
* lisp/url/url-auth.el (url-basic-auth)
(url-digest-auth-directory-id-assoc):
* lisp/url/url-news.el (url-news):
* lisp/url/url-util.el (url-parse-query-string):
* lisp/vc/vc-cvs.el (vc-cvs-parse-entry):
* lisp/wid-browse.el (widget-browse-sexp):
* lisp/woman.el (woman-parse-colon-path, woman-mini-help)
(WoMan-getpage-in-background, woman-negative-vertical-space):
* lisp/xml.el:
* test/lisp/emacs-lisp/check-declare-tests.el
(check-declare-tests-warn):
* test/lisp/files-tests.el
(files-tests-file-name-non-special-dired-compress-handler):
* test/lisp/net/network-stream-tests.el (server-process-filter):
* test/src/coding-tests.el (ert-test-unibyte-buffer-dos-eol-decode):
Use `string-search` instead of `string-match` and `string-match-p`.
2021-08-09 11:35:56 +02:00
Lars Ingebrigtsen
9192f5d25b Make 's' in *Help* work for Lisp-defined variables again
* lisp/help-fns.el (describe-variable): Make the `s' command work
for Lisp-defined variables again (bug#39121).
2021-07-24 13:46:02 +02:00
Lars Ingebrigtsen
072512414e Make the `s' command in *Help* work for Lisp variables defined in C
* lisp/help-fns.el (describe-variable): Store the type.
* lisp/help-mode.el (help-view-source): Use the type.  This fixes
the problem when looking for a variable defined in a C file.
2021-07-19 18:35:12 +02:00
Lars Ingebrigtsen
620e35f09f Add a new function for separator lines
* lisp/help-fns.el (describe-symbol): Use it.

* lisp/help.el (describe-key): Use it.

* lisp/simple.el (separator-line): New face.
(make-separator-line): New function (bug#49630).
2021-07-19 15:48:20 +02:00
Ori
eaefa44acd ; * lisp/help-fns.el: Speed up `describe-mode'
* lisp/help-fns.el (help-fns--list-local-commands): Speed up (bug#49579).

A predicate checks if there are no key bindings for a given function. A
full list of bindings is not needed, even a single binding is sufficient
to say the function is bound. Set FIRSTONLY arg in where-is-internal so
this predicate runs faster, with functional equivalence. For some
configurations this has a noticeable improvement on the speed of
describe-mode.

Copyright-paperwork-exempt: yes
2021-07-15 18:57:38 +02:00
Lars Ingebrigtsen
22a5482ab6 Improve the shortdoc link action in *Help* buffers
* lisp/emacs-lisp/shortdoc.el (shortdoc-display-group): Allow
taking an optional parameter to place point on a specific function.
(shortdoc--display-function): Go to the function in question in
the shortdoc buffer.
2021-07-15 18:29:27 +02:00
Juri Linkov
fe1b72d216 * lisp/help-fns.el (help--symbol-class): Concat chars for all namespaces.
Since Emacs Lisp is more than Lisp-2, separately output letters
for each namespace: functions, variables, faces, classes.
Use non-letter characters for additional properties
such as advice, obsolete, local.
(help--symbol-completion-table-affixation): Use format "%-4s".
https://lists.gnu.org/archive/html/emacs-devel/2021-06/msg00524.html
2021-06-17 23:19:30 +03:00
Lars Ingebrigtsen
6fc48df5ae Add new convenience commands for *Help*
* doc/emacs/help.texi (Help Mode): Document it (bug#36767).

* lisp/help-fns.el (help-fns-function-description-header)
(describe-variable, describe-face, describe-keymap)
(describe-mode): Add the required data.

* lisp/help-mode.el (help-mode-map): Add 'i' and 's'.
(help-mode--current-data): New variable.
(help-mode): Make it local.
(help-view-source, help-goto-info): New commands.
2021-06-15 20:51:00 +02:00
Juri Linkov
d4ae640a37 * lisp/help-fns.el (help--symbol-class): New function.
Refactored from help--symbol-completion-table-affixation.
https://lists.gnu.org/archive/html/emacs-devel/2021-06/msg00066.html
2021-06-03 23:41:30 +03:00
Lars Ingebrigtsen
415ae812e9 Use buffer-local-boundp in describe-variable
* lisp/help-fns.el (describe-variable): Use `buffer-local-boundp'.
2021-05-31 07:22:12 +02:00
Daniel Mendler
db91108315 Speed up `describe-variable' completion predicate
* lisp/help-fns.el (describe-variable): Do not switch to the original
buffer in the predicate (bug#48738).
2021-05-31 06:49:37 +02:00
Lars Ingebrigtsen
c8ec798d70 Allow help-C-file-name to work on symbols designating subrs
* lisp/help-fns.el (help-C-file-name): Allow working on symbols
designating subrs (bug#14932).
2021-05-30 08:25:06 +02:00
Stefan Kangas
6c1c3204e4 Add new help command 'describe-command'
* lisp/help-fns.el (describe-command): New command.
(help-fns--describe-function-or-command-prompt): New helper
function to prompt for a function or function.  (Bug#46627)
(describe-function): Use above new helper function.

* lisp/help.el (help-map): Bind above new command to `C-h x'.
(help-for-help): Add this new command to the help summary.
* lisp/menu-bar.el (menu-bar-describe-menu): Add the new command to
the help menu.

* doc/emacs/help.texi (Help Summary, Name Help): Document
'describe-command', and update documentation on 'describe-function'.
* etc/tutorials/TUTORIAL: Change reference from 'describe-function' to
'describe-command'.
2021-05-02 15:04:00 +02:00
Andrea Corallo
82bd6d57d5 Merge remote-tracking branch 'savannah/master' into native-comp 2021-03-12 16:42:51 +01:00
Andrea Corallo
43b0df62cd Merge commit '9cbdf20316' into native-comp 2021-03-09 10:03:47 +01:00
Stefan Kangas
4a112fd7a6 Add new face 'help-key-binding' for keybindings in help
* lisp/faces.el (help-key-binding): New face.
* lisp/help.el
(help-for-help): Rename from 'help-for-help-internal'.  Use
'substitute-command-keys' syntax.
(help): Make into alias for 'help-for-help'.
(help-for-help-internal): Make into obsolete alias for
'help-for-help'.
(help--key-description-fontified): New function to add the
'help-key-binding' face.
(help-key-description, substitute-command-keys)
(describe-map-tree, help--describe-command)
(help--describe-translation, describe-map):
* lisp/help-fns.el (help-fns--key-bindings, describe-mode):
Use above new function.
* lisp/isearch.el (isearch-help-for-help-internal): Use
`substitute-command-keys' syntax.
* lisp/help-macro.el (make-help-screen): Use
'substitute-command-keys' and 'help--key-description-fontified'.
Simplify.
* src/keymap.c (describe_key_maybe_fontify): New function to add
the 'help-key-binding' face to keybindings.
(describe_vector): Use above new keybinding.
(syms_of_keymap) <Qfont_lock_face, Qhelp_key_binding>: New
DEFSYMs.
(fontify_key_properties): New static variable.
* lisp/tooltip.el (tooltip-show): Avoid overriding faces in
specified tooltip text.
* test/lisp/help-tests.el (with-substitute-command-keys-test):
Don't test for text properties.
(help-tests-substitute-command-keys/add-key-face)
(help-tests-substitute-command-keys/add-key-face-listing):
New tests.
2021-03-08 04:23:08 +01:00
Stephen Berman
57758dcbac Restrict the version guesser to top-level headings
* lisp/help-fns.el (help-fns--first-release): Restrict the version
guesser to top-level section -- looking in all headings leads to
false positives (bug#46889).
2021-03-05 14:08:17 +01:00
Andrea Corallo
5c922cc3a4 Merge remote-tracking branch 'savannah/master' into native-comp 2021-02-26 19:54:59 +01:00
Lars Ingebrigtsen
b0b4609be0 Remove the "Documentation:" line from the variable help
* lisp/help-fns.el (describe-variable): Remove the
"Documentation:" line (bug#46702).  This makes the help text more
compact and seems easier to read, too.
2021-02-24 17:58:38 +01:00
Lars Ingebrigtsen
77e194971c Buttonize function values in help (and add a blank line)
* lisp/help-fns.el (describe-variable): Add a newline for better
readability (bug#46702).  This also has the side effect of
buttonizing `function-references-like-this' in the "Its value is"
part.

* lisp/help-mode.el (help-make-xrefs): Adjust comments.
2021-02-22 22:34:22 +01:00
Andrea Corallo
f92bb788a0 Merge remote-tracking branch 'savannah/master' into native-comp 2021-02-17 22:26:28 +01:00
Lars Ingebrigtsen
4be98d5575 Fix problem with the newly introduces `minor-modes' variable
* lisp/help-fns.el (describe-mode): Apparently buffer-local
variables take precedence over lexically bound variables?
2021-02-14 14:43:24 +01:00
Lars Ingebrigtsen
98e3ee2747 Make `C-h m' list unbound commands applicable for the mode
* lisp/help-fns.el (help-fns--list-local-commands): New function.
(describe-mode): Use it.
2021-02-14 14:07:48 +01:00
Andrea Corallo
2fcb85c3e7 Merge remote-tracking branch 'savannah/master' into HEAD 2021-02-10 21:56:55 +01:00
Lars Ingebrigtsen
b12d22f6af Don't ask the user to make a bug report on missing arglists
* lisp/help-fns.el (help-fns--signature): Don't ask the user to
make a bug report (bug#30223) because the symbol may very well be
one that the user has defined themselves.
(help-fns-function-description-header): Ditto.
2021-02-04 12:08:46 +01:00
Andrea Corallo
b8d3ae78c5 Merge remote-tracking branch 'savannah/master' into native-comp 2021-01-24 21:05:33 +01:00
Juri Linkov
eec059b124 * lisp/help-fns.el: Move defvar keymap-name-history closer to where it's used. 2021-01-19 20:27:29 +02:00
James N. V. Cash
4e64d02356 Define keymap-name-history
* lisp/help-fns.el (keymap-name-history): Define the history
variable (bug#45879).  This avoids problems in other completing
systems like Helm.

Copyright-paperwork-exempt: yes
2021-01-19 07:07:37 +01:00
Andrea Corallo
0a7ac0b550 Merge remote-tracking branch 'savannah/master' into native-comp 2021-01-16 13:26:10 +01:00
Daniel Martín
e62f71988f Minor shortdoc link improvements
* lisp/emacs-lisp/shortdoc.el (shortdoc--display-function): Use
describe-function as a fallback link when a function is not documented
in any Info manual.  Also make the link respond to mouse-1, like the
rest of *Help* links, and add a proper help-echo property.
* lisp/help-fns.el (help-fns--mention-shortdoc-groups): Same link
improvement as described before, this time for the shortdoc groups
(bug#45750).
2021-01-10 13:45:44 +01:00
Andrea Corallo
5db5064395 Merge remote-tracking branch 'savannah/master' into HEAD 2021-01-02 10:11:15 +01:00
Paul Eggert
ba05d005e5 Update copyright year to 2021
Run "TZ=UTC0 admin/update-copyright".
2021-01-01 01:13:56 -08:00
Andrea Corallo
f244c21902 Merge remote-tracking branch 'savannah/master' into HEAD 2020-12-20 22:08:42 +01:00
Mattias Engdegård
46394dff7f Follow good regexp practice
These were found by relint 1.19.

* lisp/help-fns.el (help-fns--first-release): Use string-end instead
of line-end when matching a file name.
* lisp/org/ob-core.el (org-babel--string-to-number): Put hyphen last
in alternative.
* lisp/org/org-agenda.el (org-agenda-filter): Escape '+' correctly.
2020-12-18 14:35:09 +01:00
Andrea Corallo
0474fda62d Merge remote-tracking branch 'savannah/master' into HEAD 2020-12-12 15:31:33 +01:00
Stefan Kangas
c50c0a19e3 Prefer setq-local in most files
* lisp/apropos.el (apropos-print):
* lisp/buff-menu.el (Buffer-menu-mode):
* lisp/calc/calc.el (calc-trail-buffer):
* lisp/chistory.el (command-history-mode):
* lisp/dabbrev.el:
* lisp/dframe.el (dframe-frame-mode):
* lisp/doc-view.el (doc-view-presentation-mode):
* lisp/ebuff-menu.el (electric-buffer-menu-mode)
(electric-buffer-update-highlight):
* lisp/edmacro.el (edit-kbd-macro):
* lisp/face-remap.el (buffer-face-set, buffer-face-toggle):
* lisp/files.el:
(find-file-noselect-1, hack-local-variables-confirm)
(set-visited-file-name, revert-buffer--default):
* lisp/filesets.el (filesets-spawn-external-viewer):
* lisp/find-dired.el (find-dired):
* lisp/find-lisp.el (find-lisp-find-dired-internal):
* lisp/finder.el (finder-mode):
* lisp/font-core.el (font-lock-default-function):
* lisp/format.el (format-annotate-function):
* lisp/help-fns.el (describe-variable):
* lisp/help-mode.el (help-mode):
* lisp/icomplete.el (icomplete-minibuffer-setup)
(icomplete--in-region-setup):
* lisp/ido.el (ido-completion-help, ido-tidy):
* lisp/international/robin.el (robin-activate):
* lisp/leim/quail/hangul.el (hangul-input-method-activate):
* lisp/leim/quail/uni-input.el (ucs-input-activate):
* lisp/man.el (Man-mode):
* lisp/master.el (master-set-slave):
* lisp/minibuffer.el (minibuffer-completion-help)
(read-file-name-default):
* lisp/outline.el (outline-minor-mode):
* lisp/pcomplete.el (pcomplete-comint-setup):
* lisp/proced.el (proced-mode):
* lisp/recentf.el (recentf-edit-list, recentf-open-files-items):
* lisp/replace.el (occur-1):
* lisp/reveal.el (reveal-mode):
* lisp/ruler-mode.el (ruler--save-header-line-format):
* lisp/scroll-lock.el (scroll-lock-mode):
* lisp/startup.el (normal-top-level, normal-splash-screen):
* lisp/strokes.el (strokes-list-strokes):
* lisp/thumbs.el (thumbs-insert-image, thumbs-show-thumbs-list):
* lisp/tree-widget.el (tree-widget-set-theme):
* lisp/window.el (read-buffer-to-switch):
* lisp/xwidget.el (xwidget-webkit-begin-edit-textarea): Prefer
setq-local.
2020-12-09 11:58:38 +01:00
Andrea Corallo
6523b84015 Merge remote-tracking branch 'savannah/master' into HEAD 2020-11-29 15:11:38 +01:00
Juri Linkov
3b740591b0 Add 'completions-detailed' to add prefix/suffix with 'affixation-function'
* doc/lispref/minibuf.texi (Completion Variables)
(Programmed Completion): Add affixation-function.

* lisp/help-fns.el (help--symbol-completion-table-affixation): New function.
(help--symbol-completion-table): Set affixation-function when
completions-detailed is non-nil.

* lisp/minibuffer.el (completion-metadata): Add affixation-function
to docstring.
(completions-annotations): Inherit from shadow with italic.
(completions-detailed): New defcustom.
(completion--insert-strings): Count string-width on all strings in
completion list.  Insert prefix and suffix.
(completion-extra-properties): Add affixation-function to docstring.
(minibuffer-completion-help): Call affixation-function.
(minibuffer-default-prompt-format): Move down closer to its use.

https://lists.gnu.org/archive/html/emacs-devel/2020-11/msg00613.html
2020-11-25 10:46:59 +02:00
Andrea Corallo
f8505fd3d4 Merge remote-tracking branch 'savannah/master' into HEAD 2020-10-14 11:04:55 +02:00
Stefan Kangas
dcfed86cc6 ; * lisp/help-fns.el (help-fns-describe-function-functions): Fix typo. 2020-10-11 19:32:55 +02:00
Eli Zaretskii
4b84095d23 Improve documentation of shortdoc features
* lisp/help-fns.el (help-fns-describe-function-functions): Doc
fix.
* lisp/emacs-lisp/shortdoc.el (define-short-documentation-group)
(shortdoc-display-group, shortdoc-add-function): Doc fixes.

* doc/lispref/help.texi (Documentation Groups): Improve the
recently-added documentation and the indexing.
2020-10-11 17:28:40 +03:00
Lars Ingebrigtsen
2a7488d42d Add support for displaying short documentation for function groups
* doc/lispref/help.texi (Documentation Groups): Document it.

* lisp/help-fns.el (help-fns--mention-shortdoc-groups): Output
references to the shortdocs.

* lisp/emacs-lisp/shortdoc.el: New file.
2020-10-11 05:51:16 +02:00
Andrea Corallo
7268295868 * Fix function description message for native compiled lisp functions
* lisp/help-fns.el (help-fns-function-description-header): Fix
	message.
2020-10-04 19:44:15 +02:00
Andrea Corallo
a06fe08e8e Clean-up some now unnecessary diff against master
* lisp/emacs-lisp/autoload.el (update-directory-autoloads):
	.eln files have been moved so remove the '.eln' match.

	* lisp/emacs-lisp/bytecomp.el (byte-compile-refresh-preloaded):
	Likewise.

	* lisp/emacs-lisp/find-func.el (find-library-suffixes): Clean-up
	as '.eln' is no more in `load-suffixes'.

	* lisp/help-fns.el (find-lisp-object-file-name): Clean-up as
	`symbol-file' will return the '.elc' file.

	* src/lread.c (Fget_load_suffixes): Remove logic as '.eln' is not
	anymore in load-suffixes.
	(openp): Two spaces.
2020-09-29 10:05:39 +02:00
Andrea Corallo
06acf681d6 Merge remote-tracking branch 'savannah/master' into HEAD 2020-09-26 15:31:50 +02:00
Stefan Monnier
e7a69c9204 * lisp/help-fns.el (help-fns--first-release): Use etc/NEWS as well 2020-09-24 18:15:39 -04:00
Andrea Corallo
6a726c5ad7 Merge remote-tracking branch 'savannah/master' into HEAD 2020-09-13 18:20:21 +02:00
Lars Ingebrigtsen
9ca83cdd79 Revert "Use format-prompt in read-file-name calls that have a default"
This reverts commit de4f347901.

read-file-name already displays a long path when given a default
(like INITIAL in many other prompting functions), so using
format-prompt here is superfluous.
2020-09-13 14:58:24 +02:00
Andrea Corallo
a26b14733b Merge remote-tracking branch 'savannah/master' into HEAD 2020-09-10 10:45:02 +02:00
Lars Ingebrigtsen
de4f347901 Use format-prompt in read-file-name calls that have a default
* lisp/xwidget.el (xwidget-webkit-save-as-file):
* lisp/vc/vc.el (vc-backend-for-registration, vc-delete-file)
(vc-rename-file):
* lisp/vc/ediff-ptch.el (ediff-prompt-for-patch-file):
* lisp/vc/diff-mode.el (diff-tell-file-name):
* lisp/progmodes/etags.el (visit-tags-table)
(visit-tags-table-buffer):
* lisp/misearch.el (multi-isearch-read-files):
* lisp/mail/rmailmm.el (rmail-mime-save):
* lisp/help-fns.el (doc-file-to-man, doc-file-to-info):
* lisp/gnus/gnus-bookmark.el (gnus-bookmark-load):
* lisp/files.el (write-file, basic-save-buffer):
* lisp/dired.el (dired-read-dir-and-switches):
* lisp/bookmark.el (bookmark-save, bookmark-load):
* lisp/abbrev.el (write-abbrev-file, abbrev-edit-save-to-file):
Use format-prompt in read-file-name calls that have a default.
2020-09-07 22:10:06 +02:00