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

Re: How come i wrote a NO-BREAK SPACE in xterm+bash ?



Quoting Vincent Lefevre (vincent@vinc17.net):
> On 2015-08-19 16:33:09 -0500, David Wright wrote:
> > Quoting Thomas Schmitt (scdbackup@gmx.net):
> > > But the typographical purpose of NO-BREAK SPACE is to look
> > > like space without inviting an automatic line break.
> > > So making it look not like space would be absurd.
> > 
> > But shell input is not a typographical context. Most source code
> > isn't, except in literals. Documents generally are because they are
> > displayed/printed.
> 
> The point is that the terminal cannot do the difference between
> a NBSP coming from shell input and a NBSP coming from a displayed
> document. So, it should render a NBSP exactly like a normal space.
> And it is up to the application (the shell, an editor in some
> mode, etc.) to render NBSP in a special way if needed.

Why not? Let's substitute TAB TAB for NBSP in your comment.
My terminal happily swallows TAB TAB with cat > file, and renders
it correctly with cat file. But when I type TAB TAB as shell input,
I get "Display all 3402 possibilities? (y or n)". It seems to be able
to "do the difference" in this case.

So my point is, "rendering NBSP in a special way *is* needed" (because NBSP
is not treated as firstclass whitespace and, it appears, never can be).

Cheers,
David.


Reply to: