NetBSD-Users archive

[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index][Old Index]

Re: tmux messes up my backspace character



On Fri 15 Aug 2014 at 15:16:41 +0200, Steffen Nurpmeso wrote:
> Can't you simply `bind-key' over that?

I don't think so. bind-key looks to be for commands only, not a general
translation mechanism.

> But i'm out of ideas if not; i switched back to screen(1) due to
> it's charset conversion capabilities (i'm still using ISO-8859-x
> on all BSD VMs),o

Yes, so do I, and I noticed that if I happen to access my systems from
Linux, then tmux won't translate characters for use in utf8 terminals.

> requires significantly less CPU time and after

I am also surprised by the high cpu time usage of tmux. I wonder what it
is doing in all that time? The FAQ mentions something about automatic
window renaming or somesuch - I'm going to try turning that off and see
if that helps.

> And i guess your problem could be easily fixed with it's `term*' commands.

I used screen before, and there the problem doesn't exist at all. It
took a while to discover it in tmux because many programs can use
whatever is set for the erase character, including bash. I noticed it in
mutt, where ^H scrolls back a single line in a mail message.

I have also mailed to the tmux-users mailing list, and I have discovered
which code seems to be responsible for the translation:

        /*
         * Check for backspace key using termios VERASE - the terminfo
         * kbs entry is extremely unreliable, so cannot be safely
         * used. termios should have a better idea.
         */
        bspace = tty->tio.c_cc[VERASE];
        if (bspace != _POSIX_VDISABLE && key == bspace)
                key = KEYC_BSPACE;

in cvs/src/external/bsd/tmux/dist/tty-keys.c. Note that KEYC_BSPACE is
'\177' or ASCII DEL, not backspace.

> --steffen
-Olaf.
-- 
___ Olaf 'Rhialto' Seibert  -- The Doctor: No, 'eureka' is Greek for
\X/ rhialto/at/xs4all.nl    -- 'this bath is too hot.'

Attachment: pgpr24baDxOhG.pgp
Description: PGP signature



Home | Main Index | Thread Index | Old Index