all messages for Emacs-related lists mirrored at yhetil.org
 help / color / mirror / code / Atom feed
* Latin-1 non breaking space not highlighted
@ 2002-04-07 23:31 Ulrich Neumerkel
  2002-04-08  7:08 ` Eli Zaretskii
  0 siblings, 1 reply; 23+ messages in thread
From: Ulrich Neumerkel @ 2002-04-07 23:31 UTC (permalink / raw)


--text follows this line--
This bug report will be sent to the Free Software Foundation,
not to your local site managers!
Please write in English, because the Emacs maintainers do not have
translators to read other languages for them.

Your bug report will be posted to the bug-gnu-emacs@gnu.org mailing list,
and to the gnu.emacs.bug news group.

In GNU Emacs 21.2.1 (i686-pc-linux-gnu, X toolkit)
 of 2002-04-08 on gupu.complang.tuwien.ac.at
configured using `configure  --without-toolkit-scroll-bars --prefix /usr'
Important settings:
  value of $LC_ALL: nil
  value of $LC_COLLATE: nil
  value of $LC_CTYPE: nil
  value of $LC_MESSAGES: nil
  value of $LC_MONETARY: nil
  value of $LC_NUMERIC: nil
  value of $LC_TIME: nil
  value of $LANG: en_US
  locale-coding-system: iso-latin-1
  default-enable-multibyte-characters: nil

Please describe exactly what actions triggered the bug
and the precise symptoms of the bug:

With show-trailing-whitespace being true in a Latin-1 buffer the
character "non breaking space" (C-x 8 SPACE) is not highlighted at the
end of line.


US
  locale-coding-system: iso-latin-1
  default-enable-multibyte-characters: nil

Please describe exactly what actions triggered the bug
and the precise symptoms of the bug:

With show-trailing-whitespace being true in a Latin-1 buffer the
character "non breaking space" (C-x 8 SPACE) is not highlighted at the
end of line.

^ permalink raw reply	[flat|nested] 23+ messages in thread
* Re: Latin-1 non breaking space not highlighted
@ 2002-04-14 23:30 Ulrich Neumerkel
  2002-04-16 20:16 ` Richard Stallman
  0 siblings, 1 reply; 23+ messages in thread
From: Ulrich Neumerkel @ 2002-04-14 23:30 UTC (permalink / raw)
  Cc: emacs-devel, ulrich

> From: "Eli Zaretskii" <eliz@is.elta.co.il>
> I see two possible solutions:
>
>   - hardcode a few more special characters, like ISO8859-x NBSP and a
>     few Unicode characters;
> or
>   - use syntax tables for non-ASCII characters only, assuming that no
>     Lisp package does anything weird with their syntax class.

Both solutions may cause problems with other/new encoding systems.
Maybe better:
   - use the syntax table of the corresponding fundamental mode

^ permalink raw reply	[flat|nested] 23+ messages in thread
* Re: Latin-1 non breaking space not highlighted
@ 2002-04-14 23:54 Kenichi Handa
  0 siblings, 0 replies; 23+ messages in thread
From: Kenichi Handa @ 2002-04-14 23:54 UTC (permalink / raw)
  Cc: rms, ulrich, emacs-devel

"Eli Zaretskii" <eliz@is.elta.co.il> writes:
>>  It looks like there is a real problem.  I guess we should not simply
>>  change show-trailing-whitespace to use the whitespace syntax class.

> I see two possible solutions:

>   - hardcode a few more special characters, like ISO8859-x NBSP and a
>     few Unicode characters;
> or
>   - use syntax tables for non-ASCII characters only, assuming that no
>     Lisp package does anything weird with their syntax class.

I think show-trailing-whitespace should not be affected by
syntax of characters because what it should concern is a
glyph.  If a glyph of a character is just space, even if the
syntax is `symbol' or whatever else, it should be
highlighted.

So, what we need is a char-table of such characters that are
displayed by white glyph.  In addition to many NBSPs, that
char-table should also contain the following CJK white-space
characters:
 (make-char 'japanese-jisx0208-1978 33 33)
 (make-char 'chinese-gb2312 33 33)
 (make-char 'japanese-jisx0208 33 33)
 (make-char 'korean-ksc5601 33 33)
 (make-char 'chinese-cns11643-1 33 33)
 (make-char 'japanese-jisx0213-1 33 33)
 (make-char 'chinese-big5-1 33 33)

---
Ken'ichi HANDA
handa@etl.go.jp

^ permalink raw reply	[flat|nested] 23+ messages in thread
* Re: Latin-1 non breaking space not highlighted
@ 2002-04-19  1:55 Kenichi Handa
  2002-04-19 13:55 ` Stefan Monnier
  0 siblings, 1 reply; 23+ messages in thread
From: Kenichi Handa @ 2002-04-19  1:55 UTC (permalink / raw)
  Cc: eliz, monnier+gnu/emacs, rms, ulrich, emacs-devel

"Stefan Monnier" <monnier+gnu/emacs@RUM.cs.yale.edu> writes:
>>  But Handa-san listed a couple of problems with using the standard syntax 
>>  tables.

> I seem to have missed his email.

My point is:
show-trailing-whitespace should not mean highlighting such
charactes that have "whitespace" SYNTAX, but should mean
highlighting sucn characters that have "whitespace" GLYPH.

Both sets of characters mostly overlap but not necessarily
be the same.

For instance, even if I set syntax of NBSP to "word
constitute", show-trailing-whitespace should highlight it.

---
Ken'ichi HANDA
handa@etl.go.jp

^ permalink raw reply	[flat|nested] 23+ messages in thread
* Re: Latin-1 non breaking space not highlighted
@ 2002-04-22  1:53 Kenichi Handa
  2002-04-22 22:37 ` Richard Stallman
  0 siblings, 1 reply; 23+ messages in thread
From: Kenichi Handa @ 2002-04-22  1:53 UTC (permalink / raw)
  Cc: monnier+gnu/emacs, eliz, rms, ulrich, emacs-devel

"Stefan Monnier" <monnier+gnu/emacs@RUM.cs.yale.edu> writes:
>>  My point is:
>>  show-trailing-whitespace should not mean highlighting such
>>  charactes that have "whitespace" SYNTAX, but should mean
>>  highlighting sucn characters that have "whitespace" GLYPH.

> That's a separate issue.  Related to whether or not we should
> take the display-table into account.

In my understanding, the purpose of show-trailing-whitespace
is to tell users that there are characters that has space
glyphs (thus invisible) at end of line.  So, yes, if some
characters are displayed by SPCs because of display-table,
it is better that we take that info account (although it may
require a rather big change in the display engine).  Anyway,
we should not decide if a character should be highlighted or
not simply by its syntax.

>>  Both sets of characters mostly overlap but not necessarily
>>  be the same.
>>  
>>  For instance, even if I set syntax of NBSP to "word
>>  constitute",

> When would you do that and why (considering that we're specifically
> talking about the global standard-syntax-table) ?

The above is just an example.  I don't mean it's useful.
But, hmmm, perhaps, it may be useful for filling.

>>  show-trailing-whitespace should highlight it.

> Really ?  I think this very much depends on the answer to the
> previous question.

I really think NBSP should be highlighted also in such a
(hypothetical) situation.  What do the other people think?

> We really just need a table somewhere that tells us what is whitespace
> and what isn't.  Currently I think there are two such tables, one is
> the standard-syntax-table, the other is the ` ' category.  Actually,
> I [:space:] and [:blank:] are two more, but [:space:] relies on the
> buffer-local syntax-table (i.e. not good, although it's not that bad
> since it only uses it for non-ASCII chars, IIRC) and [:blank:] only
> matches ASCII chars (i.e. not good either).

I have forgotten about ` ' category.  Do you know which
character has this category and how is that category used?

---
Ken'ichi HANDA
handa@etl.go.jp

^ permalink raw reply	[flat|nested] 23+ messages in thread

end of thread, other threads:[~2002-04-22 22:37 UTC | newest]

Thread overview: 23+ messages (download: mbox.gz follow: Atom feed
-- links below jump to the message on this page --
2002-04-07 23:31 Latin-1 non breaking space not highlighted Ulrich Neumerkel
2002-04-08  7:08 ` Eli Zaretskii
2002-04-09 12:08   ` Richard Stallman
2002-04-09 14:37     ` Eli Zaretskii
2002-04-10 20:16       ` Richard Stallman
2002-04-11 18:54         ` Eli Zaretskii
2002-04-12  8:18           ` Eli Zaretskii
2002-04-13 19:06             ` Richard Stallman
2002-04-14  4:10               ` Eli Zaretskii
2002-04-15 21:59                 ` Richard Stallman
2002-04-18  5:38                   ` Eli Zaretskii
2002-04-18 10:18                     ` Stefan Monnier
2002-04-18 11:33                       ` Eli Zaretskii
2002-04-18 10:36                         ` Stefan Monnier
2002-04-19  5:25                       ` Richard Stallman
  -- strict thread matches above, loose matches on Subject: below --
2002-04-14 23:30 Ulrich Neumerkel
2002-04-16 20:16 ` Richard Stallman
2002-04-14 23:54 Kenichi Handa
2002-04-19  1:55 Kenichi Handa
2002-04-19 13:55 ` Stefan Monnier
2002-04-19 14:07   ` Miles Bader
2002-04-22  1:53 Kenichi Handa
2002-04-22 22:37 ` Richard Stallman

Code repositories for project(s) associated with this external index

	https://git.savannah.gnu.org/cgit/emacs.git
	https://git.savannah.gnu.org/cgit/emacs/org-mode.git

This is an external index of several public inboxes,
see mirroring instructions on how to clone and mirror
all data and code used by this external index.