Having the macro's definition of the operator| in the namespace of the
flags argument improves/unbreaks things for the argument-dependent
lookup of unqualified function names, e.g. when flags are combined in
calls of other methods, but there is some other operator| defined in the
namespace of the current code.
Given Q_DECLARE_OPERATORS_FOR_FLAGS creates inlined functions, this
should be a source and binary compatible change.
Qt did similar for Qt 5.12 in
https://codereview.qt-project.org/c/qt/qtbase/+/225348
Updated the tests so that you can see if the aspect ratio is correct.
Made an animated transition for when `control.running` is false.
Removed the code that updates the RotationAnimator when control.running changes since it didn't work.
Set padding to 0 (see comment).
BUG: 425504
Rather than duplicating the behaviors in both Button.qml and ToolButton.qml, leading to bugs and inconsistencies, the Button/ToolButton background code is split into separate reusable files. The correct background is used depending on whether or not flat mode is enabled.
BUG: 425174
This fixes installation on Windows.
An alternative solution would have been to dynamically create the symlinks
in the install step, on Linux, and to copy them on Windows.
01:05:07.444 CMake Error at src/desktoptheme/breeze-dark/cmake_install.cmake:43 (file):
01:05:07.444 file INSTALL cannot read symlink
01:05:07.444 "C:/_/acd4f350/plasma-framework-5.71.0/src/desktoptheme/breeze-dark/widgets/plasmoidheading.svgz"
01:05:07.444 to duplicate at
01:05:07.444 "C:/Craft/BC/windows-mingw_64-gcc/build/kde/frameworks/tier3/plasma-framework/image-RelWithDebInfo-5.71.0/Craft/BC/windows-mingw_64-gcc/bin/data/plasma/desktoptheme/breeze-dark/widgets/plasmoidheading.svgz":
01:05:07.444 No such file or directory.
01:05:07.444 Call Stack (most recent call first):
01:05:07.444 src/desktoptheme/cmake_install.cmake:40 (include)
01:05:07.444 src/cmake_install.cmake:41 (include)
01:05:07.444 cmake_install.cmake:109 (include)
The toolbutton-hover margins need to be inconsistent with the hover margins because 3rd party themes expect this inconsistent behavior now.
BUG: #425255
This reverts commit 7062c635a9.
Unfortunately, 3rd party themes were still broken after this commit was made because it didn't fix the real issue.
The real issue is that toolbutton-hover is supposed to have margins, but it didn't have real margins due to a previous patch to `button.svg`.
3rd party themes depend on hover and toolbutton-hover being used in inconsistent ways because of past behavior.
Unfortunately, they have to be inconsistent again
to not break themes.
Previously, it was trying to use the margins of toolbutton-hover for flat buttons, but toolbutton-hover doesn't have real margins (0.001 since 0 isn't valid).
BUG: #425255
Non-flat ToolButtons are supposed to have a shadow, but flat ToolButtons
are not. The ternary providing this was inverted so that the reverse was
true.
QQC2 controls gain activeFocus on press this is a difference to controls 1
which had activeFocusOnPress property that defaulted to false. qqc2-desktop-style
also only sets the focus flag if it was gained via keyboard (kquickstyleitem.cpp:705).
BUG:424446
For the following reasons:
- It can break and look bad on Plasma Mobile which uses the Plasma style
- It makes buttons with icons and short text look visually unbalanced
- QStyle and QML desktop style buttons do not do this so it's a source
of inconsistency
Tests are adjusted to all pass. Stuff looks better to my eye.
Fixes common and frequent crashes introduced by 6c627ea044.
Otherwise the engine will try to delete it. The docs say:
NOTE: A QObject singleton type instance returned from a singleton type provider
is owned by the QML engine unless the object has explicit
QQmlEngine::CppOwnership flag set.
A lambda can only be converted to a function pointer if it does not capture
anything. Just specifying a default capture even if it does not capture anything,
prevents this. In newer Qt this actually ended up calling the std::function
(which is much heavier than function pointers) overload which was introduced
only after Qt 5.12.
Since a checkbox is a subclass of AbstractButton, it can be given an
icon. QWidgets checkboxes will faithfully display this icon, but
PlasmaComponents3 ones will not. They should. :)
I will submit a similar change for the QQC2 checkbox style
to make them consistent.
if KDeclarative::runtimePlatform() is set, then filter applets
that have formfactors set and don't match, in order to not
show on the phone applets that are desktop only
in desktop case, list all applets, for maximum retrocompatibility,
to be reconsidered for kf6
Compare API dox of Q_DECLARE_METATYPE:
"
Some types are registered automatically and do not need this macro:
* Pointers to classes derived from QObject
* QPointer<T>, QSharedPointer<T>, QWeakPointer<T>,
where T is a class that derives from QObject
"
This is a ABI-compatible change, as this just replaces explicitly
defined template code (by the Q_DECLARE_METATYPE macro use) with the
generic predefined one picking up pointers to QObject subclasses.
So instead of the custom explicitly template overload
template <>
struct QMetaTypeId< TYPE >
{ /**/ static int qt_metatype_id() {/**/} };
the predefined template overload one is picked up via
template <typename T>
struct QMetaTypeId : public QMetaTypeIdQObject<T>
{ /**/ };
template <typename T, int =
QtPrivate::IsPointerToTypeDerivedFromQObject<T>::Value ?
QMetaType::PointerToQObject :
/**/ 0>
struct QMetaTypeIdQObject
{ /**/ };
template <typename T>
struct QMetaTypeIdQObject<T*, QMetaType::PointerToQObject>
{ /**/ static int qt_metatype_id() {/**/} };
And thus the constexpr code using QMetaTypeId<T>::qt_metatype_id(),
for which all this is done, evaluates as before.
GIT_SILENT
The old code calling
qRegisterMetaType<Plasma::T *>("T");
was broken, as it registered for the name "T", not the pointer
type "T*". Things still work though as that registration is also
covered due to
qmlRegisterInterface<Plasma::T>("T");
internally also calling
qRegisterMetaType<Plasma::T *>("T*");
so that in the end "T*" was registered and mapped to the right type.
Currently, I see that the network icons aren't visible enough. For example, I find it difficult to determine the signal strength of the network without peering. I would like these icons to be more visible, and therefore I propose to use 35% opacity for faded elements. As for me, this solution makes determining the signal level more convenient and the icons more informative.
Plasma dialogs are already marked as not being shown in the task manager
and the pager. We should similarly omit them from the task switcher, for
the same reasons.
BUG: 419239
FIXED-IN: 5.73
We should use the normal arrow cursor when a list item is hovered.
The hovered state is depicted with a highlight already, so the hand
cursor is unnecessary and doesn't go well with the rest of the desktop.
The sizes of the context buttons on the list item were being overridden
for no apparent reason. Let's stop doing that so that the button sizes
are consistent with other PC3 button sizes.
Make sure the shadow item--which includes the hover effect, if present--can
be shown when the ToolButton is focused, and also always omit the shadow
when the ToolButton is flat.
Now all of them have a base height of units.gridUnit. Combined with
the standard 6px margins it works out to make all of these controls
a uniform 30px tall with the default Noto Sans 10 font. If the font
is changed or the size is increased, even to absurd levels, all of
them scale evenly.
The PC3 version was missing the clear button and show password button,
which the PC2 version has. This should allow us to port more things to
use the PC3 version.
relay->checkQueueing emits a signal to all observers. As it's a signal
anything can happen at that point. It's seemingly common for a receiver
to connect/disconnect a new visualisation which in turn alters
d->relays.
This broke when a foreach (with implicit shallow copy) was ported to a
for statement.
This report contains a good analysis and test case
BUG: 422973
Probably also:
BUG: 421392
BUG: 423713
BUG: 423776
BUG: 422230
BUG: 423081
Currently, I see that the icons that show available and connected networks are not visible enough. For example, I find it difficult to determine the signal strength of the network without peering. I would like these icons to be more visible, and therefore I propose to reduce the opacity of faded lines. As for me, this solution makes determining the signal level more convenient and the icons more informative.
BUG: 423843
This changed the name of the types for which the classes where registered
from unnamespaced "Service", "ServiceJob", "DataSource" to the fully
namespaced "Plasma::Service", "Plasma::ServiceJob", "Plasma::DataSource",
so making the old names no longer known to the system and thus breaking
support for any invokable methods which use the unnamespaced type name.
And not only that, qmlRegisterInterface<T>("Name") also registered the
classes' pointer counterparts T* by the name "Name*", so here
"Service*", "ServiceJob*", "DataSource*". While the new again instead
does this with the fully namespaced names "Plasma::Service*",
"Plasma::ServiceJob*", "Plasma::DataSource*", so also breaking support
here.
This reverts commit 7c4f5c5f1e.
Level 1 is too large for this, as it's typically used for the entire
window or popup's title. The smaller level 2 is therefore more
appropriate so that when the parent window supplies its own level 1
heading, the calendar month label don't inappropriately be the same size.
Needed for https://invent.kde.org/plasma/plasma-workspace/-/merge_requests/98
Summary:
I recently noticed that `Kirigami.Units.devicePixelRatio` was `1.3` even though I was at the default 96dpi when writing a widget's config.
{F8287886}
There's 4 different `Units.qml`, and I'm not certain which does what. 2 are in `krigiami` and the other 2 are in `plasma-framework`.
```
$ locate /Units.qml | grep /usr/
/usr/lib/qt/qml/org/kde/kirigami.2/Units.qml
/usr/lib/qt/qml/org/kde/kirigami.2/styles/Plasma/Units.qml
/usr/lib/qt/qml/org/kde/kirigami.2/styles/org.kde.desktop/Units.qml
/usr/lib/qt/qml/org/kde/kirigami.2/styles/org.kde.desktop.plasma/Units.qml
```
* 2 years ago [`kirigami/src/controls/Units.qml`](https://github.com/KDE/kirigami/blame/master/src/controls/Units.qml#L75) (`/usr/lib/qt/qml/org/kde/kirigami.2/Units.qml`) was changed from `13/10 = 1.3` to multiply by `13*0.75` so that `9.75/10 = 0.975` (then `max(1, 0.975) = 1`).
-----
There's 2 files owned by `plasma-framework`. The `/styles/Plasma/Units.qml` binds PlasmaCore's `units.devicePixelRatio`, so that leaves `/styles/org.kde.desktop.plasma/Units.qml`.
```
$ pacman -Qo /usr/lib/qt/qml/org/kde/kirigami.2/styles/org.kde.desktop.plasma/Units.qml
/usr/lib/qt/qml/org/kde/kirigami.2/styles/org.kde.desktop.plasma/Units.qml is owned by plasma-framework 5.69.0-2
```
This patch edits the `org.kde.desktop.plasma` style, and fixes `qmlscene KirigamiDevicePixelRatioTest.qml`, and `plasmashell` widget configs, and `plasmoidviewer` widget configs.
The Kirigami patch is D29462
Test Plan:
You can edit `/usr/lib/qt/qml/org/kde/kirigami.2/styles/org.kde.desktop.plasma/Units.qml` then run:
* https://gist.github.com/Zren/621338b8cda7c550d7b43f8ea1ba71a7
* `qmlscene KirigamiDevicePixelRatioTest.qml`
and `Kirigami.Units.devicePixelRatio` should equal `1`.
Reviewers: #kirigami, mart
Reviewed By: #kirigami, mart
Subscribers: davidre, kde-frameworks-devel
Tags: #frameworks
Differential Revision: https://phabricator.kde.org/D29463
Summary:
Currently adjusting the value by scroll and click/touch+drag are not implemented.
This patch implements them.
Test Plan:
As far as I can tell, the `PlasmaComponents3.Spinbox` is not actually used anywhere in Plasma, so test with D29535:
{F8301480}
Reviewers: #vdg, #plasma, ahiemstra
Reviewed By: ahiemstra
Subscribers: ahiemstra, abetts, ndavis, cblack, kde-frameworks-devel
Tags: #frameworks
Maniphest Tasks: T9460
Differential Revision: https://phabricator.kde.org/D29534
Summary:
m_svgIcon can be null.
disconnect(q, nullptr, nullptr, nullptr); would have pretty catastrophic
consequences as it disconnects everything. Anyone listening for
QObject::destroyed of IconItem for cleanup would no longer get anything.
That could lead to obscure conditions.
ShaderEffectSource watches for the source being destroyed for cleanup
and we have a newly introduced crash with ShaderEffectSource that seems
to come from this patch.
BUG: 421170
Test Plan:
Someone who could reproduce the crash reliably confirms it fixes the
issue
Reviewers: #plasma
Subscribers: kde-frameworks-devel
Tags: #frameworks
Differential Revision: https://phabricator.kde.org/D29742
Summary: This makes borders of elements using plasmoidHeading rounded again
Test Plan:
After:
{F8289023}
Clearing cache might be needed here.
Reviewers: #plasma, broulik
Reviewed By: #plasma, broulik
Subscribers: broulik, ngraham, kde-frameworks-devel
Tags: #frameworks
Differential Revision: https://phabricator.kde.org/D29479
Summary:
We're moving towards using the small font for subtitles in Kirigami BasicListItem (D29432)
so we should probably do the same here since it has the same title + subtitle layout.
Test Plan:
Before: {F8284752}
After: {F8284751}
Reviewers: #plasma, #vdg, broulik, ndavis
Reviewed By: #vdg, ndavis
Subscribers: cblack, kde-frameworks-devel
Tags: #frameworks
Differential Revision: https://phabricator.kde.org/D29434
Summary:
We're the only theme with the appropriate heading svgs that make the headers and footers look as they should.
All the other themes fall back to Breeze, which is not a good look for some of them:
- the heading is too jarring compared to applet background
- the heading does not extend all the way vertically and horizontally
To solve this, to avoid degrading unmaintained themes and to give themes a chance to adjust on their own terms, this patch makes the heading visible only when the needed SVG exists in the theme.
Test Plan:
Avoids this:
{F8276897}
{F8276896}
Breeze still works as it should.
Reviewers: #vdg, #plasma, niccolove, ngraham
Reviewed By: #vdg, niccolove, ngraham
Subscribers: ngraham, niccolove, kde-frameworks-devel
Tags: #frameworks
Differential Revision: https://phabricator.kde.org/D29352
Summary:
When SvgSource is changed, old one is deleted. Connections are not automatically disconnected.
This change disconnects connections and fixes regression introduced in D28470.
BUG: 420801
FIXED-IN: 5.70
Test Plan:
STEPS TO REPRODUCE
1. click on mute button for a device
2. click on the desktop to collapse the applet
OBSERVED RESULT
crash in step 1 and in the rare case it doesn't crash it crash in step 2
EXPECTED RESULT
don't crash
Reviewers: #plasma, #frameworks, ngraham, davidedmundson
Reviewed By: ngraham
Subscribers: kde-frameworks-devel
Tags: #frameworks
Differential Revision: https://phabricator.kde.org/D29314
Summary: There are 3 possible strategies: QIcon, QImage and SVG. This change moves logic of each of these strategies into separate class.
Test Plan: Should behave exactly the same
Reviewers: #plasma, broulik, apol, davidedmundson, #frameworks
Reviewed By: #plasma, davidedmundson
Subscribers: mart, davidre, cblack, kde-frameworks-devel, #plasma
Tags: #frameworks
Differential Revision: https://phabricator.kde.org/D28470
Summary:
It takes into account the dpi of the screen we're rendering to.
Other overloads assume the window is nullptr and will use the primary screen's dpi which can change almost randomly.
Test Plan: Icons still look fine even if I drag windows from a screen to another.
Reviewers: #plasma, #frameworks, davidedmundson
Reviewed By: #plasma, davidedmundson
Subscribers: davidedmundson, ngraham, kde-frameworks-devel
Tags: #frameworks
Differential Revision: https://phabricator.kde.org/D29102
Summary:
Right now ExpandableListItem is not very touch-friendly due to use of a mousearea
hover effect for choosing the selected item. This patch fixes that by using a `TapHandler`
to handle left-clicks and touch input. We still need a MouseArea inside it to handle
non-touch hover and right-click behaviors.
FEATURE: 393749
FIXED-IN: 5.70
Test Plan: Click behavior is identical to how it was before, but now touch works too: {F8234452}
Reviewers: #plasma, apol, #vdg, niccolove
Subscribers: kde-frameworks-devel
Tags: #frameworks
Differential Revision: https://phabricator.kde.org/D28808
Summary:
Without this, the Busy Indicator generates binding loops for me when used in the new
ExpandableListItem component.
Test Plan: No more binding loops in console logging
Reviewers: #plasma, davidedmundson, broulik
Reviewed By: #plasma, broulik
Subscribers: kde-frameworks-devel
Tags: #frameworks
Differential Revision: https://phabricator.kde.org/D28787
Summary: Neither the merged look nor the normal one needs to have rounded borders, as they are clipped out from the dialog and they would break third party themes without rounding. Without rounded borders, there's no need for the enabledBorders check, which also broke the heading when used in top panels.
Reviewers: #plasma, ngraham
Reviewed By: ngraham
Subscribers: manueljlin, ahiemstra, ndavis, ngraham, mart, davidedmundson, kde-frameworks-devel
Tags: #frameworks
Differential Revision: https://phabricator.kde.org/D28372
Summary:
QQmlComponent::beginCreate and completeCreate are useful if you need to
set properties on the object explicitly. We're not doing that here, we
can just call create.
Test Plan:
On Qt5.15
Right click a panel
choose edit
Reviewers: #plasma, apol
Reviewed By: apol
Subscribers: apol, kde-frameworks-devel
Tags: #frameworks
Differential Revision: https://phabricator.kde.org/D28599
Summary:
As discussed in T12778, the icon can never be in a correct state: either it's
redundant with the icon you're hovering over that made the tooltip appear, or
else it's different from the icon you're hovering over, which is inconsistent.
Since either case is undesirable, let's just remove the icon from the tooltip
entirely. This reduces the visual noise in the tooltip and solves the entire
class of bugs automatically.
Test Plan:
{F8150019}
{F8150017}
{F8150021}
Reviewers: #vdg, #plasma, cblack, niccolove, apol
Reviewed By: #vdg, cblack, niccolove, apol
Subscribers: cblack, kde-frameworks-devel
Tags: #frameworks
Maniphest Tasks: T12778
Differential Revision: https://phabricator.kde.org/D27848
Summary:
This patch creates the `ExpandableListItem`, a re-usable PlasmaExtras item that can
be used for the views in various Plasma applet pop-ups, such as Vaults, Printers,
Bluetooth, Networks, and Device Notifier. This way those applets can share more code and
not have to implement this paradigm themselves in five different ways, as they currently
do.
All of these applets currently use slightly different visual styles. For example the
network applet uses a pushbutton with no icon as its "default action" button, while
other applets use icons-only toolbuttons. I tried my best to create a component that's
flexible but also consistent, so various applets that adopt it will see minor visual
changes as a result. Hopefully this is acceptable.
Closes T12812
Depends on D28144
Test Plan: {F8183650}
Reviewers: #vdg, #plasma, davidedmundson
Reviewed By: #plasma, davidedmundson
Subscribers: mart, davidedmundson, bruns, niccolove, cblack, davidre, kde-frameworks-devel
Tags: #frameworks
Maniphest Tasks: T12812
Differential Revision: https://phabricator.kde.org/D28033
Summary:
Right now longDuration is 120ms and shortDuration is 24ms. This presents three problems:
- The durations are far too fast, especially shortDuration, which is so fast that it seems like there is no animation at all.
- The durations are not consistent with Kirigami, which uses 150 for short and 250 for
long.
- There is no longer value available, as with the one being added to Kirigami in D28143.
Accordingly, this patch makes the short and long values consistent with Kirigami's values,
and adds a new `veryLongDuration` value to match the one being added to Kirigami in D28143.
Reviewers: #plasma, davidedmundson, mart
Reviewed By: #plasma, mart
Subscribers: kde-frameworks-devel
Tags: #frameworks
Differential Revision: https://phabricator.kde.org/D28144
Summary: Page element was missing. I added it.
Reviewers: #plasma, ngraham, mart
Reviewed By: #plasma, ngraham, mart
Subscribers: ngraham, davidedmundson, kde-frameworks-devel
Tags: #frameworks
Differential Revision: https://phabricator.kde.org/D28466
Summary: When not running the indicator should be invisible. This matches the behaviour of the org.kde.desktop style.
Test Plan: Run KTrip with Plasma style. Open location search page. Indicator is only shown when actually loading things
Reviewers: #plasma, ngraham
Reviewed By: ngraham
Subscribers: kde-frameworks-devel
Tags: #frameworks
Differential Revision: https://phabricator.kde.org/D28391
This reverts commit 049978008b.
This commit changes existing animation durations, and must be landed
simultaneously with Plasma 5.19's release so that rolling release
users don't suffer from very slow animations for a month. Will
re-land after Plasma 5.59 is tagged so it gets released with Frameworks
5.60, the dependency version for Plasma 5.19.
Summary:
16 and 22px sizes added for window-pin and unpin. Style was also updated for window-unpin.
edit-delete is redundant because it's already defined in edit.svg. I don't think it's used anywhere at all. It was actually window-close, but renamed to edit-delete for whatever reason.
Test Plan:
{F8195527, size=full}
1. Install patch to kdesrc-build environment
2. Run `plasmashell --replace &` in kdesrc-build environment
3. Check pin button in systray
Reviewers: #vdg, #plasma, cblack, ngraham
Reviewed By: #vdg, cblack, ngraham
Subscribers: cblack, kde-frameworks-devel
Tags: #frameworks
Differential Revision: https://phabricator.kde.org/D28228
Summary:
Right now longDuration is 120ms and shortDuration is 24ms. This presents three problems:
- The durations are far too fast, especially shortDuration, which is so fast that it seems like there is no animation at all.
- The durations are not consistent with Kirigami, which uses 150 for short and 250 for
long.
- There is no longer value available, as with the one being added to Kirigami in D28143.
Accordingly, this patch makes the short and long values consistent with Kirigami's values,
and adds a new `veryLongDuration` value to match the one being added to Kirigami in D28143.
Reviewers: #plasma, davidedmundson, mart
Reviewed By: #plasma, mart
Subscribers: kde-frameworks-devel
Tags: #frameworks
Differential Revision: https://phabricator.kde.org/D28144
Summary:
This creates a new component that uses the widgets/toparea svg. First time I try to add something to PlasmaComponents, so I probably got stuff wrong and I probably have to still do thing like adding documentation. I'm creating the diff to get feedback on how to move forward with this.
Depends on D27444
Reviewers: mart, ngraham
Reviewed By: mart, ngraham
Subscribers: ngraham, davidedmundson, ahiemstra, kde-frameworks-devel
Tags: #frameworks
Maniphest Tasks: T10470
Differential Revision: https://phabricator.kde.org/D27695
Summary:
always scale icons unless a size is specified in the api.
this makes icon sizing more in line with plasma components 2
Test Plan:
{F8129062}
{F8129064}
{F8129065}
Reviewers: #plasma, broulik
Reviewed By: #plasma, broulik
Subscribers: broulik, ngraham, kde-frameworks-devel
Tags: #frameworks
Differential Revision: https://phabricator.kde.org/D27628
Summary:
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.
BUG: 417780
Test Plan:
{F8125752}
{F8125753}
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
Summary:
When Dialog is being destroyed, its QWindow super-class may still emit
some signals from its destructor. Dialog is connected so some of them,
so this leads to Qt invoking slots on Dialog, whose destructor has
already been called, leading to crashes.
This patch disconnects all internal connections in Dialog's destructor.
See https://phabricator.kde.org/D23339 for details.
Test Plan: Plasma no longer crashes when a notification appears
Reviewers: #plasma, nicolasfella, davidedmundson
Reviewed By: #plasma, davidedmundson
Subscribers: kde-frameworks-devel
Tags: #frameworks
Differential Revision: https://phabricator.kde.org/D27671
Summary:
Removed two unused lines.
Removed old comments.
Minor style changes to comments.
Test Plan: Everything must stay unchanged visually and function wise for ListItems.
Reviewers: #plasma, ngraham
Reviewed By: ngraham
Subscribers: kde-frameworks-devel
Tags: #frameworks
Differential Revision: https://phabricator.kde.org/D27296
Summary:
icon sizes and label placements tested correct in several scenarios
* control.icon.width/height is used as maximum size of the icon
* if the button is smaller icons always scale down
* icons stay ccentered regardless of button size when there is no text
Test Plan:
fixes icon sizes without workarounds like D27260
{F8108705}
Reviewers: #plasma, davidedmundson
Reviewed By: #plasma, davidedmundson
Subscribers: davidedmundson, kde-frameworks-devel
Tags: #frameworks
Differential Revision: https://phabricator.kde.org/D27460
Summary:
for retrocompatibility with pc2 units.gridUnit * 1.6 is used
a lot as size hint (we have to guarantee buttons and
textfields have the same height by default for perfect
horizontal alignment.
tough we have make sure that size is integer and even otherwise
we'll have a lot of internal misalignments
Reviewers: broulik
Reviewed By: broulik
Subscribers: kde-frameworks-devel
Tags: #frameworks
Differential Revision: https://phabricator.kde.org/D27399
Summary:
support the icon size hint of the control. Reinstate it in ToolButton
and add the support for the other controls
CCBUG:417514
Test Plan:
possible to control buttons icon sizes
mediacontroller taskbar tooltip with icons set to small:
{F8103363}
Reviewers: #plasma, broulik
Reviewed By: #plasma, broulik
Subscribers: broulik, kde-frameworks-devel
Tags: #frameworks
Differential Revision: https://phabricator.kde.org/D27396
The deprecated constructor taking a KPluginInfo unconditionally calls toMetaData() and then asserts.
BUG: 417548
Differential Revision: https://phabricator.kde.org/D27366
Summary:
Right now the widget tooltip's icon/image is top-aligned, which in practice makes it
vertically centered when the tooltip has only one line of text, but not vertically
centered when there are two lines of text.
This patch makes it vertally centered all the time, improving the appearance.
Test Plan:
Before: {F8095695}
After: {F8095696}
{F8095697}
Reviewers: #vdg, #plasma, filipf, ndavis
Reviewed By: #vdg, filipf, ndavis
Subscribers: kde-frameworks-devel
Tags: #frameworks
Differential Revision: https://phabricator.kde.org/D27299
Summary:
move all the logic in an attached property QObject
it's a bit less heavy to create so should make things slightly better
when this is used in delegates
Test Plan: Plasmoid background removal (with colors inversion) still works
Reviewers: bshah, #plasma
Subscribers: apol, kde-frameworks-devel
Tags: #frameworks
Differential Revision: https://phabricator.kde.org/D27200
Summary:
Currently, when you have the desktop in the Desktop layout, if you drop 10 jpg files into the desktop, it creates 10 menus at the same position.
When you have the desktop in the Folder layout, if you drop 10 jpg files into the desktop, it calls `KIO::setApplicationActions()` 10 times.
What does this improve?
- Do not create KIO::MimetypeJob for each file
- Do not call `DropJob::setApplicationActions()` too many times/ create too many menus for each file.
My idea is that, when you drop files into the desktop:
- If they have the same `mimetype` -> we add actions support this `mimetype`.
- If not -> we only show the action from `KIO::DropJob` and only actions support different `mimetypes` at the same time like `Add icon`...
**Require:** D26484
CCBUG: 415917
Reviewers: #plasma, mart, broulik, #vdg, davidedmundson
Reviewed By: #plasma, davidedmundson
Subscribers: davidedmundson, anthonyfieroni, #plasma, kde-frameworks-devel
Tags: #frameworks
Differential Revision: https://phabricator.kde.org/D26691
Summary: Alternative and more basic patch to D26955, this aims to fix the background color without breaking the mask
Reviewers: #vdg, #plasma, ndavis
Reviewed By: #vdg, ndavis
Subscribers: ndavis, ngraham, kde-frameworks-devel
Tags: #frameworks
Differential Revision: https://phabricator.kde.org/D26968
Summary:
The checkboxes and radio buttons in plasmashell were signficantly different from checkboxes and radio buttons in the Breeze QStyle. This patch is needed to make D26271 look nicer.
- Plasmashell checkboxes and radio buttons were much larger.
-- 24x24 for checkboxes and 29x29 for radio buttons (Plasmashell) vs 16x16 (QStyle).
- Pixel alignment was very poor.
-- Checkbox indicator was 14x14, stretched to 24x24.
-- Radio button background was 22x22 or 32x32, adjusted to 29x29.
-- Radio button indicator was 16x16, stretched to 29x29.
- Style was different.
-- Checkbox indicators had sharper corners and less margin around the inner rectangle.
-- Radio buttons had a hardcoded dark gray circular frame and a shadow on the bottom of the inside of the frame.
-- Radio button indicators had less margin around the inner circle.
Test Plan:
{F7891476}
{F7891477}
Reviewers: #plasma, #vdg, ngraham
Reviewed By: #vdg, ngraham
Subscribers: ngraham, davidedmundson, kde-frameworks-devel
Tags: #frameworks
Differential Revision: https://phabricator.kde.org/D26758
Summary: I have received negative feedback (and I agree with it) on the current state of breeze shadows: they are quite dark, narrow, and feel unnatural. I tried to adress that by making shadows more sparse and a bit lighter especially on the angles while trying to keep it distinguishable when on white background. I received some positive feedback on these shadows from T10891 and the VDG channel. More specifically, I changed dialogs/background.svg to have a) longer linear gradients and b) radial gradients instead of linear on the four sides to make the center darker than the angles.
Test Plan:
{F7765496}
{F7765497}
{F7765500}
Reviewers: #vdg, ngraham, The-Feren-OS-Dev, ndavis
Reviewed By: #vdg, ngraham, The-Feren-OS-Dev, ndavis
Subscribers: The-Feren-OS-Dev, mart, broulik, cblack, ndavis, manueljlin, ngraham, filipf, kde-frameworks-devel
Tags: #frameworks
Differential Revision: https://phabricator.kde.org/D25015
Summary:
bigger scrollbar and add a small line separator
to look consistent with D26655 and D26654
same behavior for mobile scrollbar
Test Plan: {F7882876}
Reviewers: #plasma, #vdg, ngraham
Reviewed By: #vdg, ngraham
Subscribers: davidedmundson, kde-frameworks-devel
Tags: #frameworks
Differential Revision: https://phabricator.kde.org/D26664
Summary: Instead of relying on the older KPluginInfo which is slower (parses de metadata twice) and comes from a much higher tier.
Test Plan: Running plasmashell with it
Reviewers: #plasma, mart
Reviewed By: #plasma, mart
Subscribers: kossebau, broulik, kde-frameworks-devel
Tags: #frameworks
Differential Revision: https://phabricator.kde.org/D23682
Summary:
- much improves discoverability of the ability to move added widgets without clicking and holding (I have seen people having trouble figuring it out)
- makes it more consistent with panel widget context menus
- allows easier access to the edit mode when the desktop is full of widgets
Test Plan: Open the context menu of a widget on the desktop.
Reviewers: #plasma, #vdg, mart, ngraham, davidedmundson
Reviewed By: #plasma, #vdg, ngraham, davidedmundson
Subscribers: davidedmundson, ngraham, broulik, mart, #vdg, kde-frameworks-devel, #plasma
Tags: #frameworks
Differential Revision: https://phabricator.kde.org/D26043
Summary:
color selected buttons to the highlight color when it has keyboard
focus.
This makes the behavior much more similar to the Breeze desktop style
Test Plan:
selected buttons look blue on Breeze, old themes still work as they did
Before
{F7872340}
After
{F7872341}
QWidget
{F7872344}
Reviewers: #plasma, #vdg, #goal_consistency, ngraham
Reviewed By: #vdg, ngraham
Subscribers: davidedmundson, ngraham, kde-frameworks-devel
Tags: #frameworks
Differential Revision: https://phabricator.kde.org/D26540
Summary:
So far PC3 version of the slider doesn't react to events, this change
enables it.
Test Plan: Used it with a test.
Reviewers: #plasma, broulik, davidedmundson
Reviewed By: #plasma, davidedmundson
Subscribers: davidedmundson, kde-frameworks-devel
Tags: #frameworks
Differential Revision: https://phabricator.kde.org/D26055
Summary:
Currently the widget explorer relied on some QML code calling
KWindowSystem::forceActiveWindow which on plasma implicitly set this
hint.
This works for the first show, but the order of events is somewhat
unreliable. It's invoked from QML when the window is ready, but for the
second show this is before the wl_surface is created and it no-ops.
By syncing the flags in applyType() we can guarantee we call this both
when setFlags is called and when the wl_surface is created in the
correct order.
BUG: 415124
BUG: 401172
Test Plan:
Ran plasmashell
Opened widget explorer twice
Had focus each time
Reviewers: #kwin, #plasma, romangg
Reviewed By: #kwin, #plasma, romangg
Subscribers: kde-frameworks-devel
Tags: #frameworks
Differential Revision: https://phabricator.kde.org/D26153
Summary:
If we have a broken locale setup we don't have any uiLanugages to look
up the relevant locale object for.
In that case use the system locale.
Test Plan:
Had a crash here
#11 0x00007ff982aab0b2 in QList<QString>::at(int) const (this=0x7ffd50b1d928, i=0) at /opt/qt5/include/QtCore/qlist.h:571
#12 0x00007ff982aaaa4a in Calendar::monthName() const (this=0x5640cce026f0) at /home/david/projects/kde5/src/frameworks/plasma-framework/src/declarativeimports/calendar/calendar.cpp:202
#13 0x00007ff982aa14e9 in Calendar::qt_static_metacall(QObject*, QMetaObject::Call, int, void**) (_o=0x5640cce026f0, _c=QMetaObject::ReadProperty, _id=9, _a=0x7ffd50b1dd40) at src/declarativeimports/calendar/calendarplugin_autogen/EWIEGA46WW/moc_calendar.cpp:340
Reviewers: #plasma, vkrause
Reviewed By: vkrause
Subscribers: kde-frameworks-devel
Tags: #frameworks
Differential Revision: https://phabricator.kde.org/D25960
... but Qt XCB does, such as Notification type.
This ensures QXcbWindow keeps the correct window types around so we don't have Qt setting it back
to e.g. Dialog when we change some flags and then having to manually set it back using KWindowSystem.
Only for types that aren't in NET WM like OSD and Critical Notifications will it have to fall back to
the old codepath. It also just uses it directly on Wayland.
Differential Revision: https://phabricator.kde.org/D26000
Summary:
KDeclarative::setupBindings() is deprecated, replaced calls with its
implementation (setupContext + static setupEngine call), but see comment
about whether we can be sure this is done only once per engine, as
requested by the setupEngine API. It's 100% equivalent to the old code
though, can't be worse.
KPackage::contentsHash is deprecated, replaced call with implementation.
Depends on D25433 for the KActionCollection::changed signal.
Test Plan: Builds
Reviewers: mart, davidedmundson, broulik, apol
Reviewed By: apol
Subscribers: apol, kde-frameworks-devel
Tags: #frameworks
Differential Revision: https://phabricator.kde.org/D25434
Summary:
When we destroy a colorscope, all children will try to reparent. This patch
makes it so they never pick an object if it's being removed.
Test Plan:
The logout screen greeter and kscreenlocker doesn't crash anymore
upon close.
Reviewers: #plasma, mart
Reviewed By: #plasma, mart
Subscribers: kde-frameworks-devel
Tags: #frameworks
Differential Revision: https://phabricator.kde.org/D25953
Summary: Set the right value on the Kirigami.Units and use it from tooltip.
Reviewers: #plasma, ngraham
Reviewed By: ngraham
Subscribers: kde-frameworks-devel
Tags: #frameworks
Differential Revision: https://phabricator.kde.org/D25918
Summary:
Otherwside if we toggle indeterminate the bar resizes to 50% of the view
and X stops on the current value of the animation. Resulting in
something that looks super odd.
Test Plan: Plasma Components manual uit test looks sane
Subscribers: kde-frameworks-devel
Tags: #frameworks
Differential Revision: https://phabricator.kde.org/D25927
Summary:
If the width is smaller than LeftMargin + Right Margin the two ends
overlap and it looks super weird
Test Plan: Progressbar manual unit test looks sane
Reviewers: #plasma
Subscribers: kde-frameworks-devel
Tags: #frameworks
Differential Revision: https://phabricator.kde.org/D25926