Subject: bug#28339: 25.2; Emacs shows ZWNJ character (Zero Width non-Joiner) as Space

From: Eli Zaretskii <[email-masked]>
Date: Sat, 16 Sep 2017 20:42:54 +0300

> From: Benjamin Riefenstahl <[email-masked]>
> Cc: handa <[email-masked]>,  [email-masked],  [email-masked]
> Date: Sat, 16 Sep 2017 19:30:05 +0200
> 
> > [...] I thought the shaping engine gives us back glyphs that don't
> > include ZWNJ itself.  Evidently, that's not true, which I find
> > strange.
> 
> I thought that with OpenType at least that depends on the font?

It does, but Handa-san seems to say that even the best fonts don't
consider ZWNJ part of any grapheme cluster, and always leave it alone.

> For editing, I would like a hair-line type glyph to delete.

We already have a solution for deleting a character which was composed
with the preceding one(s).  So I think this aspects doesn't have to be
a factor in our decision how to display ZWNJ.

> We should also consider what to do about ZWJ and the bidi directional
> control characters.

Bidi controls are different in that they are never composed.  Their
effect is via the application of the UBA, and whether or not to
display them is explicitly left to the application to decide.

> * Hightlighting ZWNJ in read-only text while searching for it with
>   incremental search.

In general, search should ignore ZWNJ and similar controls, at least
the "folding" search.

> * User-specified replacement via display tables. 

We already have the glyphless-char-display-control feature for that.