bug-bash
[Top][All Lists]
Advanced

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

Re: bash doesn't display user-typed characters; can interfere with COPY/


From: L A Walsh
Subject: Re: bash doesn't display user-typed characters; can interfere with COPY/PASTE
Date: Tue, 08 Dec 2020 15:38:11 -0800
User-agent: Thunderbird

On 2020/12/08 06:28, Greg Wooledge wrote:
The end result is that it's basically impossible to preserve the original
whitespace of your source material across a terminal copy/paste operation.
So don't count on that.
----
If you use a random terminal to copy/paste, sure, but if you use a specific
product that maintains fidelity, then it's not true.


Especially nice are term-progs that automatically reflow text *as you resize* the terminal. Like if you see 100 characters written to an 80-column terminal,
that line wraps the text, when you expand the width, you retain the original
white space. That's why programs that don't preserve what you wrote are annoying. And note -- you see the reflow in real-time as you change dimensions -- not just
at the end.

   Imagine working on a terminal that only displayed upper case even if the
differentiation was saved when stored. You can't really see the text as "it is"
when you enter it or re-edit it.  With it putting in something different on
display than what is really there, you get things like (tab chars between
each letter):
echo "a b c d e f g h
i j k l m n o p q r s t a b c d e f g h i j k l m n o p q r s t" a b c d e f g h i j k l m n o p q r s t a b c d e f g h i j k l m n o p q r s t

If you re-edit a line with tabs in it that displays like it does in the bottom
line, above (tabs ever 2 spaces), the re-edited "line" takes up 4 lines.





reply via email to

[Prev in Thread] Current Thread [Next in Thread]