GNOME/GTK Application tooltips are stretched/distorted

Original thread - (GeForce RTX 4070) GTK application issue with NVIDIA GPU.
GNOME Bug report - Tooltips are stretched (#5832)

Reposting the thread with a more descriptive title for additional clarity/discoverability. In GTK applications, some menus and tooltips become stretched/improperly sized.

Have personally seen this issue crop up in GNOME Software dropdown menus and hover tooltips in any GTK applications. It’s especially apparent in GNOME Builder (IDE) with auto-completion.

A couple examples from the GitLab issue -

3 Likes

Thanks for creating an updated topic here.

NOTE: This only affects GTK4 apps. Tooltips in GTK3 apps are displayed properly.

  • Arch Linux | Kernel 6.7.8
  • Gnome-shell | Mutter 46.rc
  • Wayland (meson_options: xwayland=false)
  • GTK 4.13.8.1
  • Mesa 24.0.2
  • nVidia 550.54.14

As one of the folks involved in the original GTK GitLab issue and original forum thread, I’ll add another screencast using Nautilus file manager as an example here.

This issue has persisted now for several iterations of nVidia Production Branch Linux drivers.

2 Likes

This issue is still present with the latest Production Branch drivers and graphics stack.

  • Arch Linux | Kernel 6.7.10
  • Gnome-shell | Mutter 46.0
  • Wayland (meson_options: xwayland=false)
  • Gtk4 4.14.1
  • Mesa 24.0.3
  • nVidia 550.67

Happy to see this issue has caught some interest from the nVidia side:

I’d always suspected that at least one nVidia dev must use GTK+Wayland haha!

Awesome! I recognize Erik’s name as he was involved in some other issues I was tracking (namely explicit sync). Glad to see it’s on their radar now :). Mentioned it’s too late for 555, but at least a fix is incoming some time in the future. Woohoo!

Two things to note on this old issue:

  1. A fix never landed still as of the 560 series drivers. I pinged Eric in the bug report, but no response yet.

  2. GTK 4.16 switched to Vulkan default, rendering (pun intended) this issue rather moot now. Tooltips are displayed properly with Vulkan.

1 Like

Unsurprisingly this issue is still present with nVidia 570.133.07 Production Branch drivers.

GTK4 application tooltips and popover dialogs are stretched/distorted/frozen.
This affects the GL and NGL renderers for GTK4 apps and is wildly annoying.

Linking back to overall summary tracker:

The old GL renderer was removed in the GTK 4.18.x release cycle.

As time marches on without any nVidia driver fixes, a few positive evolutions have mostly mitigated the pain points with this specific problem.

The changes in Nautilus 48.x to use newer Adwaita toolkit widgets combined with improvements landed in GTK 4.18.2 and 4.18.3 have made the stretched/frozen dialog issue nigh impossible to reproduce now. The tooltips are still a mess but that’s unimportant in comparison.

So, until the Vulkan rendering CPU usage issue is addressed by nVidia driver fixes, the NGL renderer for GTK 4 is now a viable workaround in the meanwhile.

1 Like

i wonder if this has the same root cause as this chromium bug

That doesn’t appear remotely related and it is reportedly specific to Xwayland.

AND, it has nothing to do with GTK4 or it’s rendering backend.

It may be a driver issue. Or, it may be a Chromium issue. Or, it may be a compositor issue. Or some combo thereof.

This issue is still present with nVidia 575.64 New Feature Branch driver.


Issue Summary:

‣ The effort by an nVidia developer to address this known issue was abandoned almost a year ago.


‣ GTK4 switched to the Vulkan backend as default in the meanwhile, leaving this NGL issue less prominent.


‣ Modern GTK 4.18 and Awaita 48 widget changes have mostly mitigated the areas where this bug manifested.


If an nVidia mod/dev would be so kind to supply the internal bug tracking number, I can add it to the tracker thread.

Per a parallel KDE thread…


Now tracking as:

nVidia internal tracking Bug #5382305

  • kernel 6.15.6
  • wlroots 0.19 (-D xwayland=disabled) (Vulkan Backend)
  • sway 1.11 (Native Wayland)
  • gtk4 4.18.6 (-Dx11-backend=false)
  • nVidia 575.64.03
  • egl-wayland2 1.00

EDIT:

Per the KDE-related thread, I’m now testing the egl-wayland2 library.

COMMAND    PID       USER  FD   TYPE DEVICE SIZE/OFF    NODE NAME
sway       852 tekstryder mem    REG  259,2    84512 1870808 /usr/lib/libnvidia-egl-wayland2.so.1.0.0
kgx       1014 tekstryder mem    REG  259,2    84512 1870808 /usr/lib/libnvidia-egl-wayland2.so.1.0.0
gnome-tex 1339 tekstryder mem    REG  259,2    84512 1870808 /usr/lib/libnvidia-egl-wayland2.so.1.0.0
nautilus  1447 tekstryder mem    REG  259,2    84512 1870808 /usr/lib/libnvidia-egl-wayland2.so.1.0.0
evolution 1679 tekstryder mem    REG  259,2    84512 1870808 /usr/lib/libnvidia-egl-wayland2.so.1.0.0
WebKitWeb 1758 tekstryder mem    REG  259,2    84512 1870808 /usr/lib/libnvidia-egl-wayland2.so.1.0.0
brave     1930 tekstryder mem    REG  259,2    84512 1870808 /usr/lib/libnvidia-egl-wayland2.so.1.0.0

Thanks @kbrenneman for pointing this new lib out!

Upon building today’s git main@1229d635… the tooltip issue with the GTK4 NGL renderer is resolved.

I suspect also the popover/dialog distortion issues noted over the course of this thread may too be resolved/improved, but as noted several times previously, they became very rare and difficult to reproduce with recent GTK/Adwaita releases.

I’ll wait to mark this SOLVED until egl-wayland2 is officially tagged & packaged for my distro, and the temporary-fix env var is no longer required. Hopefully in the 580 driver.

I will, however, update the tracking thread now. Sweet!

Thanks again to @kbrenneman for picking this up. 👍

@kbrenneman FYI, the env vars are still required to be set with the 580.65.06 Beta driver.

__EGL_EXTERNAL_PLATFORM_CONFIG_FILENAMES=/usr/share/egl/egl_external_platform.d/09_nvidia_wayland2.json:/usr/share/egl/egl_external_platform.d/15_nvidia_gbm.json

Otherwise both egl-wayland libraries are loaded and the OG lib wins (distorted).




EDIT:

Glad to see egl-wayland2 get its first tag.

As I’m packaging the 580.65.06 Beta driver anyway, I took things a step further and removed the older egl-wayland library package dependency and purged it from my system.

This allowed me to remove the env var as well.

So now I’ve just the default 580 driver + egl-wayland2 1.0.0-rc.

GL is all good in native Wayland environments.

  • kernel 6.15.9
  • hyprland 0.50.1 (-DNO_XWAYLAND:STRING=true)
  • sway 1.11 (Native Wayland)
  • wlroots 0.19 (Vulkan Backend) (-Dxwayland=disabled)
  • nVidia 580.65.06

When egl-wayland2 is out of RC I’ll request Arch package maintainers to package/dep the newer lib.

Cc: @ptr1337

egl-wayland2 can be installed alongside of egl-wayland. You dont need to remove the dependency from it. egl-wayland (1) can be still used as fallback for unsupported enviroments

2 Likes

Right, this was my configuration, only requiring the aforementioned environmental variables to prefer the newer lib.

Dropping the older lib locally was me just cleaning things up locally.

In case it wasn’t implicit, this request would simply be in addition.

Not asking to drop the egl-wayland dep.

Thanks for the quick response!

Currenly on git master @d4deb7c3.

I’ve used egl-wayland2 for over 2 months now exclusively, without egl-wayland.

Tempted to mark this thread as SOLVED, as the new lib introduces no regressions and solves all previous known issues with GTK4 app toolips and popover dialog windows distortion when using the NGL renderer backend.

Current stack:

  • kernel 6.16.7
  • hyprland 0.51.0 (-DNO_XWAYLAND:STRING=true)
  • sway 1.11 (Native Wayland)
  • wlroots 0.19 (Vulkan Backend) (-Dxwayland=disabled)
  • gtk4 4.18.6
  • nVidia 580.82.09
  • egl-wayland2 1.00 (git main@d4deb7c3)

I think you should wait until Nvidia switched by default to egl-wayland2 to mark this as solved

have you tested egl-wayland2 on KDE Plasma too?

I’m waiting until it’s officially distro-packaged, at least for Arch.

I’ve been packaging it myself locally in the meanwhile.

No. I use Hyprland. And sometimes Sway.

I was using Gnome when this whole issues started years ago with a change in GTK4, which exposed this nVidia driver bug, addressed by the new library.

The whole 3yr history is covered in this thread, its predecessor, and the original GTK bug… if you’re bored haha.

All linked in the OP.

1 Like

Well look at that, @ptr1337 packaged it up for Arch.

I’ll mark this 2.5yr old saga as SOLVED when it lands in [extra].

@shrublet As the OP, if you’re still kicking around on the forums, please do tag this as the solution. Thx!

1 Like