Benno Schulenberg
f6dd0ad18a
tweaks: compile a parameter unconditionally
...
Straightforward code is more important than the tiniest possible binary.
Also adjust some comments and rename a variable.
2016-08-02 17:30:58 +02:00
Benno Schulenberg
a7ae1766c0
locking: remove any lock files when dying
...
This fixes https://savannah.gnu.org/bugs/?48675 .
2016-08-02 17:30:40 +02:00
Benno Schulenberg
faa46a3c71
screen: remove redundant redrawings of the entire edit window
...
(It may have been necessary in the past; there is no need for it now.)
This fixes https://savannah.gnu.org/bugs/?48633 .
2016-08-01 19:41:13 +02:00
Benno Schulenberg
03b168d0e3
tweaks: restore earlier conditions to prevent superfluous redrawings
...
When doing an <Up> on the top line, or a <Down> on the bottom line of
the edit window, the affected lines have already been redrawn by the
scrolling code, so there is no need to do that again.
(However, that does not prevent the second line (or the last-but-one
line) from being redrawn unnecessarily when using the M-- (or M-+)
command elsewhere on the screen and /that/ line is horizontally
scrolled. But we'll let that pass for now.)
2016-08-01 19:41:13 +02:00
Benno Schulenberg
2f6647687a
tweaks: rename a function, and adjust some comments
2016-08-01 19:41:13 +02:00
Benno Schulenberg
c9e9964207
screen: don't look at placewewant but at where we actually were and are
...
For horizontal scrolling, it is not the /desired/ column position that
is relevant for determining whether a line needs to be redrawn after a
cursor movement, but the /actual/ column positions before and after.
This fixes https://savannah.gnu.org/bugs/?48627 ,
and fixes https://savannah.gnu.org/bugs/?48629 .
2016-08-01 19:41:13 +02:00
Benno Schulenberg
0a3a6441bc
tweaks: unconditionally compile a couple of parameters
...
Having two unneeded parameters in the tiny version is acceptable --
the code gets so much more readable.
2016-08-01 19:41:13 +02:00
Benno Schulenberg
2eafe7bf58
files: make allowances for 32-bit PIDs
...
This addresses https://bugs.debian.org/831636 reported by Christoph Biedl.
2016-08-01 16:24:05 +02:00
Benno Schulenberg
08c51cfd45
input: ingest as verbatim just one control code or one or two escapes
...
Leave the rest of any escape sequence to be processed normally, which
should be possible because those characters are all in ASCII range.
This fixes https://savannah.gnu.org/bugs/?48318 .
2016-08-01 14:47:02 +02:00
Benno Schulenberg
b472f5a633
tweaks: remove some unnecessary keycodes from a switch statement
...
These codes are the basic codes that get assigned for the movement keys
in the list of shortcuts -- they don't need any translation.
2016-08-01 14:07:21 +02:00
Benno Schulenberg
5806bf5249
tweaks: normalize some whitespace and adjust several comments
2016-08-01 14:05:42 +02:00
Benno Schulenberg
90a90365a8
tweaks: rename three constants, for clarity, and hardcode two others
2016-08-01 12:56:05 +02:00
Benno Schulenberg
9cd30d4917
tweaks: don't bother setting meta_key to false when a key is invalid
...
That is a task for the key-getting routine.
2016-07-31 18:32:18 +02:00
Benno Schulenberg
f33d8cae30
tweaks: don't use a function call when reference to the variable will do
2016-07-31 18:30:53 +02:00
Benno Schulenberg
e471e2d462
tweaks: move the modified editing keys again
2016-07-31 18:29:57 +02:00
Benno Schulenberg
fe38b78486
tweaks: adjust indentation after the previous changes
2016-07-31 18:22:07 +02:00
Benno Schulenberg
1af1f5c9f4
tweaks: return quicker from the key parsing routine
2016-07-31 18:19:17 +02:00
Benno Schulenberg
b9e83fe9f8
tweaks: move some debugging stuff, and move modified editing keys too
...
Again, just for preapring an easier return from the parsing routine.
2016-07-31 18:17:06 +02:00
Benno Schulenberg
cb10b2b908
tweaks: elide the global variable 'func_key'
...
There is no need to specially flag a function key or editing key --
the keycode is indication enough in itself: outside of byte range.
2016-07-31 18:13:05 +02:00
Benno Schulenberg
19dfd20a88
tweaks: add a variable, in preparation for making returning easier
2016-07-31 18:10:31 +02:00
Benno Schulenberg
d12fdda15b
tweaks: replace a three-case switch with an if and an else
2016-07-31 18:10:01 +02:00
Benno Schulenberg
3930a697e8
tweaks: consistently use a parameter instead of a struct element
2016-07-30 13:05:52 +02:00
Benno Schulenberg
9322e1e6a4
tweaks: reshuffle two ifs for a little more speed
...
Saving roughly twenty microseconds at startup.
2016-07-30 13:04:06 +02:00
Benno Schulenberg
b70fe38eab
tweaks: normalize some indentation
2016-07-30 12:24:35 +02:00
Benno Schulenberg
1c528db8da
tweaks: condense three asserts into a single one
...
Also, when a key string does not denote a Ctrl nor Meta nor Function key,
there is no point in assigning a keycode, because plain characters cannot
be used as a function shortcut.
2016-07-30 12:24:35 +02:00
Benno Schulenberg
1c9ab8bf16
tweaks: rename a struct element, to be more fitting
...
The keycode is not a sequence; it is a single integer value.
2016-07-30 12:24:35 +02:00
Benno Schulenberg
e295070193
shortcuts: group the setting of key string and keycode into one function
...
And instead of using two key types, just use a bool to indicate whether
a keystroke involves Meta.
2016-07-30 12:21:42 +02:00
Benno Schulenberg
91951ab22a
input: don't bother putting a keycode into byte range
...
A keycode is either already in byte range (so there is nothing to do)
or it is not and it shouldn't be (so there is nothing to do either).
2016-07-30 12:19:47 +02:00
Benno Schulenberg
5b0ab8be62
shortcuts: remove any unnecessary classifying of keys
...
After initialization, the type of a key is never used nor needed
(other than for meta keys).
2016-07-30 12:13:47 +02:00
Benno Schulenberg
ecef093def
tweaks: adjust indentation after previous changes
2016-07-29 09:33:28 +02:00
Benno Schulenberg
6d6f5bd4a7
tweaks: check earlier on for sufficient length of the sequence
2016-07-29 09:33:28 +02:00
Benno Schulenberg
e3dbffc9f7
input: be more strict in recognizing certain escape sequences
...
Accept the "Esc [ 1 n ~" and "Esc [ 2 n ~" sequences only when they
end with the "~" character, not with any character.
2016-07-29 09:33:28 +02:00
Benno Schulenberg
2225d54126
input: don't use a function call when a literal value will do
2016-07-29 09:33:28 +02:00
Benno Schulenberg
9115828e76
input: fix a pasto from eight years ago, from commit e347efb
2016-07-29 09:33:16 +02:00
Benno Schulenberg
b43a72471a
docs: tweak some spacing and spelling
2016-07-29 09:05:40 +02:00
Benno Schulenberg
2b5d29b8c6
po: update translations and regenerate POT file and PO files
2016-07-28 09:38:30 +02:00
Benno Schulenberg
b40520b574
bump version numbers and add a news item for 2.6.2
2016-07-28 09:21:27 +02:00
Benno Schulenberg
992533b91e
moving: don't do an automatic smart home with Ctrl+Up and Ctrl+Down
...
It is nicer to have a predictable cursor position and not see it hop
left and right on differently indented lines.
2016-07-28 09:09:51 +02:00
Benno Schulenberg
f3e8991206
credits: don't bother blanking the second line nor the help lines
...
Those lines don't exist in that mode -- the relevant subwindows are
smaller, or have been made smaller just before.
2016-07-27 12:40:11 +02:00
Benno Schulenberg
df7353b312
tweaks: compute the sizes of the subwindows in a more direct manner
2016-07-27 12:27:04 +02:00
Benno Schulenberg
f311c0af87
tweaks: adjust a couple of comments
2016-07-27 09:23:49 +02:00
Benno Schulenberg
c88fae3310
search: match a beginning-of-line anchor just once per line
...
This fixes https://savannah.gnu.org/bugs/?48635 .
2016-07-27 09:04:06 +02:00
Benno Schulenberg
68cfb08888
tweaks: fix compilation with --enable-tiny
2016-07-25 17:29:24 +02:00
Benno Schulenberg
4cff67fdde
tweaks: adjust indentation after the previous change, and edit comments
2016-07-25 12:50:03 +02:00
Benno Schulenberg
aefe26d216
tweaks: factor out a common condition
2016-07-25 12:31:40 +02:00
Benno Schulenberg
8eb99e2a1d
tweaks: put similar things together
2016-07-25 12:18:40 +02:00
Benno Schulenberg
19b6f906cc
tweaks: rename another variable, for aptness
2016-07-25 10:57:33 +02:00
Benno Schulenberg
c38ffdc741
tweaks: rename two variables, to match others
2016-07-25 10:53:49 +02:00
Benno Schulenberg
a472f480a7
tweaks: trim some comments, and simplify a condition
2016-07-24 13:44:16 +02:00
Benno Schulenberg
4416d9c941
tweaks: shuffle the resetting of a counter to the tail of the routine
2016-07-24 13:15:45 +02:00