1
Fork 0
mirror of git://git.sv.gnu.org/emacs.git synced 2026-01-21 03:52:16 -08:00
emacs/lisp/textmodes
Basil L. Contovounesios 0185d76e74 Fix and extend format-spec (bug#41758)
* lisp/format-spec.el: Use lexical-binding.  Remove dependence on
subr-x.el.
(format-spec-make): Clarify docstring.
(format-spec--parse-modifiers): Rename to...
(format-spec--parse-flags): ...this and simplify.  In particular,
don't bother parsing :space-pad which is redundant and unused.
(format-spec--pad): Remove, replacing with...
(format-spec--do-flags): ...this new helper function which performs
more of format-spec's supported text manipulation.
(format-spec): Autoload.  Allow optional argument to take on special
values 'ignore' and 'delete' for more control over what happens when
a replacement for a format specification isn't provided.  Bring back
proper support for a precision modifier similar to that of 'format'.

* lisp/battery.el (battery-format): Rewrite in terms of format-spec.
(battery-echo-area-format, battery-mode-line-format): Mention
support of format-spec syntax in docstrings.

* doc/lispref/strings.texi (Custom Format Strings):
* etc/NEWS: Document and announce these changes.

* lisp/dired-aux.el (dired-do-compress-to):
* lisp/erc/erc-match.el (erc-log-matches):
* lisp/erc/erc.el (erc-update-mode-line-buffer):
* lisp/gnus/gnus-sieve.el (gnus-sieve-update):
* lisp/gnus/gssapi.el (open-gssapi-stream):
* lisp/gnus/mail-source.el (mail-source-fetch-file)
(mail-source-fetch-directory, mail-source-fetch-pop)
(mail-source-fetch-imap):
* lisp/gnus/message.el (message-insert-formatted-citation-line):
* lisp/image-dired.el:
* lisp/net/eww.el:
* lisp/net/imap.el (imap-kerberos4-open, imap-gssapi-open)
(imap-shell-open):
* lisp/net/network-stream.el (network-stream-open-shell):
* lisp/obsolete/tls.el (open-tls-stream):
* lisp/textmodes/tex-mode.el:
Remove extraneous loads and autoloads of format-spec now that it is
autoloaded and simplify its uses where possible.

* test/lisp/battery-tests.el (battery-format): Test new format-spec
support.
* test/lisp/format-spec-tests.el (test-format-spec): Rename to...
(format-spec) ...this, extending test cases.
(test-format-unknown): Rename to...
(format-spec-unknown): ...this, extending test cases.
(test-format-modifiers): Rename to...
(format-spec-flags): ...this.
(format-spec-make, format-spec-parse-flags, format-spec-do-flags)
(format-spec-do-flags-truncate, format-spec-do-flags-pad)
(format-spec-do-flags-chop, format-spec-do-flags-case): New tests.
2020-06-18 12:46:21 +01:00
..
artist.el
bib-mode.el
bibtex-style.el
bibtex.el * lisp/textmodes/bibtex.el: Fix bug#41285 (paren typo) 2020-05-16 09:08:27 -04:00
conf-mode.el * lisp/textmodes/conf-mode.el (conf-mode): Fix last change 2020-03-25 14:09:48 -04:00
css-mode.el Improved light/dark colour predicate (bug#41544) 2020-06-10 20:11:13 +02:00
dns-mode.el dns-mode-soa-auto-increment-serial: safe if symbolp 2020-01-27 21:35:17 -08:00
enriched.el
fill.el * lisp/textmodes/fill.el (fill-nobreak-predicate): Fix documentation. 2020-03-14 11:25:57 +01:00
flyspell.el
ispell.el ; Fix some typos and doc issues (bug#40695) 2020-04-18 17:10:02 +02:00
less-css-mode.el
makeinfo.el
mhtml-mode.el Remove mhtml--extend-font-lock-region (Bug#41441) 2020-05-31 10:21:38 -06:00
nroff-mode.el * lisp/textmodes/nroff-mode.el (nroff-mode-map): Remove key 'M-s' (bug#39706) 2020-02-25 02:38:33 +02:00
page-ext.el
page.el
paragraphs.el Merge from origin/emacs-27 2020-01-24 07:50:22 -08:00
picture.el
po.el Use lexical-binding in po.el and add tests 2020-04-25 09:12:24 +02:00
refbib.el
refer.el Fix edge case errors in filename-matching regexps 2020-04-14 12:25:16 +02:00
refill.el
reftex-auc.el
reftex-cite.el
reftex-dcr.el
reftex-global.el
reftex-index.el
reftex-parse.el
reftex-ref.el
reftex-sel.el
reftex-toc.el
reftex-vars.el Remove subsumed repetitions in regexps 2020-02-20 16:05:18 +01:00
reftex.el Remove (or double) redundant backslashes in string literals 2020-01-24 23:04:34 +01:00
remember.el Declare some <package>-version variables obsolete 2020-03-21 02:49:25 +01:00
rst.el
sgml-mode.el Prefer 'strong' and 'em' to 'b' and 'i' in html-mode 2020-05-06 03:30:20 +02:00
table.el Merge from origin/emacs-27 2020-03-07 07:50:28 -08:00
tex-mode.el Fix and extend format-spec (bug#41758) 2020-06-18 12:46:21 +01:00
texinfmt.el
texinfo.el Update texinfo.el following changes in 'tex-start-options-string' 2020-04-03 15:12:47 +03:00
texnfo-upd.el
text-mode.el
tildify.el
two-column.el
underline.el