1
1
Граф коммитов

6357 Коммитов

Автор SHA1 Сообщение Дата
Benno Schulenberg
b7166d5c06 po: update translations and regenerate POT file and PO files 2017-04-12 10:19:50 +02:00
Benno Schulenberg
1e8f6fd7a9 bump version numbers and add a news item for the 2.8.1 release 2017-04-12 10:11:45 +02:00
Benno Schulenberg
0b93fff802 docs: correct an answer to a question in the FAQ 2017-04-11 21:10:07 +02:00
Benno Schulenberg
1c74517629 docs: remove the self-referencing stuff and the changelog from the FAQ
Furthermore, change an item header into a question, swap two items,
and tweak the formatting a bit.
2017-04-11 20:41:17 +02:00
Benno Schulenberg
9f696ef9af copyright: update the year in --version, and use the standard hyphen 2017-04-11 13:57:29 +02:00
Benno Schulenberg
5aa12a2b3d tweaks: group ^D and ^H together in the help lines
This also groups ^I and ^M together, and cutwordleft and cutwordright
(when they are bound).  It furthermore makes that less pairs are now
mixed and instead consist of either two Ctrl or two Meta combos.  In
short: it looks better in the default config.  The only sacrifice is
that Verbatim is now split off from the other "inserting" keys.
2017-04-11 13:23:43 +02:00
Benno Schulenberg
2439e1e451 linting: treat a tab as one "column", not eight
This fixes https://savannah.gnu.org/bugs/?47131.
2017-04-10 20:32:36 +02:00
Benno Schulenberg
dab70d06ed linting: when no is said to a file, remove all corresponding entries
When the user chooses not to open a file that some message refers to,
remove all messages for that file from the linting results, so the user
does not get asked about that same file again.

This fixes https://savannah.gnu.org/bugs/?47130.
2017-04-10 19:55:46 +02:00
Benno Schulenberg
8993c36366 tweaks: reduce the number of additions that actual_x() performs
Replace them by a single subtraction.
2017-04-10 19:25:40 +02:00
David Lawrence Ramsey
5c51d4ea46 tweaks: avoid a compilation warning 2017-04-10 16:26:52 +02:00
David Lawrence Ramsey
02376103eb bindings: use arrows instead of words for search history too
When UTF-8 is available, use actual arrows instead of untranslated words
to indicate the cursor keys in the search history, as is done elsewhere.
2017-04-10 16:19:37 +02:00
Benno Schulenberg
999d99c6e4 tweaks: delete a function that hasn't been used since 2005 2017-04-09 13:33:25 +02:00
Benno Schulenberg
6e73805a0d tweaks: delete unnecessary function prototypes
These functions are used only in the file in which they are declared,
and they are declared before they are used.
2017-04-09 13:28:27 +02:00
Benno Schulenberg
754c62c5cc copyright: update the years, use ranges, and explain this usage
The interval 2013-2017 for the Free Software Foundation is valid
because in those years there were releases with changes by either
Chris or David, and the GNU maintainers guide advises to mention
a new year in all files of a package, not just in the ones that
actually changed, and be done with it for the rest of the year.
2017-04-09 12:09:23 +02:00
Benno Schulenberg
9f2c80db24 moving: when determining where we are on the screen, use placewewant
To make dynamic Home and End work properly when double-width characters
straddle a chunk boundary, use the spot where the cursor is really shown
instead of the "actual x" position of the current character, because the
latter might be on the preceding row.

This fixes https://savannah.gnu.org/bugs/?50737.
2017-04-09 11:36:39 +02:00
Benno Schulenberg
4c987bc3e0 tweaks: adjust a couple of comments 2017-04-07 21:40:33 +02:00
Benno Schulenberg
e75c933cb0 tweaks: fix two typos in the NEWS file
Also, use single quotes for rcfile options more consistently.
2017-04-07 21:23:00 +02:00
Benno Schulenberg
28767d8fec tweaks: fix some inconsistencies in an old Changelog 2017-04-07 21:22:55 +02:00
Benno Schulenberg
bf00e3f606 tweaks: put M-A before ^6, to look better above M-6 in the help lines
Also, M-A is far more mnemonic for setting the mark than ^6 or ^^,
so it's better to try and teach the user that.
2017-04-07 20:07:37 +02:00
David Lawrence Ramsey
23ae7bfbbf input: support escape sequences for ^Home and ^End
Make nano recognize the escape sequences for Ctrl-Home, Ctrl-End,
Shift-Ctrl-Home, and Shift-Ctrl-End on xterm, rxvt, and Eterm.
2017-04-06 21:25:41 +02:00
Benno Schulenberg
cb0806b2a0 bindings: make ^Home and ^End go to top and tail of buffer
On some terminal emulators, Ctrl+Home and Ctrl+End produce special
keycodes, distinct from plain Home and End.  Make the users of those
emulators (and of the Linux console) glad by making ^Home and ^End
do the obvious thing, and the combinations with Shift too.
2017-04-06 21:19:00 +02:00
Benno Schulenberg
005ee8eda6 editing: avoid creating blank lines when using autoindent
When Enter is pressed while the cursor is exactly on the current
indent width, remove the blank characters on that line to avoid
creating a line that consists only of trailing whitespace.

(When Enter is pressed somewhere in the middle of the blanks,
however, the whitespace is preserved.)

Suggested-by: Florian Zeitz <florob@babelmonkeys.de>
2017-04-06 20:34:04 +02:00
Benno Schulenberg
f3e2ad945d display: with softwrap, show the cursor where the eye expects it
When a multi-column character straddles a chunk boundary, and the
preferred column (placewewant) for the cursor is zero, cheat: show
the cursor not where the character starts but on the beginning of
the next row.  This makes the cursor move smoothly in the leftmost
column of the screen when using <Up> and <Down> and such, instead
of jumping around.

In this way the scrolling logic won't get confused and the screen
will scroll properly when stepping beyond the top or bottom row.

This fixes https://savannah.gnu.org/bugs/?50687.
2017-04-06 19:51:07 +02:00
Benno Schulenberg
6ec65d5500 display: check the correct character for being double-width
This fixes https://savannah.gnu.org/bugs/?50741.
2017-04-06 17:39:58 +02:00
Benno Schulenberg
de0adb8e3e tweaks: keep the help text aligned, also with the narrow arrows 2017-04-05 18:02:03 +02:00
Mike Frysinger
cc91ee603c configure: ignore the REG_ENHANCED test when we use gnulib
If we're using the bundled gnulib regex module, then assume REG_ENHANCED
is not supported (since gnulib doesn't support it).

This fixes https://savannah.gnu.org/bugs/?50714.
2017-04-04 21:21:37 +02:00
Benno Schulenberg
c84324bc7a gnulib: update to current state 2017-04-04 21:11:31 +02:00
Benno Schulenberg
8fc72eb32b bindings: use arrows instead of words to designate the cursor keys
When UTF-8 is available, use actual arrows instead of untranslated words
to indicate the cursor keys.  This was already done for the combinations
with Ctrl but not yet for the plain cursor keys.
2017-04-04 20:53:08 +02:00
Benno Schulenberg
6b5aff4878 tweaks: put unshifted shortcuts ^6 and M-6 first, instead of ^^ and M-^
The unshifted shortcuts are easier to type, and also less confusing in
my eyes.  Putting them first means they get shown in the help lines,
and get listed first in the ^G help text.

(I would also like to put ^- first instead of ^_ (because the latter
is hard to see when using the default inverse video for shortcuts),
but on several terminal emulators Ctrl+- reduces the font size.)
2017-04-04 20:41:09 +02:00
Benno Schulenberg
fb534bada6 bindings: make ^Up/^Down go to first/last row in the file browser
Making ^Up and ^Down go to top and bottom row in the file browser
complements and completes the behavior of ^Left and ^Right.
2017-04-04 20:26:21 +02:00
Benno Schulenberg
b5bc1b5094 tweaks: again use memory on the stack instead of malloc() and free()
Also, don't bother copying the found bracket -- just compare it in situ
and thus elide a variable.
2017-04-04 19:20:33 +02:00
Benno Schulenberg
aedc3ddd49 tweaks: replace a function call or a macro with a hard number
Verify at startup that the number is not too small.
2017-04-04 19:17:02 +02:00
Benno Schulenberg
754aa8ba79 tweaks: elide a variable and a pair of braces 2017-04-04 19:15:15 +02:00
Benno Schulenberg
53cea142e0 tweaks: use memory on the stack instead of calling malloc() and free()
Rename some variables in the process, and remove two cluttering asserts.
2017-04-04 19:14:14 +02:00
Benno Schulenberg
7e18100197 tweaks: close the backup file also when we skip making a backup
(We still leak the backupname in that case, but I can't be bothered
with that now.)

Also elide a variable, trim some comments, and rewrap some lines.
2017-04-04 12:50:49 +02:00
Benno Schulenberg
0abf225129 files: check also for write errors when prepending, not just read errors 2017-04-04 12:21:43 +02:00
Kamil Dudka
70bcf752dc backup: prevent a symlink attack by operating on the file descriptor
Use futimens() instead of utime() to change the timestamps on a backup
file.  Otherwise, a non-privileged user could create an arbitrary symlink
with the name of the backup file and in this way fool a privileged user
to call utime() on the attacker-chosen file.

Import the relevant gnulib module to make sure futimens() is available.
2017-04-04 11:28:01 +02:00
Mike Frysinger
8f2b5bbf3d configure: fix up word boundary regex logic now that we have gnulib
If we're using the bundled gnulib regex module, then assume word boundary
support is available to avoid issues with the regcomp test.  This also
unifies the different code paths a bit.

This fixes https://savannah.gnu.org/bugs/?50705.
2017-04-04 11:08:58 +02:00
David Lawrence Ramsey
f9a8d6ff4e scrolling: properly compensate for the onscreen chunks
If edittop is partially offscreen before we scroll, and it gets
scrolled more offscreen, we do need to compensate for the chunks
between firstcolumn and leftedge -- that is: the chunks between
the top row and the cursor row.

This fixes https://savannah.gnu.org/bugs/?50691.
2017-04-04 10:55:24 +02:00
David Lawrence Ramsey
c3830517cc display: show '<' and '>' placeholders for characters that get split
When a two-column character cannot be shown because it straddles the
boundary between two chunks of a line, show the '>' placeholder for
its left "half", and '<' for its right "half".

This mitigates https://savannah.gnu.org/bugs/?49440.
2017-04-03 21:51:46 +02:00
Benno Schulenberg
6d70ab11d6 docs: mention another difference with Pico in the Info document 2017-04-02 13:26:53 +02:00
Benno Schulenberg
5f359179b2 docs: trim the TODO file a bit, and put the more important items first
Remove some things we're never going to do: allowing to replace
newlines, a regression framework, characterset conversions, or
jumping to various screen lines.
2017-04-02 13:09:52 +02:00
Benno Schulenberg
be62368d54 po: update translations and regenerate POT file and PO files 2017-03-31 11:07:01 +02:00
Benno Schulenberg
032030566c bump version numbers and add a news item for the 2.8.0 release 2017-03-31 10:54:55 +02:00
Benno Schulenberg
bc9862fbff tweaks: condense some declarations by reshuffling 2017-03-29 21:35:56 +02:00
Benno Schulenberg
582a624998 tweaks: frob some parentheses and other things, to be more consistent 2017-03-29 19:30:37 +02:00
Benno Schulenberg
c7282e8821 tweaks: reshuffle two declarations for a more consistent order 2017-03-29 10:35:11 +02:00
Benno Schulenberg
1f9a6ab336 tweaks: factor out a bit of common code 2017-03-29 10:30:41 +02:00
Benno Schulenberg
33cefa9208 tweaks: elide an intermediate variable 2017-03-29 10:20:41 +02:00
Benno Schulenberg
873e3d6fa6 tweaks: don't loop over an initializer 2017-03-29 10:13:08 +02:00