GNU bug report logs -
#73752
29.4; Ligatures are randomly rendered with extra spaces
Previous Next
Reported by: xuan <at> xlk.me
Date: Fri, 11 Oct 2024 21:40:02 UTC
Severity: normal
Merged with 54646
Found in versions 29.0.50, 29.4
Fixed in version 30.1
Done: Eli Zaretskii <eliz <at> gnu.org>
Bug is archived. No further changes may be made.
Full log
Message #176 received at 73752 <at> debbugs.gnu.org (full text, mbox):
> Cc: 73752 <at> debbugs.gnu.org, xuan <at> xlk.me, visuweshm <at> gmail.com
> Date: Thu, 31 Oct 2024 11:42:12 +0200
> From: Eli Zaretskii <eliz <at> gnu.org>
>
> In my testing, that breakpoint never breaks, which is consistent with
> the fact that none of the glyphs we compose have zero width. They
> don't have zero width in your "broken rendering" case, either:
>
> > $ pp composition_gstring_from_id(19)
> >
> > [[#<font-object "-UKWN-Iosevka Term SS04-regular-normal-normal-*-20-*-*-*-d-0-iso10646-1"> 61 61 61] 19 [0 0 61 5852 10 1 11 11 -4 [0 0 20]] [1 1 61 5896 10 -1 11 11 -4 [0 0 20]] [2 2 61 5891 10 -1 9 11 -4 [0 0 20]]]
>
> (The width is the 5th component of the glyph vector, and they are all
> positive there.) Same in the example shown by Visuwesh:
>
> > Misaligned:
> >
> > [[#<font-object "-SAJA-Cascadia Code-bold-normal-normal-*-15-*-*-*-m-0-iso10646-1"> 45 45 62] 2231 [0 0 45 1970 9 0 9 7 -4 [0 0 10]] [1 1 45 1969 9 -1 10 7 -4 [0 0 10]] [2 2 62 2728 9 -1 9 11 0 [0 0 10]]]
>
> So there's something we are missing here.
>
> Also note that in Visuwesh's case the WADJUST element corresponds to
> the width of the previous glyph (9 + 1 = 10), but in your case it
> doesn't (11 + 1 ≠ 20). So this is another mystery.
>
> There are a few calls to lglyph-set-adjustment in composite.el, which
> could be responsible for this. So if the breakpoint inside
> composition_gstring_adjust_zero_width never breaks in your sessions,
> either, the next step is to put a watchpoint on the cached composition
> created by font-shape-gstring and wait for some code to modify the
> adjustment part.
Btw, is your Emacs built with only HarfBuz, or with both HarfBuz and
m17n-flt?
This bug report was last modified 252 days ago.
Previous Next
GNU bug tracking system
Copyright (C) 1999 Darren O. Benham,
1997,2003 nCipher Corporation Ltd,
1994-97 Ian Jackson.