emacs-devel
[Top][All Lists]
Advanced

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

Re: whitespace includes U+3000


From: Kevin Rodgers
Subject: Re: whitespace includes U+3000
Date: Wed, 05 Jul 2006 11:33:03 -0600
User-agent: Thunderbird 1.5.0.4 (Windows/20060516)

Richard Stallman wrote:
>     > You can probably get this result by putting NBSP into the pattern
>     > for show-trailing-whitespace to recognize.  Redisplay will override
>     > the face, for the NBSP.
>
>     What do you mean by "pattern" here?  Regular expression?
>
> Yes, I assumed it used one.
>
> However, on second thought, I've concluded that
> show-trailing-whitespace doesn't need to know about NBSP at all.
> Since NBSP is now indicated on the screen by a color, it is no longer
> likely to go unnoticed.  So there is no problem with NBSP and
> show-trailing-whitespace.

That is true by default, but not if the user has set
nobreak-char-display to nil.  I think show-trailing-whitespace should
DTRT even if the user has made such a customization and ensure that the
trailing whitespace is indicated.

> show-trailing-whitespace ought to know about all characters that will
> be indistinguishable on the screen from "end of the line".

Agreed! (for non-default values of display options like
nobreak-char-display as well)

>     By the way, I've just found that currently the special face
>     for NBSP is overriden by show-trailing-whitespace.
>
> Do you mean, show-trailing-whitespace would override the special face
> for NBSP _if_ you modify it to recognize NBSP along with SPC and TAB?
> That means my expectation was mistaken; I stand corrected.

I think that is good: it means that show-trailing-whitespace will
indicate NBSP regardless of nobreak-char-display.

> But since show-trailing-whitespace does not need to recognize NBSP,
> this isn't a _problem_.

I don't think so.  (To reiterate: show-trailing-whitespace does need to
recognize NBSP in case nobreak-char-display is nil).
...

>     How about the case of delete-trailing-whitespace?
>
> That is meant to get rid of junk.  It should probably delete
> NBSP just like SPC and TAB, since that is useless at the end of a line.

It would be surprising if delete-trailing-whitespace deleted anything
(e.g. NBSP) that was not displayed specially by show-trailing-whitespace.

--
Kevin





reply via email to

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