GNU bug report logs - #73752
29.4; Ligatures are randomly rendered with extra spaces

Previous Next

Package: emacs;

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


View this message in rfc822 format

From: Tim Ruffing <dev <at> real-or-random.org>
To: Eli Zaretskii <eliz <at> gnu.org>, Tim Ruffing <dev <at> real-or-random.org>
Cc: 73752 <at> debbugs.gnu.org, xuan <at> xlk.me, visuweshm <at> gmail.com
Subject: bug#73752: 29.4; Ligatures are randomly rendered with extra spaces
Date: Thu, 31 Oct 2024 02:39:09 +0100

On Wed, 2024-10-30 at 20:57 +0200, Eli Zaretskii wrote:
> 
> 
> Then what exactly is the difference between the session with "good"
> display and the one with the "bad" display?  How come they show the
> same ligature differently?  What did you do to make them have
> different looks?

Nothing (that I'm aware of.) This appears to be non-deterministic.
Sometimes it works, sometimes it doesn't. And Yixuan seems to say the
same when he says that this looks like race condition.

It will still be useful to figure out what sets the [X-OFF Y-OFF
WADJUST] vectors instead of nil. After digging into the code a bit, I
strongly suspect it's composition_gstring_adjust_zero_width.

I'm not sure if I have the time to verify this in the coming days, I'd
appreciate if some of the other affected users could give it a try. 

I'm not claiming that composition_gstring_adjust_zero_width is wrong,
but if my theory is right that it sets the vector if and only if the
rendering is bad, then we'll be a step further.

This function was introduced in
cd88f6de4be1f8eba1db038b371d769f584be53b because of bug#50951. AFAIU it
is supposed to correct a grapheme width of 0 pixels to 1 pixel, so that
won't explain why large spaces are added. But I skimmed bug#50951 and
there are some mentions that composition_gstring_adjust_zero_width is
supposed to suppress adding the "space width of the font", which is
what some people see here, so all of this sounds a bit related. Next
question would be why emacs thinks that the grapheme width was zero in
the first place.

Tim  






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.