Gentoo Forums
Gentoo Forums
Gentoo Forums
Quick Search: in
Purpose of GTK use flag for dev-qt/qtbase and qtwidgets
View unanswered posts
View posts from last 24 hours
View posts from last 7 days

 
Reply to topic    Gentoo Forums Forum Index Desktop Environments
View previous topic :: View next topic  
Author Message
nagmat84
Apprentice
Apprentice


Joined: 27 Mar 2007
Posts: 285

PostPosted: Sun Dec 15, 2024 4:50 pm    Post subject: Purpose of GTK use flag for dev-qt/qtbase and qtwidgets Reply with quote

Today I noticed that the packages dev-qt/qtbase and dev-qt/qtwidgets also support the GTK use flag. What is the purpose of that use flag? What do I gain or loose if I enable/disable the use flag? (Currently it is disabled.)

I am on a "pure" Qt/Plasma/KDE system and KDE is the only desktop environment in use. Hence, "gtk" is disabled on a global level. However, I also run some GTK applications, e.g. GIMP and Firefox. I have selectively enabled the GTK use flag for kde-plasma/plasma-meta and kde-plasma/print-manager to enable the Plasma Breeze theme for GTK applications and have the KDE print dialog in GTK applications.

Does the GTK use flag for dev-qt/qtbase and dev-qt/qtwidgets serve a similar purpose? If yes, what do I gain, if enabled?
Back to top
View user's profile Send private message
rab0171610
Guru
Guru


Joined: 24 Dec 2022
Posts: 440

PostPosted: Sun Dec 15, 2024 5:34 pm    Post subject: Reply with quote

You cannot "loose" anything but you may "lose" something.

Quote:
I am on a "pure" Qt/Plasma/KDE system and KDE is the only desktop environment in use. Hence, "gtk" is disabled on a global level.

That is flawed logic. There are other factors to consider when disabling a use flag globally, especially when you do not even know what that use flag does for your particular set of installed packages. That is evident in the fact that you are asking what the gtk use flag does for two particular packages installed on your system.
If you are going to disable a use flag globally, possibly overriding your default profile, at least do the research and find out if that is in your best interests. Then, make an informed decision, not a haphazard guess.
In this particular case, one thing you would may want to refer to is:
https://packages.gentoo.org/useflags/gtk
Both of those packages you refer to have the gtk use flag to "Build the GTK platform theme plugin". My assumption from looking at the source code is that it is simply used for theming purposes. Using KDE Plasma, I would assume, maybe incorrectly, that will affect System Settings>Colors and Themes>Application Style. Click on the 3 dots in the top right corner next to Configure Icons and Toolbars and you will see a popup option for "Configure Gnome/GTK application style."
Another thing to consider is whether or not a use flag is enabled on your system due to your default profile. Remove any reference to gtk in make.conf (USE=gtk or USE=-gtk). Run 'emerge --info' or 'emerge --info | grep gtk' (to highlight the word gtk in the results). If it shows up in the output (USE=gtk) and you did not explicitly enable or disable it, then it is likely enabled by the profile. Unless you have specific, informed reasons to globally disable use flags enabled by your profile, you should generally just leave it enabled.
Back to top
View user's profile Send private message
nagmat84
Apprentice
Apprentice


Joined: 27 Mar 2007
Posts: 285

PostPosted: Sun Dec 15, 2024 7:03 pm    Post subject: Reply with quote

Quote:
That is evident in the fact that you are asking what the gtk use flag does for two particular packages installed on your system.
Unfortunately, the in-depth meaning of a use flag for a particular is usually not well documented. That is not meant to offense anybody. It is just an observation. I myself know that documentation is very often an unloved task and as we are all volunteers. Hence, nobody has the obligation to write documentation.
Quote:
If you are going to disable a use flag globally, possibly overriding your default profile, at least do the research and find out if that is in your best interests. Then, make an informed decision, not a haphazard guess.
I did. I usually even go to the upstream site (in this case Qt) to find something in their build documentation, because usually use flags correspond to a flag for the configuration script of the build system. But in this case nothing useful popped up.
The Gentoo Wiki: KDE - Use flags as describes the meaning of the GTK use flag at least for "kde-plasma/plasma-meta". So yes, I did my research.
Quote:
Using KDE Plasma, I would assume, maybe incorrectly, that will affect System Settings>Colors and Themes>Application Style. Click on the 3 dots in the top right corner next to Configure Icons and Toolbars and you will see a popup option for "Configure Gnome/GTK application style."
Well, you are indeed incorrect here. The only use flag which is needed for that is the GTK use flag on "kde-plasma/plasma-meta" which then pulls in "kde-plasma/breeze-gtk" and "de-plasma/kde-gtk-config". The GTK use flag for dev-qt/qtbase and dev-qt/qtwidgets is not needed for that. So you are guessing yourself here. Hence, my question doesn't seem to be so dumb at all.
Quote:
In this particular case, one thing you would may want to refer to is: https://packages.gentoo.org/useflags/gtk
This doesn't explain what the use flag does for each package. That only shows which package use that use flag.
Quote:
Another thing to consider is whether or not a use flag is enabled on your system due to your default profile. Remove any reference to gtk in make.conf (USE=gtk or USE=-gtk). Run 'emerge --info' or 'emerge --info | grep gtk' (to highlight the word gtk in the results). If it shows up in the output (USE=gtk) and you did not explicitly enable or disable it, then it is likely enabled by the profile.
Well, there are other options to find out whether the profile enables the use flag ( for example using ufed). However, this doesn't answer the question either.
Back to top
View user's profile Send private message
Display posts from previous:   
Reply to topic    Gentoo Forums Forum Index Desktop Environments All times are GMT
Page 1 of 1

 
Jump to:  
You cannot post new topics in this forum
You cannot reply to topics in this forum
You cannot edit your posts in this forum
You cannot delete your posts in this forum
You cannot vote in polls in this forum