GNU bug report logs - #39799
28.0.50; Most emoji sequences don’t render correctly

Previous Next

Package: emacs;

Reported by: Mike FABIAN <mfabian <at> redhat.com>

Date: Wed, 26 Feb 2020 14:30:03 UTC

Severity: normal

Found in version 28.0.50

Fixed in version 28.1

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

Bug is archived. No further changes may be made.

Full log


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

From: Eli Zaretskii <eliz <at> gnu.org>
To: Robert Pluim <rpluim <at> gmail.com>
Cc: rgm <at> gnu.org, 39799 <at> debbugs.gnu.org, mfabian <at> redhat.com
Subject: Re: bug#39799: 28.0.50; Most emoji sequences don’t render correctly
Date: Fri, 28 Feb 2020 18:19:10 +0200
> From: Robert Pluim <rpluim <at> gmail.com>
> Cc: Glenn Morris <rgm <at> gnu.org>,  mfabian <at> redhat.com,  39799 <at> debbugs.gnu.org
> Date: Fri, 28 Feb 2020 15:14:01 +0100
> 
>     >> It matches forward off the first char, so the
>     >> composition-function-table entries all have '0' as the number of chars
>     >> to match. Would it be better to match backwards?
> 
>     Eli> I don't think matching backwards is better in general.  Did you have a
>     Eli> reason for thinking it was?
> 
> I thought I saw a comment in composite.c that says matching is done
> backward, but I see that itʼs done forwards as well.

Btw, it sometimes _can_ be beneficial to use backward matching: if it
makes the size of composition-function-table smaller.  Since
composition-function-table is a char-table, and char-tables allocate
sub-tables only if needed, you can conserve memory (and thus make
Emacs's memory footprint smaller) and faster (because 'aref' will llok
up values in a char-table faster) by setting a smaller number of
slots.  For example, if the 2nd character of an Emoji sequence was
always one specific character, or a small set of characters, you could
set only the slots of those few characters, which would make the
char-table smaller.  OTOH, if that would yield many different
composition rules in the list of rules for those few characters,
redisplay could become slower, because it generally examines the rules
one by one until it finds an appropriate one.  So the winning setup of
composition-function-table is the one that sets the smallest number of
slots, but still keeps the lists of rules for those slots short.  And
note that setting the same rule for a range of codepoints generally
uses up only one slot in the char-table, so rules that can be
generalized to cover many characters are preferable.




This bug report was last modified 3 years and 256 days ago.

Previous Next


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