Re: the home/end issue
Sorry my response took so long.
On 26 May, email@example.com wrote:
> Maybe I'm misunderstanding this, but IMO there's a big difference between
> the backspace issue (^? or ^H) and this one. A quick look in the terminfo
> database (http://www.earthspace.net/~esr/terminfo/) shows there are a very
> large number of different sequences associated with khome/kend
> (e.g., for khome: \E[H ^^ \E[1~ \Ehm \E[Y \377\240 \E[7~ etc.).
Sure, I wasn't talking about modifying terminfo at all, just xterm and
friends. This would have no influence what so ever on apps that use
> The correct way to make applications behave consistently with home and end,
> IMHO, would be something like:
> Screen-oriented programs that have/support cursor movement, e.g.
> editors, should use ncurses or an equivalent to parse the terminfo
> entry for the current TERM setting, and use that to support the
> following key behaviour, if it makes sense:
> "home" (khome): Move the cursor to the start of the current line.
> "end" (kend): Move the cursor to the end of the current line.
> "page up" (knp): Move one page up.
> "page down" (kpp): Move one page down.
>> That's a good idea, however, what the maintainers should do about it
>> depends on whether it's desirable to make a policy of only using \e[1~
>> and \e[4~ or not.
> I don't think it is, as there are _many_ different sequences associated with
> home and end keys for different terminal types.
I should have squeezed "in xterm and clones" somewhere in the sentence.
Making all the xterm-clones do the same thing would make their behavior
> With the backspace/delete issue, a big part of the problem is that many
> programs tried to fix it in their own particular way; with this issue, I
> don't think many programs are hardwired to expect specific sequences for
> home/end, pgup/pgdn etc.; the few that are should be changed to honour the
> terminfo entry.
Yes, I agree. I shouldn't have used joe as an example, instead joe
should be an example of an application that should use terminfo instead
of using the 'rc-file kludge'. Maybe it's not such a good idea
anyway. With bash in rxvt, the home and end keys work. If it's done by
mapping several different sequences, maybe it should also be done this
way in cshrc? It is not pretty, but it's probably more work to try and
change rxvt (and kvt), and apps such as joe should really use terminfo.
To UNSUBSCRIBE, email to firstname.lastname@example.org
with a subject of "unsubscribe". Trouble? Contact email@example.com