[prev in list] [next in list] [prev in thread] [next in thread] 

List:       kde-frameworks-devel
Subject:    Re: There's no proper replacement for KIcon
From:       Albert Astals Cid <aacid () kde ! org>
Date:       2014-09-07 8:27:06
Message-ID: 2816514.n5KPPdtGZQ () xps
[Download RAW message or body]

El Dijous, 4 de setembre de 2014, a les 14:04:04, Kevin Ottens va escriure:
> On Thursday 04 September 2014 11:36:38 Martin Klapetek wrote:
> > On Wed, Sep 3, 2014 at 10:10 PM, Eike Hein <hein@kde.org> wrote:
> > > On 09/03/2014 10:07 PM, Nicol=E1s Alvarez wrote:
> > >> So if I'm not in a Plasma session I get no icons?
> > > =

> > > If you're not in a Plasma session you don't get the Plasma
> > > platform plugin. Other platform plugins can drive this as
> > > they prefer.
> > =

> > Isn't that the task of the given platform plugin? Eg. if I run my app in
> > Gnome, there should be a Gnome plugin which provides its own icon plugin
> > and loads Gnome icons (well in an ideal world, anyway) and thus making =
the
> > app actually look more "integrated"...in other words, shouldn't this
> > problem be moved there?
> =

> Spot on. And such a plugin is in fact shipped with Qt, but for some reason
> isn't loaded in Albert's case. That awfully sounds like a bug to me, hence
> why my line of argument is that it should be investigated and fixed.

My setup & investigation:
 * Plasma 4 logged in with tsdgeos
 * konsole logged in to kdeunstable via "su - kdeunstable"
 * I'm using the QGenericUnixTheme QPT (aka PlatformTheme) =

 * QGenericUnixTheme uses XDG_CURRENT_DESKTOP, KDE_FULL_SESSION, =

GNOME_DESKTOP_SESSION_ID or DESKTOP_SESSION environment variables to decide=
 in =

which desktop environment you are
 * Since none of those environment variables are defined in my kdeunstable =

user it falls back to the "UNKNOWN" desktop environment
 * Then it goes to QGenericUnixTheme::themeNames and since it's not a known =

desktop it will default to QGenericUnixTheme as QPT instead of to QKdeTheme=
 or =

QGnomeTheme for icon theme handling
 * Then QGenericUnixTheme::themeHint does not implement =

QPlatformTheme::SystemIconThemeName and =

QPlatformTheme::SystemIconFallbackThemeName defaults to hicolor
 * And hicolor is not a "proper" theme, just a fallback theme, so it is not =

designed to hold icons for the majority of icons.

One could say the bug is in QGenericUnixTheme::themeHint that should actual=
ly =

provide a meaningul icon theme instead of "hicolor" as default.

The problem is that there is not (or I could not find it) a "xdg-way" to =

set/get the current icon theme so it's hard not to default to something =

different than "hicolor", one possibility would be making =

QGenericUnixTheme::themeHint default to say the first icon theme in =

xdgIconThemePaths, but that's obviously not that great either.

So as I see it, there's three options:
 * Do nothing, and expect that people have to set one of XDG_CURRENT_DESKTO=
P, =

KDE_FULL_SESSION, GNOME_DESKTOP_SESSION_ID or DESKTOP_SESSION environment =

variables to get icons
 * Do the change/hack to QGenericUnixTheme::themeHint return any of the the=
mes =

in xdgIconThemePaths that is not hicolor
 * Talk to the xdg-people to include a way to get the current icon theme an=
d =

use that in QGenericUnixTheme::themeHint


Cheers,
  Albert

P.S: Sorry it took that much to answer, akademy+travel kept me busy.

> =

> Regards.

_______________________________________________
Kde-frameworks-devel mailing list
Kde-frameworks-devel@kde.org
https://mail.kde.org/mailman/listinfo/kde-frameworks-devel
[prev in list] [next in list] [prev in thread] [next in thread] 

Configure | About | News | Add a list | Sponsored by KoreLogic