"Ted Unangst":
> This came up long ago, but I've lost the mail, and the problem remains.
>
> When printing a line of text containing vt100 escapes and tabs, the tab stops
> are not set correctly. After running reset, they are.
>
> Repro:
>
> Open a new xterm and run printf "\e[32m\tgreen\e[0m\n".
>
> Observe four space indent.
xterm's tty defaults to the "oxtabs" setting, i.e., \t characters are
expanded to spaces by the line discipline, which doesn't understand
terminal control sequences.
$ stty -e | grep oflags
oflags: opost onlcr -ocrnl -onocr -onlret -olcuc oxtabs -onoeot
^^^^^^
> Run reset and run printf again. Observe eight spaces.
This resets the oxtabs flag, so \t characters are output unmodified.
$ stty -e | grep oflags
oflags: opost onlcr -ocrnl -onocr -onlret -olcuc -oxtabs -onoeot
^^^^^^^
> One of the magic OXTABS bits needs to be adjusted? I thought that was the
> proposed resolution?
Yes, and that was committed three years ago, disabling oxtabs in
<sys/ttydefaults.h> and a few other places.
I don't understand where the initial oxtabs setting in xterm is
coming from. xterm itself?
--
Christian "naddy" Weisgerber [email protected]