Benno Schulenberg
8536b4bfcb
tweaks: prevent some color keywords from getting hyphenated in man page
2025-02-14 16:50:16 +01:00
Benno Schulenberg
0694c616a2
syntax: man: highlight some escapes, like \& and \(em, specially
...
This helps prevent reading things like \e and \(em as text.
2025-02-14 16:42:45 +01:00
Benno Schulenberg
8e456bab9f
docs: use proper emdashes instead of double hyphens: "--" => "\(em"
...
Also, remove redundant double quotes, protect single quotes from
possibly getting misinterpreted, and protect periods from getting
treated as end-of-sentence. Also, use \e instead of \\.
(Overlong lines are left alone -- they don't bother me.)
This partially addresses https://bugs.debian.org/1095957 .
Reported-by: Bjarni Ingi Gislason <bjarniig@simnet.is >
2025-02-14 16:29:13 +01:00
Benno Schulenberg
aa663ae386
tweaks: consistently use "\fR" for switching back to normal, roman font
2025-02-12 09:34:29 +01:00
Benno Schulenberg
01c8ffd61f
tweaks: avoid running tolower() on an out-of-range value
...
Functions like tolower() expect characters in the range -1..255.
Reference: https://savannah.gnu.org/bugs/?50289 .
The other occurrences of toupper(), tolower(), and isxdigit() that
don't do a cast are fine, because the values of 'code' or 'keycode'
are already guaranteed to be in range by the surrounding code.
2025-02-12 09:34:06 +01:00
Benno Schulenberg
58c7358cb3
tweaks: change the man-page markup of options that take an argument
...
This is an attempt to work around a bug in the Debian HTML-renderer of
manual pages: see how after "-C" everything is in italics [1], instead
of just the "directory" arguments. (The renderer for Arch Linux does
even worse, showing the first argument in bold italics [2].)
The old markup was fine, though, as `groff` had no problem generating
properly formatted HTML [3].
[1] https://manpages.debian.org/bookworm/nano/nano.1.en.html
[2] https://man.archlinux.org/man/nano.1.en
[3] https://nano-editor.org/dist/v7/nano.1.html
2025-02-10 16:34:15 +01:00
Benno Schulenberg
1a150bf544
syntax: po: colorize also the %llu and %hhi format specifiers
...
And colorize %% only by itself, not combined with anything.
2025-02-10 11:04:06 +01:00
Benno Schulenberg
98bab0db07
docs: improve the description of the constantshow bindable function
...
And of the '--constantshow' and 'set constantshow' options.
2025-01-20 15:25:40 +01:00
Brand Huntsman
b9c65193af
files: improve the wording of the normal file-writing prompts
...
Make them similar to the prompts for writing out a selection.
Signed-off-by: Brand Huntsman <alpha@qzx.com >
(The change was first proposed seven years ago as part of a patch set:
https://lists.gnu.org/archive/html/nano-devel/2018-02/msg00144.html ,
then reposted by myself:
https://lists.gnu.org/archive/html/nano-devel/2018-02/msg00147.html ,
and then... forgotten.)
2025-01-17 11:11:04 +01:00
Benno Schulenberg
20403ef8bb
copyright: update the years for the FSF
2025-01-14 11:00:11 +01:00
Benno Schulenberg
e26cdd3dab
tweaks: remove three redundant pairs of parentheses from a nanorc regex
2025-01-12 12:32:27 +01:00
Benno Schulenberg
2065713e5c
docs: replace a word that is better not used in the plural
...
Noted by https://fossies.org/linux/misc/nano-8.3.tar.xz/codespell.html .
2024-12-24 17:14:23 +01:00
Benno Schulenberg
a9cf841042
po: update translations and regenerate POT file and PO files
2024-12-21 11:55:15 +01:00
Benno Schulenberg
46466530a5
bump version numbers and add a news item for the 8.3 release
2024-12-21 11:23:05 +01:00
Benno Schulenberg
94ed548366
gnulib: update to its current upstream state
2024-12-20 12:15:44 +01:00
Benno Schulenberg
1e4c69baa7
tweaks: adjust another translator hint, and add two more
...
The "Prev Line"/"Next Line" tags are shown in the help viewer,
so on an 80-column terminal they may be only 10 cells wide.
2024-12-16 11:16:10 +01:00
Benno Schulenberg
f04c1a6ab5
syntax: markdown: accept also digit 0 in a list marker
...
For ordered lists, 10., 20., 30., ... were not getting colorized.
Also, https://daringfireball.net/projects/markdown/dingus
accepts 0. by itself just fine as marker.
This addresses https://savannah.gnu.org/patch/?10492 .
2024-12-15 11:39:06 +01:00
Benno Schulenberg
6393edf40a
tweaks: add a small clarifying comment
2024-12-11 17:12:50 +01:00
Lukáš Zaoral
7fd38e88c1
memory: avoid a leak when linter aborts after producing parsable output
...
Any collected messages should be freed also after an
abnormal exit of the linter.
Buglet existed since version 2.4.1, commit f225991b .
2024-12-11 08:22:17 +01:00
Benno Schulenberg
ee66c13487
tweaks: adjust a translator hint, and add another one
...
For the affected four "tags" only 10 character cells are available
(on an 80-column terminal) since they are used in the help viewer.
For the other two "tags" 15 cells are available, as they are shown
only when the terminal is at least 380 columns wide.
Indirectly-reported-by: Rafael Fontenelle <rafaelff@gnome.org >
2024-11-24 17:41:04 +01:00
Benno Schulenberg
250192c603
tweaks: drop six unneeded casts
...
The cast is implied by the type of the assignee.
2024-11-24 17:41:02 +01:00
Benno Schulenberg
9d181a1cc6
build: fix a compilation error with gcc-15
...
Assigning a pointer to a boolean variable without a cast
is not accepted any more.
This addresses https://savannah.gnu.org/bugs/?66467 .
Reported-by: Rudi Heitbaum <rudi@heitbaum.com >
2024-11-20 13:06:22 +01:00
LIU Hao
07a92c3988
syntax: asm: add end-of-word anchors to the keywords
...
Previously some of these regexes could color part of a directive;
for example, the `.int` part of `.intel_syntax`.
Signed-off-by: LIU Hao <lh_mouse@126.com >
2024-11-05 17:12:25 +01:00
Benno Schulenberg
e9b0a57490
docs: put a space after "|" and before "{enter}" in the sample nanorc
...
This makes the example bindings slightly more legible.
Also improve a comment.
2024-11-04 16:22:07 +01:00
Benno Schulenberg
2fca581095
syntax: groff: correct the mistaken .rof extension to .roff
...
Buglet existed since version 2.9.8, commit cdd637d6 .
2024-10-23 11:14:48 +02:00
Benno Schulenberg
53afd90ad4
syntax: groff: recognize also the .mom extension
...
This addresses https://savannah.gnu.org/bugs/?66369 .
Reported-by: Elfener <elfenermarcell@gmail.com >
2024-10-23 11:07:05 +02:00
Benno Schulenberg
d9ea07515b
docs: clarify the possible effects of a misuse of braced function names
...
And fix a nearby grammatical mistake that was
caused by commit 77a8841d from four months ago.
Inspired-by: Max Gammache <bigjango13@gmail.com >
2024-10-20 17:19:27 +02:00
Benno Schulenberg
de82920819
docs: add Shift+PgUp/PgDown to the FAQ item about urxvt modified keys
...
So that those keystrokes will select text per screenful also on urxvt.
Inspired-by: Sébastien Desreux <seb@h-k.fr >
2024-10-12 12:57:15 +02:00
Benno Schulenberg
9a842e4bf2
tweaks: add a translator hint
...
This should help translators to avoid mistakenly interpreting
"Home" and "End" as names of keys.
2024-10-11 11:59:01 +02:00
Benno Schulenberg
1862995aab
syntax: spec: colorize all canonical architecture names
...
The list of canonical names was found in:
https://github.com/rpm-software-management/rpm/blob/master/rpmrc.in
The canonical names were extracted with:
grep arch_canon rpmrc.in | sed 's/^.*:\s*//' | sed 's/\s*..\?$//'
and then sorted and condensed into a regular expression.
Inspired-by: Funda Wang <fundawang@gmail.com >
2024-09-22 12:34:28 +02:00
Benno Schulenberg
468613c9db
syntax: makefile: colorize also multiple targets
...
Multiple targets are separated by spaces. Furthermore, there
may be spaces before the first target and before the colon.
2024-09-06 13:56:56 +02:00
Benno Schulenberg
28642cd047
po: update translations and regenerate POT file and PO files
2024-09-05 11:41:30 +02:00
Benno Schulenberg
f96f3546c7
bump version numbers and add a news item for the 8.2 release
2024-09-05 09:18:12 +02:00
Benno Schulenberg
205066ed12
gnulib: update to its current upstream state
2024-09-04 14:52:27 +02:00
Benno Schulenberg
7e8ee46c09
syntax: autoconf: colorize the keywords 'case', 'esac', and 'ifelse' too
...
Case statements occur a lot in gnulib's m4 files,
and 'ifelse' is simply part of the m4 language.
2024-08-28 17:12:17 +02:00
Collin Funk
d1e2febb6d
build: update a symbol that was renamed in gnulib
...
As noted in a gnulib NEWS item of 2023-01-07, linking now happens
against $(CLOCK_TIME_LIB) instead of $(LIB_CLOCK_GETTIME).
2024-08-27 10:20:56 +02:00
Benno Schulenberg
3d0273de45
tweaks: improve or rewrap six comments, and add two missing ones
...
Also, stop initializing three variables that don't need it.
2024-08-17 10:37:41 +02:00
Benno Schulenberg
109386dfe8
syntax: nanorc: an unquoted argument of 'include' may not contain blanks
...
Anything after the first "word" after 'include' will be ignored
and should thus remain colorized in bright red.
2024-08-16 15:49:28 +02:00
Benno Schulenberg
ebddb49041
docs: do not quote the argument of 'include' statements in sample nanorc
...
This avoids those arguments getting colorized as if they were regexes
(when the relevant lines are uncommented), and instead allows them to
get colorized in bold purple by a dedicated rule.
2024-08-16 15:42:37 +02:00
Benno Schulenberg
b5f320a2f9
tweaks: delete three redundant checks from the undo/redo code
...
Since commit 50954a4b from two years ago, a replacing session will
not ever change the final empty line, and thus a fresh magic line
will never need to be undone or redone.
This complements commit c6a26641 from five months ago.
2024-08-12 08:41:58 +02:00
Benno Schulenberg
7568bd9af5
docs: trim stuff that is more than four years old from the changelog
...
A detailed list of changes is useful for just a small number of users,
and only when the changes are fairly recent.
2024-08-12 08:39:57 +02:00
Benno Schulenberg
0384c251ff
docs: mention former maintainership last among an author's contributions
2024-08-10 17:36:31 +02:00
Benno Schulenberg
b812ad2926
tweaks: unwrap three lines that don't need to be wrapped
...
(These lines were noticed while checking that all
calls of nrealloc() use a size bigger than zero.)
2024-08-04 16:09:42 +02:00
Benno Schulenberg
fe0b928b39
tweaks: move a condition to the only place that needs it
...
Most calls of draw_all_subwindows() are made while in the edit window.
The only call that could occur while in the file browser is the one in
regenerate_screen(). So only this call needs to be guarded against
being made while the file list is being shown.
2024-07-31 10:04:00 +02:00
Benno Schulenberg
4b1a81e773
docs: mention the availability of ^Y, ^N, and ^A at a Yes-No prompt
2024-07-28 13:55:31 +02:00
Benno Schulenberg
af2f218192
bindings: at a Yes-No-All prompt, accept also ^A for "All"
...
This can be useful when replacing text in a Japanese locale,
avoiding the need to guide the input method to produce "A".
Inspired-by: Takeshi Hamasaki <hmatrjp@users.sourceforge.jp >
2024-07-28 13:54:41 +02:00
Benno Schulenberg
572247dbd8
tweaks: reshuffle a seldom-used function to the end of an if-else series
2024-07-22 15:43:37 +02:00
Benno Schulenberg
c5a0e6b60c
syntax: awk: colorize escape sequences specially
2024-07-21 14:32:56 +02:00
Benno Schulenberg
d7e8665782
syntax: awk: rewrite a regex more densely, and add the missing ~ operator
...
Also, improve the comment.
2024-07-18 16:14:25 +02:00
Benno Schulenberg
7c86c1a185
syntax: awk: add a missing "|" between "\?" and ":"
...
The "\?" and ":" are meant to match the ? and : in this construct:
condition ? thenthis : otherwisethis
The missing "|" seems to have been a typo.
2024-07-18 13:02:54 +02:00