The Layer Shell Qt library is updated to match its API more closely to
the protocol. It is now possible, or rather required if the behavior
should not change, to specify a desired output for a LayerShell window.
There's no use of static declarations in headers, those result in compiler
warnings. They could be removed envirely after moving one function up a bit.
Give context though i18nc for the use of "uninstallable" so that it won't be misinterpreted as "not installable" by translators, as has happened in some cases (e.g. sv & zh_TW).
Applets in PlasmoidItem were blocking events from reaching the
ToolTipArea, so I moved the on hover logic to the AbstractItem's
MouseArea and put the MouseArea over the iconContainer. The
iconContainer is the parent of applets. Presses tend to hit the center,
which is where the applet is, preventing ToolTipArea::containsMouse from
being true and preventing the highlight from moving to the pressed item.
Hopefully this doesn't cause duplicate actions when events reach the
applet. I tested the patch on the nightcolor applet and all the other
default applets and didn't see anything wrong. I think this may be
because the signals are sending QML MouseEvents to the applets, causing
them to be accepted if the applet can accept them. Then when the signal
handlers are done, since the events are already accepted, they should
not move beyond the MouseArea and cause another round of event handling.
Combine the "Text selection only", "Ignore selection" and "Ignore images"
options into separate sets of radio buttons for text and images, to make
their functions explicit.
Remove the "Prevent empty clipboard" option (but leave it as a hidden
config file setting), it was difficult to explain and it is unclear if it
ever had a use case.
Convert the page to a QFormLayout, and add explanatory text to existing
controls where appropriate.
GUI:
I18N:
This empty mousearea serves for the sole purpose of refusing touch events
which otherwise are eaten by Control stealing the event from any of its parents
this fixes applet dragging in editmode for all systemmonitor plasmoids
Over the years we've changed icon spacing many times. And every time we
do, we get bug reports about it from people who were happier with the
previous value. Typically we close these bug reports as RESOLVED
INTENTIONAL, but it always leaves a sour taste in the mouth. People's
preferences for spacings and paddings are legitimate.
In addition, a larger spacing can be quite useful in Tablet Mode, to
increase the size of the touch targets to be closer to the size of the
user's finger.
This commit adds a simple UI to switch the spacings of the visible items
between three values, with the middle one that matches the current
spacing being the default. While Tablet Mode is activated, the spacing is
automatically set to its highest value and made non-user-adjustable,
just like we already do this for the icon size setting.
Applets were apparently blindly converted to use JSON metadata without
checking the usage. At least KPackage now has a direct getter for the
package metadata, so use that to get the plugin ID instead of manually
loading the package metadata.
BUG: 448529
It is important that we end plasma-core.target plasma-workspace.target
and graphical-session.target when we log out. graphical-session in turn
closes all other apps and daemons and prevents restarts.
Handling it in systemd gives the least racey option.
graphical-session used to be hanlded in the plasma-ksmserver service
file, but this was removed in 5.24 in a refactor where it caused issues
for Xwayland restarting.
This patch reintroduces the sentinel programs to close down our target,
which in turn take down the other targets. It also removes a complicated
use of templates that in hindsight didn't really solve anything.
BUG: 448492
Testing done:
- logout of wayland shows all targets as inactive, logging in
repeatedly works smoothly
- logout of X11 behaves the same.
- calling systemctl --user stop plasma-kwin_wayland.service closes the
session
- killing ksmserver on wayland does not close the session
- killing ksmserver on X does
This was removed in 88e9433e19 but probaly
should not have been, as doing so causes a binring loop on the width
property, even though there is no visual effect from the change.
`enabled` must be set in the backend because `visible` will always be
true after getting a valid nodeId, and sometimes we need to reset `enabled`
to false.
CCBUG: 449189
An input type agnostic way to activate systray items was needed. This
signal will be used for keyboard, mouse and touch navigation.
There was an activated() function that just started an animation which
has been renamed to startActivatedAnimation().
This makes it not be too wide due to the contentItem's margins, which
was an issue that went unnoticed because it was masked by always
disabling the horizontal scrollbar. Should we ever remove that override,
there won't be any regressions now.
We want to check the user-visible name, not the name of the file on disk.
In case we type "di", results like "Discord" or "Discover" are expected. With the old
logic however, we would reject discover, because the desktop file is called "org.kde.discover".
BUG: 443866
SessionManagementScreen is a FocusScope and needs focus explicitly assigned
to it. If inside a QQC2 StackView this is taken care of, but for some reason
in a QQC1 StackView this isn't the case for the initial item. Do it explicitly.
For these delegates, the width is computed automatically and correctly
from the parent ListView's width, taking into accounts margins and
scrollbar visibility.
SessionManagementScreen needs to be a FocusScope, so that when it gets focused
directly (through the StackView), it directs it to the proper control inside
instead of stealing it from them.
This fixes initial focus of the controls in the SDDM theme.
BUG: 447817
Double-quoted multi-line strings is a custom Qt/JS engine extension, and
as such it is better be avoided, since we have official widely
supported replacement.
GIT_SILENT
If invoked on gnome we should always return success
this is because a desktop file that has X-KDE-AutostartCondition
probably has an X-Gnome- equivalent and we only want one to run
this would match non systemd behaviour.
See also: https://github.com/systemd/systemd/pull/22115
This is something that came up in the monthly VDG meeting: the desktop
context menu has a lot of stuff in it, and we're looking to slim it down
where possible so it isn't so overwhelming.
One potential target is the Activities menu item, which has no real use
for a user who isn't using activities. We can never be 100% sure, but if
there is only one activity, it's a good bet the user isn't using the
feature. In this case, we can hide the menu item that shows the
switcher, because there's nothing to switch to!
Now, the switcher also has a button to add new activities, so it could
be argued that this change makes activities less discoverable. However
the feature is shown pretty prominently in the commonly-accessed
Workspace Behavior group in System Settings, so I think it's already
discoverable enough.
Test plan:
- Have one activity and right-click on the desktop > See no menu item
- Create a second activity and right-click on the desktop > See it
Here's how the menu looks now when there is only one activity:

cc @teams/vdg@ivan
An UI to manage Screen assignment of Containments, the main use case is to recover lost or inactive panels from a display that you can no longer access.
qml part: https://invent.kde.org/plasma/plasma-desktop/-/merge_requests/618
related to https://phabricator.kde.org/T14346
CCBUG: 447044
Access the dialog from Toolbar in Edit Mode (Manage containments)


To show the dialog, simply enter in `edit mode`, then you can :
* See known displays and their panels and desktops, the dialog automatically update when adding/moving/removing a panel.
* Delete a panel or a desktop
* Recover a panel by moving it to an active display (click on move icon, then select the proper action in drop menu)
* Recover a desktop by moving it to an active display, in fact, this will swap it with th targeted desktop
* Modifications are automatically applied
What I've tested:
* Adding a panel, adding some applet on it. Then disabling its display, open the dialog and move it to an active display, restarting session, the panel is here with its applet.
* On another display, add applets (sticky note) on the desktop. Disable this display, open the dialog and move it to an active display, restart session, both desktop were swapped and you see the background (if different) and sticky note available.
The original condition will turn the text in the search field into an
unknown character. Move the logic to switch-case to fix the condition.
BUG: 448819
We had all of this wired up correctly in the backend, it just turns out
that we overwrite all messages with "Unlocking failed" immediately.
BUG: 428613