On Sunday January 31 2016 12:10:05 David Faure wrote:

> On Sunday 31 January 2016 11:18:34 René J.V. Bertin wrote:
> > +    case QPlatformTheme::IconThemeSearchPaths:
> > +        if (QStandardPaths::isXDGLocationsEnabled()) {
> > +            return xdgIconThemePaths();
> > +        }
> 
> I don't think this requires an if() at all.
> It's not like Mac OSX has freedesktop icon themes natively installed...

It's kind of surprising if all your Qt applications (including those "pure Qt" 
ones like Qt Creator) start showing icons everywhere all of a sudden after 
installing even a single freedesktop icon theme. I may be particularly allergic 
to this, but it's a fact that Apple's HIG do not call for icons on buttons.

I just tried to assess how "bad" the situation is without the if() but with the
+    case QPlatformTheme::DialogButtonBoxButtonsHaveIcons:
+        return false;

addition. I must admit that I'm not seeing any unwanted icons even after 
commenting out the ifs, I don't really understand. Maybe something else was off 
earlier, maybe I'm not reproducing the correct test case ... something else to 
add to my todo list.

Edit: you're indeed right ... when there is something like a global XDG mode 
switch. xdgIconThemePaths() uses QSP to determine the path to the icon theme 
repository, and that will not be the freedesktop path if XDG mode isn't used ;)

> i.e. it seems to me that this unbreaks QIcon::fromTheme() on OSX,
> which was until now searching ... nowhere. Right?

Yes, QIcon::fromTheme() doesn't work on OS X because it doesn't know where to 
look except possibly in the qrc (?) resource (i.e. a feature I don't have 
personal experience with).

R.
_______________________________________________
Kde-frameworks-devel mailing list
Kde-frameworks-devel@kde.org
https://mail.kde.org/mailman/listinfo/kde-frameworks-devel

Reply via email to