> Correct. Most terminal emulation software will throw spaces
> inbetween Foo and Bar as to ensure a decent way of copy/pasting
> text to a clipboard or etc.
I do not think so. Consider:
ESC[1;1H
ESC[K
ESC[1;10H
Bar
ESC[1;1H
Foo
This produces exactly the same effect. I find it hard to believe that
a terminal, upon printing Foo, will print 6 additional spaces.
[...]
> A string is "Hello", terminated with \0. If this string is
> printf()'d, it outputs "Hello". The terminal sees 5 characters,
> and therefore lets you select 5. Five are only sent over the
> tty as well.
Consider this:
ESC[1;1H
H
ESC[1;2H
e
ESC[1;3H
l
ESC[1;4H
l
ESC[1;5H
o
It also produces "Hello".
[...]
> If your string is 25 characters long, and you are using a
> terminal window which is 132 characters wide, is it efficient
> to print out 107 blank spaces at the end of the line? :-) It
> may be on a LAN, but not over a dialup.
This defeats the purpose of using screen management software. If you
do not like the terminal using an escape sequence to erase to the end
of a line, then disable this from the termcap/terminfo file.
> It is definitely a problem in either mutt, slang, or
> ncurses: or all three.
Or none of the above.
--John