[dev] [st] About some bugsy programs and st

From: Roberto E. Vargas Caballero <k0ga_AT_shike2.com>
Date: Sat, 15 Dec 2012 07:58:30 +0100

In the last days some persons have comment that they have problems with
the Delete key in bash or irssi. In this case, it is not a problem of st,
but a problem of bash or irssi. Taken from terminfo:

        If the terminal has a keypad that transmits codes when the keys
        are pressed, this information can be given. Note that it is not
        possible to handle terminals where the keypad only works in
        local (this applies, for example, to the unshifted HP 2621 keys).
        If the keypad can be set to transmit or not transmit, give these
        codes as smkx and rmkx. Otherwise the keypad is assumed to
        always transmit.

In our case smkx=\E[?1h\E= and rmkx=\E[?1l\E>, so it is mandatory that
programs which want to test against keypad keys, have to send these
sequences. But bugsy bash and irssi for example don't do it. A fast
solution is write this command:

        $ echo ^[?1h^[= >/dev/tty

And all the problems will be removed. In the case of bash reading the
manpage of readline you can see this text:

       enable-keypad (Off)
                When set to On, readline will try to enable the
                application keypad when it is called. Some systems
                need this to enable the arrow keys.

so, adding this option in your .inputrc you will fix the problem with
all applications which use readline. In the case of irssi this tip will
not help.

Some persons say that we should fix st and remove this problem (it is
very easy change the key assignament), but I don't agree. I think that
the problem is such applications which don't follow the terminfo rules,
so they should fix their problems.

I would like listen what think the people about this issue because it
begins to be a very common conversation point.

Received on Sat Dec 15 2012 - 07:58:30 CET

This archive was generated by hypermail 2.3.0 : Sat Dec 15 2012 - 08:00:04 CET