GNU bug report logs - #28339
25.2; Emacs shows ZWNJ character (Zero Width non-Joiner) as Space

Previous Next

Package: emacs;

Reported by: Nima Aryan <nimawebgard <at> gmail.com>

Date: Sun, 3 Sep 2017 16:41:01 UTC

Severity: normal

Found in version 25.2

Done: Lars Ingebrigtsen <larsi <at> gnus.org>

Bug is archived. No further changes may be made.

Full log


Message #26 received at 28339 <at> debbugs.gnu.org (full text, mbox):

From: Nima Aryan <nimawebgard <at> gmail.com>
To: 28339 <at> debbugs.gnu.org
Cc: Kenichi Handa <handa <at> gnu.org>, Eli Zaretskii <eliz <at> gnu.org>
Subject: Re: bug#28339: 25.2; Emacs shows ZWNJ character (Zero Width
 non-Joiner) as Space
Date: Mon, 04 Sep 2017 11:43:40 +0000
[Message part 1 (text/plain, inline)]
It got interesting and I've found a workaround for the issue. display of
ZWNJ as SPACE or any other character is matter of font. Different fonts
uses different characters. Default Emacs font shows '[' instead of space
which is better and more readable at least.

The only minor problem I've seen so far is the irrelevance of displayed
character (shown as ZWNJ) to the 'glyphless-char-display-control' for
Persian alphabet.

I've attached a screenshot which shows different behavior of display for
both English and Persian at the same time. I execute `emacs -q` to launch
default Emacs. Then I open Test.text sample attached in previous emails.
Set the `glyphless-char-display-control` to show hex-box. It's clearly
shown that The English one is replaced by a hex-box but the Persian one
with a '[' (or SPACE).  No matter what the 'glyphless-char-display-control'
the Persian case shows same character.

Note, To type the ZWNJ for the English text, AB, I used Persian input (A,
switch keyboard layout, SHIFT+Space, switch back to English, B). So when I
put ZWNJ between the AB it's shown as hex-box (and affected by
'glyphless-char-display-control' as expected) but when I type it between
Persian characters it's shown as fixed '[' or 'SPACE' (font based) no
matter what the glyphless-char dictates.

Best Regards,


On Mon, Sep 4, 2017 at 1:45 PM Eli Zaretskii <eliz <at> gnu.org> wrote:

> > From: sadid sahami <sadidsahami <at> gmail.com>
> > Date: Mon, 04 Sep 2017 05:05:03 +0000
> >
> > I've provided a minimal test text, written in Emacs (Test.text) and its
> display for Gedit (Gedit_display.png) and
> > Emacs (Emacs_display.png). The Gedit display is the correct one.
>
> Hmm.. on my system I see a display that is almost identical to what
> your "Gedit" display shows.
>
> CC'ing Handa-san who might be able to help us with verifying the
> composition rules for Persian.  Or maybe this is a problem with the
> shaping engine used on GNU/Linux?
>
> In any case, disabling bidi reordering doesn't fix the display (it
> makes the display much worse for me), so it is not the problem.
>
[Message part 2 (text/html, inline)]
[glyphless_diff_behav_in_EngOrFa.png (image/png, attachment)]

This bug report was last modified 4 years and 260 days ago.

Previous Next


GNU bug tracking system
Copyright (C) 1999 Darren O. Benham, 1997,2003 nCipher Corporation Ltd, 1994-97 Ian Jackson.