bug-gnu-emacs
[Top][All Lists]
Advanced

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

bug#12086: 24.1; character groups and `glyphless-char-display-control'


From: Eli Zaretskii
Subject: bug#12086: 24.1; character groups and `glyphless-char-display-control'
Date: Mon, 30 Jul 2012 21:08:29 +0300

> From: "Drew Adams" <address@hidden>
> Date: Sun, 29 Jul 2012 15:28:47 -0700
> 
> How is someone to know how a character group is displayed that is not
> listed in `glyphless-char-display-control'?

This is covered in the "Usual Display" node of the ELisp manual, which
is earlier in the same chapter.  Assuming that enough references to
that node are added to "Glyphless Chars", so that it's clear what
happens with the other characters, what else is missing?

> 2. I also wonder about the critter called a character "group", which is
> apparently new with Emacs 24.  Where is the notion of character group
> defined?

It's not really a notion, it comes from the '(GROUP . METHOD)' form of
glyphless-char-display-control.  There's nothing else to it.

> And how does this critter relate, for instance, to a character set
> (charset)?  For example, `c1-control' is a character group and
> `control-1' is a charset.  But these seem to include the same set of
> characters:
> 
> `describe-character-set control-1' says that it is the 8-bit control
> codes (0x80..0x9F).  The doc for `glyphless-char-display-control' says
> that group `c1-control' is the non-ASCII, non-printing characters
> `U+0080' to `U+009F'.
>  
> Is that a coincidence or a deliberate correspondence?  Any rational
> relation between char groups and charsets should be documented.  The
> relation between char group `c1-control' and charset `control-1' seems
> to be one such presumably rational relation.

It's a convenience device, nothing more.  The groups were chosen to
allow convenient reference to groups of characters that have similar
properties, as far as display is concerned.  c0-control and c1-control
are the names of these groups in old standards, see
http://en.wikipedia.org/wiki/C0_and_C1_control_codes, for example.  I
see no particular reason to delve into that in the manual; people who
know what these are will "Aha!" when they read; for others there's an
explicit definition of these groups in the manual.

> 3. How, if it is even possible, can a programmer turn off the effect of
> the glyphless display, which uses face `glyphless-char'?

As with every char-table: put nil in the character cell of the
character for which you want to disable this display.  If you want to
display it entirely, make the entire char-table full of nil.

> 4. If I do (insert-char #x80 4), I see four \200 chars in what appears to be
> face `escape-glyph', and NOT in face `glyphless-char'.  Doesn't the doc say 
> that
> `glyphless-char' is used?

See "Usual Display" (although the face is not mentioned there).

> And `C-u C-x =' does not say anything about either of those faces.

Because it doesn't know about them.  These faces are produced by the
display engine directly, as part of rendering the non-printable
characters, not via text properties.  So "C-u C-=", which looks for
text properties and overlays, doesn't see them.





reply via email to

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