Recent Versions of GLib Break Dolphin File-Manager's Thumbnailing when Using 'gtk2' Style
Hi, everyone. When the Arch Linux-based package 'qt5-styleplugins' is used and the environment variable QT_QPA_PLATFORMTHEME= is set on "gtk2", or "qt5ct" with its interface set on Appearance > Style: gtk2, the Dolphin file-manager will not create new thumbnails, although thumbnails that were previously created (such as with Thunar, or Dolphin not using "gtk2") will be shown. This problem doesn't occur with the other styles of 'qtstyleplugins'.
I traced this problem back to GLib. The problem was introduced with the following package, and remains in later versions:
glib2-2.62.1-1-x86_64.pkg.tar.xz
The following version and previous versions work properly:
glib2-2.60.6-1-x86_64.pkg.tar.xz
However, using this previous version breaks some (but not all) GTK+ 3 programs.
This is a shame because I use the "gtk2" style for Qt 5 programs, and Dolphin is my primary file-manager. Further, this breaks my Computing Machine desktop-environment theme ( https://www.pling.com/p/1315191/ ).
Can this problem please be fixed? Thank you for your time on this matter!
- Maintainer
How did you trace this issue to GLib? What does QtPlatform define as ‘gtk2’?
We are going to need some more context to understand why this would be a GLib bug, as opposed to a qt style plugin issue.
Hi, Emmanuele Bassi. My process was that I replaced (using 'downgrade') with previous known working versions any package that I thought might be connected to Dolphin's thumbnailing or its theming (including Dolphin itself), yet nothing had any effect. Then I thought to start Dolphin in a 'uxterm' in order to see the output. That's when I saw that GLib was outputting errors that were causing '/usr/lib/qt/plugins/kf5/kio/thumbnail.so' to crash. Upon seeing that, when I replaced the GLib package as related in my above originating post, thumbnailing worked.
What I take the GLib error messages (involving 'platform_get_argv0' in the output) to mean is that GLib doesn't recognize the platform "gtk2", and that then causes 'thumbnail.so' to crash. Thus, in order for 'thumbnail.so' to work, apparently it requires GLib not to exit with error messages like that upon not recognizing the platform.
I here provide three PNGs of 'uxterm' output when Dolphin is started in it. 'Dolphin-thumbnailing-working-Windows-style-via-qt5ct.png' is when the 'qt5ct' program is set on the "Windows" style, and thumbnailing works. 'Dolphin-thumbnailing-failing-gtk2-style-via-qt5ct.png' is when the 'qt5ct' program is set on the "gtk2" style, and thumbnailing doesn't work. 'Dolphin-thumbnailing-failing-gtk2-style-direct.png' is when QT_QPA_PLATFORMTHEME= is directly set on "gtk2", and thumbnailing doesn't work.
Whether the style is set via the 'qt5ct' program or is directly set with QT_QPA_PLATFORMTHEME= doesn't matter to this problem. If "gtk2" is the style, thumbnailing fails either way, yet every other style works.
Regarding your question, "What does QtPlatform define as ‘gtk2’?" At this moment I don't know how to parse that, and so at this moment I do not know the answer to this question.
I hope the above information is helpful in fixing this problem. Thank you for your time!
Edited by Jamie Michelle