This patch simplifies the battery's ui, and brings spacing in line with
Plasma 5 standards.
In detail:
- removing the selection item on batteries: it's already visible by the
text shown that the battery is selected. It also doesn't need the
selection semantics across the ui, because -- for what?
- remove separator lines, in Plasma 5, we use spacing for this case
- Improve HighDPI by removign hard-coded layout hints, use units.gridUnit
throughout
- Fix batteryitem's status: it would show the wrong icon and time label,
because AC Adapter can be empty. Checking charging is semantically
correct here, since it uses the charge state, not the adapter state.
- remove a bunch of SVGs that were used internally to get margins -- use
gridUnit for layout internal margins instead
- fix slider's right alignment, this would jump based on the percentage
label's width, which varies per item. We know the rough length of the
percentage label from the context, and can align the labels to that.
Thanks everybody for the reviews!
REVIEW:118272
QML offers a fontSizeMode setting that scales font to the available
size. This replaces the sizing timer we had in clock with that property.
REVIEW: 118274
BUG: 335147
As kded loads before plasma, we need to check for the free disk space a
bit later than on module load, otherwise that spawns an ugly not-plasma-
themed notification even before plasma is loaded
The first check will be done 1 minute after module load, that's enough.
Klipper is supposed to show a filter widget when starting to type.
This is done by forwarding the QKeyEvent to the not visible widget.
This seems to have broken in the Qt5 port. Instead of passing to the
widget it's send again to the KlipperPopup resulting in recursive calls
to the same method which in the end crashes Klipper.
By showing the widget before sending it the key event, everything is
fine. In case that the widget is empty after processing the key event
it gets hidden nevertheless.
REVIEW: 118204
Currently it's done purely as a notification, which doesn't make much
sense. This patch turns it into a regular SNI. The actions were moved
from the notification popup to the SNI menu.
REVIEW: 118205
It's important to have ensurePolished() being called before the native
XCB window gets created. The widget style (in our case Oxygen) sets the
RGBA hint during that call. Once the native window is created this would
fail.
In the case of KlipperPopup the native window gets created by accessing
the winId(), thus the ensurePolished() needs to happen before.
REVIEW: 118199
The LockWindowTest checks whether the window is black.
We are only interested in the rgb value, so ignore the alpha channel.
This fixes the failing test on the CI system which uses a different
depth.
The LockWindow deep called into KSLDApp to unlock in case of user
activity during grace time. But LockWindow also emits a signal on user
activity. From an architectural point of view it's better to handle this
directly in the KSLDApp and connect to the signal to unlock if it's in
grace time.
Another advantage is that LockWindow now no longer pulls in the KSLDApp
which improves the unit test situation for the LockWindow as the
lockWindowTest no longer needs to link the complete ksld library.
REVIEW: 118160
Two things, to improve the balance of the digiclock in a horizontal panel:
- Set the label's height to paintedHeight, this helps a bit in using a
balanced horizontal center line
- Give it a bit of spacing top and bottom to not look cramped vertically