GNU bug report logs -
#50951
28.0.50; Urdu text is not displayed correctly
Previous Next
Reported by: Rah Guzar <aikrahguzar <at> gmail.com>
Date: Fri, 1 Oct 2021 20:19:01 UTC
Severity: normal
Tags: moreinfo
Found in version 28.0.50
Done: YAMAMOTO Mitsuharu <mituharu <at> math.s.chiba-u.ac.jp>
Bug is archived. No further changes may be made.
Full log
View this message in rfc822 format
On Mon, 05 Sep 2022 22:03:47 +0900,
Rah Guzar via Bug reports for GNU Emacs, the Swiss army knife of text editors wrote:
>
> At your suggestion, I tried hb-view and it renders Noto Nastaliq fine.
> Similarly Libre Office which also uses harfbuzz as far as I understand,
> also renders it fine. Which is why I said that the problem is limited to
> emacs.
Probably the following change will fix the problem:
diff --git a/src/hbfont.c b/src/hbfont.c
index 2721a66120..01db522909 100644
--- a/src/hbfont.c
+++ b/src/hbfont.c
@@ -598,6 +598,8 @@ hbfont_shape (Lisp_Object lgstring, Lisp_Object direction)
make_fixnum (xoff),
make_fixnum (yoff),
make_fixnum (wadjust)));
+ else
+ LGLYPH_SET_ADJUSTMENT (lglyph, Qnil);
}
return make_fixnum (glyph_len);
The other shapers except uniscribe_shape need to be changed, too.
Alternatively, one could clear garbage entries at the caller side:
diff --git a/src/composite.c b/src/composite.c
index 22422cca09..249d7587f6 100644
--- a/src/composite.c
+++ b/src/composite.c
@@ -876,7 +876,8 @@ fill_gstring_body (Lisp_Object gstring)
}
LGLYPH_SET_ADJUSTMENT (g, Qnil);
}
- if (i < LGSTRING_GLYPH_LEN (gstring))
+ len = LGSTRING_GLYPH_LEN (gstring);
+ for (; i < len; i++)
LGSTRING_SET_GLYPH (gstring, i, Qnil);
}
YAMAMOTO Mitsuharu
mituharu <at> math.s.chiba-u.ac.jp
This bug report was last modified 2 years and 241 days ago.
Previous Next
GNU bug tracking system
Copyright (C) 1999 Darren O. Benham,
1997,2003 nCipher Corporation Ltd,
1994-97 Ian Jackson.