You are not logged in.

#1 2021-04-16 14:47:42

darrSonik
Member
Registered: 2021-01-01
Posts: 8

[SOLVED] Use GTK file chooser for Qt apps

Hi!
I've been searching for how to use GTK file picker for Qt apps, but all could I find that how I can use Qt file chooser for GTK apps by setting an environment variable.
Is it possible to use GTK file chooser for Qt apps?

I'm not using a full desktop environment like GNOME, KDE and else.

Thanks In Advance.

Last edited by darrSonik (2021-04-19 07:27:55)

Offline

#2 2021-04-16 15:50:40

arojas
Developer
From: Spain
Registered: 2011-10-09
Posts: 2,093

Re: [SOLVED] Use GTK file chooser for Qt apps

export QT_QPA_PLATFORMTHEME=gtk3

Offline

#3 2021-04-18 08:41:19

darrSonik
Member
Registered: 2021-01-01
Posts: 8

Re: [SOLVED] Use GTK file chooser for Qt apps

Thanks! Although setting the value 'gtk2' instead of 'gtk3' worked for me.

Another question, I thought it's related that's why I'm asking.
I tried setting QT_STYLE_OVERRIDE=gtk3 before, it didn't work for me, spitting a bunch of errors. When I used gtk2, it worked. The same thing happened now as well. Am I missing something? Did I not upgrade properly?

Offline

#4 2021-04-19 06:38:05

arojas
Developer
From: Spain
Registered: 2011-10-09
Posts: 2,093

Re: [SOLVED] Use GTK file chooser for Qt apps

darrSonik wrote:

Another question, I thought it's related that's why I'm asking.
I tried setting QT_STYLE_OVERRIDE=gtk3 before, it didn't work for me, spitting a bunch of errors. When I used gtk2, it worked. The same thing happened now as well. Am I missing something? Did I not upgrade properly?

There are no official gtk2 or gtk3 styles for Qt. There is an buggy and unsupported gtk2 style shipped in the package qt5-styleplugins which is probably what you're seeing.

Offline

#5 2021-04-19 07:26:17

darrSonik
Member
Registered: 2021-01-01
Posts: 8

Re: [SOLVED] Use GTK file chooser for Qt apps

Thanks for clearing that up! big_smile

Offline

Board footer

Powered by FluxBB