Benno Schulenberg
ebbe546033
screen: again, look at the bytes in their context
...
This avoids having to null-terminate every single-byte character.
2016-06-30 14:28:29 +02:00
Benno Schulenberg
cf0eed6c36
screen: don't check for every character whether there is still enough space
...
Just allocate ample space up front and thus discard the delaying 'if' for
each and every character. In most cases this will allocate far too much,
but that hardly matters: it is freed again as soon as the line is printed.
2016-06-30 14:27:00 +02:00
Benno Schulenberg
feacacc46d
chars: look at bytes in their context, so only valid sequences are accepted
...
This fixes https://savannah.gnu.org/bugs/?48125 .
(The fix is slightly wasteful; speeding things up will follow later.)
2016-06-29 20:56:50 +02:00
Benno Schulenberg
af53c56ec8
chars: speed up the determination whether something is a control character
...
Use knowledge of UTF-8 instead of converting to wide characters first.
2016-06-29 20:56:50 +02:00
Benno Schulenberg
019d7b34ca
chars: delete a now-unused function
2016-06-29 20:56:50 +02:00
Benno Schulenberg
622995fb12
chars: the representation of a control character is always two bytes
...
Any control character is represented by a ^ plus an ASCII character.
2016-06-29 20:56:50 +02:00
Benno Schulenberg
03586c60da
chars: represent the high-bit controls more intelligibly
...
Instead of showing the upper control codes like this:
^À ^Á ^Â ^Ã ^Ä ^Å ^Æ ^Ç ^È ^É ^Ê ^Ë ^Ì ^Í ^Î ^Ï
^Ð ^Ñ ^Ò ^Ó ^Ô ^Õ ^Ö ^× ^Ø ^Ù ^Ú ^Û ^Ü ^Ý ^Þ ^ß
show them like this:
^` ^a ^b ^c ^d ^e ^f ^g ^h ^i ^j ^k ^l ^m ^n ^o
^p ^q ^r ^s ^t ^u ^v ^w ^x ^y ^z ^{ ^| ^} ^~ ^=
The lower control codes continue to be shown like this:
^@ ^A ^B ^C ^D ^E ^F ^G ^H ^I ^J ^K ^L ^M ^N ^O
^P ^Q ^R ^S ^T ^U ^V ^W ^X ^Y ^Z ^[ ^\ ^] ^^ ^_
The representation of DEL (0x7F) continues as ^?.
Further, use knowledge of UTF-8 to avoid a roundtrip through
wide characters.
2016-06-29 20:56:50 +02:00
Benno Schulenberg
07a39e8e18
screen: don't simulate a sigwinch but directly reinitialize the screen
...
This fixes the second part of https://savannah.gnu.org/bugs/?48331 .
Reported-by: Mike Frysinger <vapier@gentoo.org>
2016-06-29 15:55:38 +02:00
Benno Schulenberg
1d7c177606
input: don't drop a keystroke on the floor when the terminal resizes
...
This fixes the first part of https://savannah.gnu.org/bugs/?48331 .
Reported-by: Mike Frysinger <vapier@gentoo.org>
2016-06-29 15:53:08 +02:00
Benno Schulenberg
2ae490cd8f
build: refresh the git description whenever something is recompiled
...
This fixes https://savannah.gnu.org/bugs/?47962 reported by Cody Taylor.
2016-06-27 19:45:21 +02:00
Benno Schulenberg
6fda7a7057
chars: speed up two reverse-searching routines a bit
...
By removing from their main loops a condition that occurs just once.
2016-06-27 19:22:28 +02:00
Benno Schulenberg
1e2833e07b
tweaks: elide two unneeded variables
2016-06-27 19:22:20 +02:00
Benno Schulenberg
067b0a3367
input: elide an extra buffer for inserting stuff into the text
...
Do the casting from integer to character rightaway in the first
intermediate buffer.
2016-06-27 19:18:40 +02:00
Benno Schulenberg
24b10179a1
files: beep whenever writing out a file fails
...
Just like when reading a file fails. It needs the user's attention.
2016-06-27 19:17:53 +02:00
Benno Schulenberg
c14b581e0a
po: update translations and regenerate POT file and PO files
2016-06-27 11:07:44 +02:00
Benno Schulenberg
bfcb4cd415
bump version numbers and add a news item for 2.6.1
2016-06-27 11:01:54 +02:00
Benno Schulenberg
8fef94cd7d
po: make the linguas script regenerate the POT file
...
So we don't have to remember its awkward target name.
2016-06-27 10:58:47 +02:00
Benno Schulenberg
61d7ca4c41
docs: adjust the description of the verbatim function
2016-06-27 09:35:05 +02:00
Rishabh Dave
559858a3dd
browser: don't seem to enter a directory when it is inaccessible
...
This fixes https://savannah.gnu.org/bugs/?48286 .
Reviewed-by: Benno Schulenberg <bensberg@justemail.net>
Signed-off-by: Rishabh Dave <rishabhddave@gmail.com>
2016-06-26 10:14:12 +02:00
Benno Schulenberg
ddd9c7a022
tweaks: try to distinguish between keystrokes and characters
...
Keystrokes are single integers (aided by the flags meta_key and
func_key) but in the input stream they can be encoded as escape
sequences (a series of bytes). Characters are values in byte
range, but in UTF-8 one character can consist of multiple bytes.
Also rename two variables, because the secondary input buffer
that they refer to contains only characters (mostly just one),
never any shortcuts; and there are too many "kbinput" already.
2016-06-25 20:34:09 +02:00
Benno Schulenberg
03c689c22c
tweaks: normalize a type, and rewrap a line
2016-06-25 20:33:11 +02:00
Benno Schulenberg
5270dd8b32
tweaks: add a reporter's name
2016-06-25 20:03:25 +02:00
Benno Schulenberg
f33796bee1
tweaks: elide an impossible case
...
Typing a Unicode code is always finished after at most six characters:
either retval == uni or retval == kbinput, but it can't be ERR.
2016-06-25 16:52:36 +02:00
Benno Schulenberg
e679c518b1
tweaks: elide an unneeded variable
2016-06-25 16:52:36 +02:00
Luke Francl
ba9214c689
syntaxes: add highlighting rules for Rust
...
With tweaks from Andrea Canciani, Ben Young, Tennix, and Dirkjan Ochtman.
This fulfills https://savannah.gnu.org/bugs/?48163 .
2016-06-25 09:56:11 +02:00
Benno Schulenberg
68acc1dfc5
tabs: compute the number of required spaces without iterating
2016-06-24 14:56:41 +02:00
Benno Schulenberg
1a4ec6c2d3
moving: allow specifying negative numbers in "Go To Line"
...
The negatives are taken to mean: from the end of the file,
and: from the end of the line.
This fulfills https://savannah.gnu.org/bugs/?48248 .
2016-06-24 14:47:02 +02:00
Benno Schulenberg
6bb30978fb
tweaks: add a translator hint
2016-06-24 09:40:31 +02:00
Benno Schulenberg
c0c30731c4
browser: don't use a term that is not explained in the documentation
...
Also, other messages that are about --operatingdir don't use the term
"confined" either.
Suggested-by: Mario Blättermann <mario.blaettermann@gmail.com>
2016-06-24 09:24:00 +02:00
Jordi Mallach
49eaa7c465
docs: bump pointers to the newest version available
...
Fix references to an old dist dir in FAQ and RPM spec file.
2016-06-23 19:53:58 +02:00
Jordi Mallach
c2b199e926
docs: use https for nano-editor.org, and drop the www
...
Switch to https and drop the www. prefix for all occurrences of the
website URL.
2016-06-23 19:51:01 +02:00
Benno Schulenberg
80552aeab7
tweaks: elide an intermediate copy of some line data
2016-06-22 10:30:52 +02:00
Benno Schulenberg
dfbabc0411
tweaks: fix a date and an email address
2016-06-22 10:30:42 +02:00
Benno Schulenberg
59b9b222c8
moving: ignore any number when ^Y or ^V is given
...
This fixes https://savannah.gnu.org/bugs/?48282 .
2016-06-21 16:47:11 +02:00
Benno Schulenberg
79e3eaf73c
linter: refresh the edit window in order to actually place the cursor
...
This fixes https://savannah.gnu.org/bugs/?48283 .
2016-06-21 16:25:07 +02:00
Benno Schulenberg
9106cc8ecc
main: let the main loop restore the main menu, if needed
...
Don't make it the responsibility of the executed functions to restore
the list of shortcuts of the edit window. Just detect whether another
menu was displayed, and if so, redisplay the main menu.
2016-06-21 11:03:38 +02:00
Benno Schulenberg
17fb6dfdc0
tweaks: reshuffle two lines and improve two comments
2016-06-20 13:07:25 +02:00
Benno Schulenberg
95f417fa9a
tweaks: rewrap a bunch of lines and some comments
2016-06-20 13:05:45 +02:00
Benno Schulenberg
49cb559c5b
po: regenerated POT file, and updated PO files from TP
2016-06-17 15:49:20 +02:00
Benno Schulenberg
f26e88bb52
tweaks: a few last tiny adjustments before release
2016-06-17 15:04:44 +02:00
Benno Schulenberg
8875acf912
po: correctly advertise whether new PO files have arrived
...
And don't bother running configure and make upstairs; here is enough.
2016-06-17 14:47:43 +02:00
Benno Schulenberg
a025878466
po: delete an obsolete script
...
The way to update nano.pot is to run 'make nano.pot-update' in the po
subdir. Updating a specific PO file is then done with 'make xx.po'.
(The script mistakenly included all leading comments, not just the
ones marked with "TRANSLATORS:".)
2016-06-17 13:59:45 +02:00
Benno Schulenberg
9aaa835858
docs: add a list of the important changes since version 2.2.6
2016-06-17 13:32:06 +02:00
Benno Schulenberg
627f04e028
docs: rename a file, to be less confusing
...
It sounded like an instigation to upgrade, or like a list of
instructions on how to upgrade. But it is merely a list of
noteworthy changes -- what other packages put in the NEWS file.
2016-06-17 11:12:37 +02:00
Benno Schulenberg
158388c5a6
justify: enable cursor display also for the first keystroke afterward
...
This fixes https://savannah.gnu.org/bugs/?48246 .
2016-06-16 20:40:09 +02:00
Benno Schulenberg
3e45c9c5cf
version: cover the copyrights that are not assigned to the FSF
2016-06-15 21:28:11 +02:00
Benno Schulenberg
7165bd5c33
input: don't allocate too much, and don't move too many
...
To add a character, one does not need to allocate twice its size.
And the amount to be moved does not depend on the size of the new
character; it just needs to include the terminating zero.
(This fixes in do_output() the same logical mistakes that were fixed
in do_statusbar_output() last February, in acf19bd
and 7c0e433.)
2016-06-14 17:00:22 +02:00
Benno Schulenberg
883373cd76
undo: start renumbering from the head of the paste, not from its tail
...
Because when undoing a paste at the end of the buffer, the tail line
probably does not exist any more.
This fixes https://savannah.gnu.org/bugs/?48222 .
(It would have been the proper fix for
https://savannah.gnu.org/bugs/?44488 .)
2016-06-14 16:34:29 +02:00
Benno Schulenberg
9536edfcc6
add a news item for 2.6.0
...
Signed-off-by: Benno Schulenberg <bensberg@justemail.net>
2016-06-14 09:44:39 +02:00
Benno Schulenberg
efa42e4a88
docs: update the version number for the upcoming release
...
Signed-off-by: Benno Schulenberg <bensberg@justemail.net>
2016-06-13 12:27:26 +02:00