GtkEntry and GtkTextView 'insert emoji' slow / freeze screen

‘insert emoji’ is displayed for the right click menu on my GTK4 GtkEntry and GtkTextView widgets.

If the user chooses this, a popup window appears and begins populating with emojis at a rate of about 5 per second. Since there are thousands of emojis, it takes many minutes before this completes. Once it does, it seems to be cached and the next time the user right clicks and chooses ‘insert emoji’ it appears without problem.

The problem is that if the user dismisses the ‘insert emoji’ popup before it completes populating, the next time they go to ‘insert emoji’, first nothing happens and then when they ‘insert emoji’ again the whole screen freezes for several minutes.

Is this a programming, GTK4 or an OS (Fedora 40) issue?

Can the emojis be pre-cached programmatically?

Michael

Loading is close to immediate on my PC…

Have you a Nvidia GPU?
Can you try setting the environment variable GSK_RENDERER=gl ?

Its an ATI Radeon RX580 card and no that didn’t help.
Also, I noticed that once I initiated the emoji pop-up, then tried to exit the program, it will not finish until (it seems) all the emojis have been parsed. (the GTK window disappears but the program doesn’t end for several minutes).

Edit … I just tried it on another machine and it was fine… I wonder what it is about this system that is different??

Edit (again) … It looks like an own goal. I removed my .local/share/font directory and it fixed it. I guess there must be a bad font that is causing this!

Edit (again, again) … it was NotoColorEmoji-Regular.ttf … I guess it caused some sort of conflict with the identically named font from …

google-noto-color-emoji-fonts-20231130-1.fc40.noarch : Google “Noto Color Emoji” colored emoji font
Repo        : @System
Matched from:
Filename    : /usr/share/fonts/google-noto-color-emoji-fonts/NotoColorEmoji.ttf
1 Like

This topic was automatically closed 30 days after the last reply. New replies are no longer allowed.