Bug 417780

Summary: Add firewall-applet-shields_down icon to Breeze icon theme
Product: [Plasma] Breeze Reporter: Wolfgang Bauer <wbauer1>
Component: IconsAssignee: visual-design
Severity: wishlist CC: fkrueger, kainz.a, nate
Priority: NOR    
Version: unspecified   
Target Milestone: ---   
Platform: Other   
OS: Linux   
Latest Commit: Version Fixed In: 5.68
Attachments: Screenshot showing the problem
Screenshot after manually adding a firewall-applet-shields_down icon

Description Wolfgang Bauer 2020-02-17 09:36:31 UTC
firewall-applet uses new icons for the system tray since version 0.7, firewall-applet-shield_up and firewall-applet-shield_down.
firewall-applet-shield_up is part of the breeze icon theme, but firewall-applet-shield_down is not. This is normally not a problem (because firewall-applet is used as fallback), but it causes the icon to be dark with dark themes so it's barely visible.

1. Set "Oxygen" as desktop theme (without changing the color scheme)
2. Install firewall-applet 0.7+ and run it (firewalld needs to be active)

The systray icon is dark on a dark background, and thus barely visible

Should be white.

Linux/KDE Plasma:
(available in About System)
KDE Plasma Version: 5.18.0
KDE Frameworks Version: 5.67.0
Qt Version: 5.14.1

This was originally filed downstream:

Creating a symlink (or copy) firewall-applet-shield_down -> firewall-applet fixes the problem, the icons gets recolored as expected then. (older firewall-applet versions used only the 'firewall-applet' icon so are/were not affected)
This might point to a bug in the icon loader when doing the fallback, I suppose.
Comment 1 Wolfgang Bauer 2020-02-17 10:05:07 UTC
Created attachment 126097 [details]
Screenshot showing the problem

Attached a screenshot with "Oxygen" as desktop theme and "Breeze" color scheme.
Comment 2 Wolfgang Bauer 2020-02-17 10:07:56 UTC
Created attachment 126098 [details]
Screenshot after manually adding a firewall-applet-shields_down icon

And another screenshot how it looks after I manually added firewall-applet-shields_down.svg (as a symlink to firewall-applet.svg), the icon is white now as it should be.

So, to summarize, this could be fixed just by adding firewall-applet-shields_down to the breeze icon theme (even if it is just a symlink to the existing firewall-applet icon).

But to me it seems to be a glitch in the icon loader, that maybe should be investigated as well.
Comment 3 Wolfgang Bauer 2020-02-17 10:15:52 UTC
Btw, the same happens with the "Breeze Dark" desktop theme, so it's not specific to "Oxygen"...
Comment 4 Wolfgang Bauer 2020-02-17 10:30:01 UTC
And perhaps I should add that it doesn't make a difference whether I use "breeze" or "breeze-dark" as icon theme (and deleting ~/.cache/icon-cache.kcache doesn't change anything either, so it's not due to an outdated icon cache).
Comment 5 Wolfgang Bauer 2020-02-23 16:20:30 UTC
The color problem for fallback icons will be fixed by https://phabricator.kde.org/D27589, I just tried it out.

So it wouldn't really be necessary anymore to actually add the firewall-applet-shields_down icon explicitly.
Comment 6 Nate Graham 2020-02-23 16:30:31 UTC
Oh, that's nice!
Comment 7 David Redondo 2020-03-02 10:55:41 UTC
Git commit b7fa6e0e916bd8856cbf85b2d3886bc1e7b0e278 by David Redondo.
Committed on 02/03/2020 at 10:55.
Pushed by davidre into branch 'master'.

Try to apply the colorscheme of the current theme to QIcons

Before icons loaded internally with QIcon::fromTheme were being colored with the
colors from the current global color scheme instead of the ones from the current
Plasma Theme. Leading to visual bugs when the two differ. This happened because
KIconLoader uses the global color scheme by default.
A prominent case is the notification send by the network plasmoid when one
successfully connected to a wireless network. It sets the icon
"network-wireless-on" which is not included in Breeze icons (but is included in
Breeze Plasma Theme). If the current icon theme is indeed Breeze, IconItem
resorts to using QIcon::fromTheme and we end up with a wrong colored
"network-wireless" icon.

Test Plan:


Reviewers: #plasma, cblack, ngraham, mart

Reviewed By: #plasma, cblack, ngraham, mart

Subscribers: mart, wbauer, cblack, kde-frameworks-devel

Tags: #frameworks

Differential Revision: https://phabricator.kde.org/D27589

M  +4    -0    src/declarativeimports/core/iconitem.cpp
M  +2    -0    src/plasma/private/theme_p.cpp
M  +1    -0    src/plasma/private/theme_p.h
M  +6    -0    src/plasma/theme.cpp
M  +8    -0    src/plasma/theme.h