[Out-of-scope] FreeCAD not adopting Desktop theme
Forum rules
Be nice to others! Respect the FreeCAD code of conduct!
Be nice to others! Respect the FreeCAD code of conduct!
-
- Posts: 73
- Joined: Tue Feb 22, 2022 9:16 pm
[Out-of-scope] FreeCAD not adopting Desktop theme
The only conversation that comes close to the issue I raise is that in
https://forum.freecadweb.org/viewtopic. ... &start=110 , but it seems to focus on other aspects of appearance.
When I open FreeCAD 0.18.4, FreeCAD adopts the colouring from my Desktops default theme, which is dark, on UbuntuMATE. I looks like this, which is what I prefer:
When I open FreeCAD 0.19, FreeCAD appears to ignores colours from the Desktop theme.
I looked thru preferences, but there is no mention there of a built-in option for light/dark interface, nor an option to adopt/ignore the Desktop theme's colouring scheme, resulting in the following appearance:
Is there some manual technique to circumvent this restriction? A assumed fixed configuration file which can be modified?
Please note that I am using the following binary:
FreeCAD_0.19.3-Linux-Conda_glibc2.12-x86_64.AppImage
https://forum.freecadweb.org/viewtopic. ... &start=110 , but it seems to focus on other aspects of appearance.
When I open FreeCAD 0.18.4, FreeCAD adopts the colouring from my Desktops default theme, which is dark, on UbuntuMATE. I looks like this, which is what I prefer:
When I open FreeCAD 0.19, FreeCAD appears to ignores colours from the Desktop theme.
I looked thru preferences, but there is no mention there of a built-in option for light/dark interface, nor an option to adopt/ignore the Desktop theme's colouring scheme, resulting in the following appearance:
Is there some manual technique to circumvent this restriction? A assumed fixed configuration file which can be modified?
Please note that I am using the following binary:
FreeCAD_0.19.3-Linux-Conda_glibc2.12-x86_64.AppImage
- Attachments
-
- FreeCAD_0.18.4.png (155.01 KiB) Viewed 2296 times
Last edited by eajmarceau on Sun May 08, 2022 6:35 pm, edited 1 time in total.
Re: FreeCAD not adopting Desktop theme
FreeCAD is using Qt.
Mate is using GTK.
There are ways to make Qt use same theme settings or "replicate the behaviour" of a Gtk Theme.
But they are "two different world".
This "translation" however is not perfect, as Tollkits are different.
This is "a fact" that is shared among many other programs, there are "workarounds" and they depend on some external programs, and system settings.
You could try to make some search about "Qt and Gtk appearance" and see if something will work for you.
EDIT: FC has a dark theme, i dont' know when it was implemented, as something is changed between 0.19 and 0.20, and I'm using 0.20, try to search something about "FreeCAD dark theme" in this forum, probably with a "web engine" as internal forum search probably will complains about "too common terms in search"
Regards
Carlo D.
Mate is using GTK.
There are ways to make Qt use same theme settings or "replicate the behaviour" of a Gtk Theme.
But they are "two different world".
This "translation" however is not perfect, as Tollkits are different.
This is "a fact" that is shared among many other programs, there are "workarounds" and they depend on some external programs, and system settings.
You could try to make some search about "Qt and Gtk appearance" and see if something will work for you.
EDIT: FC has a dark theme, i dont' know when it was implemented, as something is changed between 0.19 and 0.20, and I'm using 0.20, try to search something about "FreeCAD dark theme" in this forum, probably with a "web engine" as internal forum search probably will complains about "too common terms in search"
Regards
Carlo D.
GitHub page: https://github.com/onekk/freecad-doc.
- In deep articles on FreeCAD.
- Learning how to model with scripting.
- Various other stuffs.
Blog: https://okkmkblog.wordpress.com/
- In deep articles on FreeCAD.
- Learning how to model with scripting.
- Various other stuffs.
Blog: https://okkmkblog.wordpress.com/
-
- Posts: 73
- Joined: Tue Feb 22, 2022 9:16 pm
Re: FreeCAD not adopting Desktop theme
Thank you, Carlo. I tried version 20 and as you mentionned, there is a colour theme drop-down menu option. That worked very well.
Just one comment about that: It seemed (I might be wrong) that the set of colours for various GUI actions/highlighting is constant, rather than having a set of colours that best fits each of those theme options. I had to go in to modify the colours to some that are actually usable instead of what was default for the "ProDark" theme.
These are colours that seemed to have better contrast, IMHO.
- FreeCAD Version 0.20
- Kernel: 5.4.0-107-generic x86_64 bits: 64 compiler: gcc v: 9.4.0 Desktop: MATE 1.24.0 info: mate-panel wm: marco 1.24.0 dm: LightDM 1.30.0 Distro: Ubuntu 20.04.4 LTS (Focal Fossa)
- Graphics: Device-1: Advanced Micro Devices [AMD/ATI] RS780D [Radeon HD 3300] vendor: ASUSTeK driver: radeon v
Just one comment about that: It seemed (I might be wrong) that the set of colours for various GUI actions/highlighting is constant, rather than having a set of colours that best fits each of those theme options. I had to go in to modify the colours to some that are actually usable instead of what was default for the "ProDark" theme.
These are colours that seemed to have better contrast, IMHO.
- FreeCAD Version 0.20
- Kernel: 5.4.0-107-generic x86_64 bits: 64 compiler: gcc v: 9.4.0 Desktop: MATE 1.24.0 info: mate-panel wm: marco 1.24.0 dm: LightDM 1.30.0 Distro: Ubuntu 20.04.4 LTS (Focal Fossa)
- Graphics: Device-1: Advanced Micro Devices [AMD/ATI] RS780D [Radeon HD 3300] vendor: ASUSTeK driver: radeon v
Re: FreeCAD not adopting Desktop theme
Probably it is better to make a similar post in the UX/UI section of the forum, where the Theme matters are discussed.eajmarceau wrote: ↑Tue Apr 05, 2022 2:14 am Just one comment about that: It seemed (I might be wrong) that the set of colours for various GUI actions/highlighting is constant, rather than having a set of colours that best fits each of those theme options. I had to go in to modify the colours to some that are actually usable instead of what was default for the "ProDark" theme.
I think that maybe here, some improvement could be done, maybe not for 0.20 "stable" but for "0.21dev" (1.0 maybe) this improvement I think will be appreciated.
I don't like too much dark themes, probably I'm old school, having started with a C64 with a TV as monitor and having done some programming on old "IBM AT 286" with monochrome monitor with "green pixels", when color have permitted to use "white background" I was so pleased that I'm already not prone to "return to origins"
PS: I check the contrast in the monitor to avoid to much light, or prefer some "pastel color" for background, I know that "dark themes" have some "good reasons to exist".
Regards
Carlo D.
GitHub page: https://github.com/onekk/freecad-doc.
- In deep articles on FreeCAD.
- Learning how to model with scripting.
- Various other stuffs.
Blog: https://okkmkblog.wordpress.com/
- In deep articles on FreeCAD.
- Learning how to model with scripting.
- Various other stuffs.
Blog: https://okkmkblog.wordpress.com/
Re: FreeCAD not adopting Desktop theme
Is this an AppImage or does it use your system Qt version? What version is that?eajmarceau wrote: ↑Sat Apr 02, 2022 4:10 am When I open FreeCAD 0.18.4, FreeCAD adopts the colouring from my Desktops default theme, which is dark, on UbuntuMATE. I looks like this, which is what I prefer:
Which Qt version is that?When I open FreeCAD 0.19, FreeCAD appears to ignores colours from the Desktop theme.
In FreeCAD there are no settings to actively suppress to use the desktop theme. If you set a Qt style sheet file this is used and if no style sheet is selected the default desktop theme is supposed to be used.I looked thru preferences, but there is no mention there of a built-in option for light/dark interface, nor an option to adopt/ignore the Desktop theme's colouring scheme, resulting in the following appearance:
What I can imagine is that for the AppImage a Qt plugin is missing that would "translate" GTK appearance into Qt appearance. When you check the content of the AppImage is there a file called libqgtk3.so?
But I wonder why your v0.18 apparently uses the theme icons while v0.19 uses FreeCAD default icons. I don't know if this can be caused by the lack of a plugin.
Re: FreeCAD not adopting Desktop theme
It shows that removing the libqgtk3.so plugin causes FreeCAD to use the built-in FreeCAD icon theme.
Here I have an AppImage for version 0.19-23141 and that lacks of the libqgtk3.so plugin.When you check the content of the AppImage is there a file called libqgtk3.so?
Re: FreeCAD not adopting Desktop theme
On Ubuntu there is a package called qt5-style-plugins that provides libqgtk2style.so that seems to be needed in order to follow more or less the desktop scheme. Even with the system Qt version FreeCAD ignores the desktop scheme if this package is not installed.
There is an additional package qt5ct that allows to adjust the provided Qt styles. In order to start the application you must set the environment variable:
There is an additional package qt5ct that allows to adjust the provided Qt styles. In order to start the application you must set the environment variable:
Code: Select all
export QT_QPA_PLATFORMTHEME=qt5ct
-
- Posts: 73
- Joined: Tue Feb 22, 2022 9:16 pm
Re: FreeCAD not adopting Desktop theme
Thank you, wmayer, for looking at this and your comments.
In my original post, I indicated that the latest version used was More details at bottom.
The version of 0.18.4 used was provided with the UbuntuMATE 20.04 LTS distro, namely
For package "qt5ct", I found that and installed it. I will let you know how that modifies the behaviour that I see in FreeCAD.
For package "qt5-style-plugins", that is not available in my 20.04 LTS distro. I also looked for each of "libqgtk2style.so, "libqgtk2style", "libqgtk2" and "gtk2style" ... and found nothing.
UbuntuMATE 22.04 is coming out soon. I will be sure to revisit your suggestions when I have upgraded my OS. Hopefully, all necessary packages will be included in that LTS distro.
----------------------------------------------------------------------------------------------------------
Version: (dowloaded from FreeCAD site)
FreeCAD_weekly-builds-28611-Linux-Conda_glibc2.12-x86_64.AppImage (used to verify issue), and
FreeCAD_0.19.3-Linux-Conda_glibc2.12-x86_64.AppImage (used to verify issue), and
FreeCAD 0.18.4 (primary tool; from LTS distro)
Distro: Ubuntu 20.04.4 LTS (Focal Fossa)
Kernel: 5.4.0-107-generic x86_64 bits: 64 compiler: gcc v: 9.4.0
Desktop: MATE 1.24.0 info: mate-panel wm: marco 1.24.0 dm: LightDM 1.30.0
CPU: Speed: 800 MHz min/max: 800/2600 MHz
Mobo: ASUSTeK model: M4A78-E v: Rev 1.xx
CPU: Topology: Quad Core model: AMD Phenom II X4 810 bits: 64 type: MCP arch: K10
Memory: RAM: total: 3.59 GiB used: 2.04 GiB (56.7%)
Graphics: Device-1: Advanced Micro Devices [AMD/ATI] RS780D [Radeon HD 3300] vendor: ASUSTeK
Drives: Local Storage: total: 1.82 TiB used: 967.00 GiB (51.9%)
In my original post, I indicated that the latest version used was
Code: Select all
FreeCAD_0.19.3-Linux-Conda_glibc2.12-x86_64.AppImage
The version of 0.18.4 used was provided with the UbuntuMATE 20.04 LTS distro, namely
Code: Select all
0.18.4+dfsg2-1ubuntu4
For package "qt5-style-plugins", that is not available in my 20.04 LTS distro. I also looked for each of "libqgtk2style.so, "libqgtk2style", "libqgtk2" and "gtk2style" ... and found nothing.
UbuntuMATE 22.04 is coming out soon. I will be sure to revisit your suggestions when I have upgraded my OS. Hopefully, all necessary packages will be included in that LTS distro.
----------------------------------------------------------------------------------------------------------
Version: (dowloaded from FreeCAD site)
FreeCAD_weekly-builds-28611-Linux-Conda_glibc2.12-x86_64.AppImage (used to verify issue), and
FreeCAD_0.19.3-Linux-Conda_glibc2.12-x86_64.AppImage (used to verify issue), and
FreeCAD 0.18.4 (primary tool; from LTS distro)
Distro: Ubuntu 20.04.4 LTS (Focal Fossa)
Kernel: 5.4.0-107-generic x86_64 bits: 64 compiler: gcc v: 9.4.0
Desktop: MATE 1.24.0 info: mate-panel wm: marco 1.24.0 dm: LightDM 1.30.0
CPU: Speed: 800 MHz min/max: 800/2600 MHz
Mobo: ASUSTeK model: M4A78-E v: Rev 1.xx
CPU: Topology: Quad Core model: AMD Phenom II X4 810 bits: 64 type: MCP arch: K10
Memory: RAM: total: 3.59 GiB used: 2.04 GiB (56.7%)
Graphics: Device-1: Advanced Micro Devices [AMD/ATI] RS780D [Radeon HD 3300] vendor: ASUSTeK
Drives: Local Storage: total: 1.82 TiB used: 967.00 GiB (51.9%)
- adrianinsaval
- Veteran
- Posts: 5548
- Joined: Thu Apr 05, 2018 5:15 pm
Re: FreeCAD not adopting Desktop theme
the version from apt has access to whatever qt style your system has, the appimage doesn't have it, if you used 0.19 or 0.20 from the ppa it will likely work. I don't think including those styles in the appimage makes much sense, if whatever this one is is included then the next style that doesn't work should be added too (I would love to have breeze on the appimage for example), were do we draw the line? Also if it is the gtk2 style, that one is pretty buggy IIRC so not a good idea anyways.