Fix icon colors of inline context buttons also in full screen mode

Authored by rkflx on Sep 28 2017, 4:36 PM.

Description

Fix icon colors of inline context buttons also in full screen mode

Summary:
In the darker full screen mode, the icons of the mouse-over overlays
were still hard to see against the similarly coloured background. This
was because when switching to full screen mode, we would miss to reset
the icon (except for mToggleSelectionButton). The root cause is
QAbstractButton, which just holds onto a pixmap and has no way of
knowing KIconLoader would return a differently coloured icon when the
colour palette changes (as is the case for colour-aware icon sets like
"Breeze").

To fix this, we simply use QIcon::fromTheme instead of SmallIcon,
which returns a proper QIcon instead of a QPixmap and automatically
adapts to colour palette changes.

(This is a followup patch to D7988.)

CCBUG: 383059
FIXED-IN: 17.08.2

Test Plan:
Overlay icons perfectly visible against the background color in standard
and full screen mode. Tested with "Breeze" and "Breeze Dark" colour
schemes as well as "Breeze", "Oxygen" and "Fusion" widget styles.
("Fusion" does not allow to customize the size for small icons, though.)

Reviewers: KDE Applications, broulik, ngraham

Reviewed By: broulik

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

Details

Committed
rkflxSep 29 2017, 6:49 PM
Reviewer
broulik
Differential Revision
D8031: Fix icon colors of inline context buttons also in full screen mode
Parents
R260:4333b095027e: GIT_SILENT made messages (after extraction)
Branches
Unknown
Tags
Unknown