Icons of Select File window disappear with Dark themes

A forum for research and development of the user interface of FreeCAD
Forum rules
Be nice to others! Respect the FreeCAD code of conduct!
User avatar
turn211
Posts: 162
Joined: Mon Feb 01, 2021 11:37 pm

Re: Icons of Select File window disappear with Dark themes

Post by turn211 »

bitacovir wrote: Wed Apr 07, 2021 11:27 am Sorry, I forgot to mention the actual command.
In DraftWB - Draft ShapeString command - In the panel, option "..." of Font file.
You are right that icons in other windows work fine. In my case too. But in this window icons are shown very tiny in dark themes.
Aha! Under further investigation, all Light and Dark stylesheets are broken. Don't know why yet? Maybe they always were? I'll look into the problem.
User avatar
turn211
Posts: 162
Joined: Mon Feb 01, 2021 11:37 pm

Re: Icons of Select File window disappear with Dark themes

Post by turn211 »

Fixed by inserting the following code above Tool Button inside QDialogs.... roughly Line 1520 in all stylesheets. Can someone try this on their box. If good someone will have to make a PR for all Stylesheets except ProDark (I'll take care of that). These PRs and commits should be in the 0.19.2 release.

Code: Select all

/*==================================================================================================
Tool button Icon fix in save dialogs
==================================================================================================*/
/* found under Tools -> Save Picture */ /* Draft -> ShapeString -> Font file */

QFileDialog#QFileDialog QToolButton {
    background-color: transparent;
    padding: 1px;
    border: 1px;
    margin: 0px;
}

*==================================================================================================
Tool button inside QDialogs that works as QPushButtons
==================================================================================================*/
/* found under Tools -> Customize -> Macros -> Pixmap "..." button */
QDialog QToolButton {
User avatar
chennes
Veteran
Posts: 3904
Joined: Fri Dec 23, 2016 3:38 pm
Location: Norman, OK, USA
Contact:

Re: Icons of Select File window disappear with Dark themes

Post by chennes »

I'll take care of making the PR for the other stylesheets, it will be ready in a few minutes.
Chris Hennes
Pioneer Library System
GitHub profile, LinkedIn profile, chrishennes.com
User avatar
chennes
Veteran
Posts: 3904
Joined: Fri Dec 23, 2016 3:38 pm
Location: Norman, OK, USA
Contact:

Re: Icons of Select File window disappear with Dark themes

Post by chennes »

Chris Hennes
Pioneer Library System
GitHub profile, LinkedIn profile, chrishennes.com
Post Reply