with this, if the configured color scheme was changed, or if the color scheme
file was updated, the colors will be reapplied and the plasma svg cache discarded
save on config the hash of the current color scheme file
the normal defaults cascading mechanism for application colors doesn't work, as header colors would be wrong, so check if colors are missing from kdeglobals and in that case apply the colors from lnf to kdeglobals
Changes how plasma_session works. Instead of just starting the
processes, plays the startup sound and stays around. This process then
gets to be terminated as the session ends.
BUG: 359651
BUG: 433293
Systemd units which are symlinked to the service directory will be in
`linked` or `linked-runtime` state. They are also available and
runnable. This can happen when the package manager uses symlinks to
install systemd units instead of copying them, like on NixOS.
StartPlasma's fontDPI syncs the current font DPI to xrdb, which affects
font DPI for X applications (inc apps run in xwayland)
This is seldom used on wayland as with framebuffer scaling you don't
want to adjust your font DPI, but it is used by some users. As it's
xrdb, it needs to come after Xwayland is started for the wayland case.
The goal of this patch is to move towards killing the
startplasma-waylandsession binary as well as just being better design to
have these things comparmentalised.
kcminit is very early in the boot process before all GUI apps with the
exception of ksplash. I don't think this will make a big difference as
that's just a picture anyway?
From what I can tell these aren't used by anybody, and not something we
want to be using whilst we increase our wayland support.
Grepping through all of KDE, the only usage I found was kde 4's
KApplication and that code is exclusively checking for
"KDE_SESSION_VERSION==4" which will be false anyway.
The version in kdelibs4support checks for the env variable too.
- Remove check for kded and confupdate stages in SplashApp, those setStage()
calls were removed a long time ago[1]
- Rename 'kinit' stage to 'startPlasma', since it's called from startplasma
- Remove startKDEInit(), it was declared but not defined anywhere, most
likely left-over from a previous refactor.
https://phabricator.kde.org/R297:185afa8a3af8002172d8f5d6aa08c57244422a12
"If $XDG_CONFIG_DIRS is either not set or empty, a value equal to
/etc/xdg should be used."
If XDG_CONFIG_DIRS was not set prior to startplasma, which it ordinarily
would not be, then the previous code would set the value to "$newdir:"
which was silly and also wrong as per the spec quoted above. Instead
default to /etc/xdg/.
Also camelCase the variables to follow our coding style.
This commit changes what counts as the default settings to take into account the default
settings of the current Global Theme.
e.g. if you change the Global Theme to Breeze Dark, when you go to the color KCM, clicking
the "Defaults" button will revert to the Breeze Dark color scheme (because it is the default
color scheme of the active Global Theme), rather than Breeze Light.
If a service has recently failed multiple times, systemd will (quite
cleverly) not restart it. This includes DBus activation so is indepdent
of the systemd boot.
If a service gets into a broken state on a previous session where ithas
different environment variables and a different display server, we
shouldn't treat it as failed for a new session.
This shouldn't be needed with the other recent fixes, but it seems like
a good practice nevertheless.
Gnome are doing something similar:
https://gitlab.gnome.org/GNOME/gnome-session/-/blob/master/gnome-session/main.c#L565
ListUnitByNames did not quite work as the author (me) expected. Whilst a
search for "adsfasf" yeilded an empty list a well-formed name like
"asdfasdf.service" would return a result to say that service was not
loaded.
This means our runtime detection of xdg-autostart-generator failed.
By using ListUnitFilesByPatterns we can filter on the status in the
query, meaning this code works again. We also can query the case of it
being available but explicitly disabled.
BUG: 433333
This add fix to avoid session specific environement variable to be
leaked into new session.
Also, it will restore the old systemd session variable upon shutting
down.
systemd provides a desktop diagnostic place for user to set environment
variables. Currently we only export to it but didn't import from it.
This would also import from it so we are able to use environment.d to
set environment even systemd unit based plasma is not used.
xdg-desktop.target was the name at the time of first being written, but
it was renamed upstream.. I had both on my system from a previous
compilation.
plasma-workspace.target already "Wants" the correctly named one.
Noticed by Benjamin Berg
Summary:
This brings numerous advantages such as:
- easier admin configuration with drop-ins, overrides and multiple
hooks throughout (and only having to learn one tool)
- session cleanup on exit, avoiding that occasional part where shutdown
hangs
- startup that actually knows when things are up
- race free autostart and DBus activation at once
- logs that rotate are split by service and usable
- resource management through slices and cgroups (the part I want)
Over the past 2 years I've been trying to tidy up and encapsulate the
relevant parts of startup into the binary plasma-session so that we can
just runtime swap out that one part and supporting both paths will be
easy.
Support is toggleable via cmake flag, as it seems like it should be a
distro decision, especially as we will require a specific systemd with
the xdg-generator.
KDED/kwin/other services are attached to the relevant repo.
Task T11914
Differential Revision: https://phabricator.kde.org/D28305
squash
This existed to include the .kde directories in the search paths for
ghostscript, which clearly hasn't been the case for years, but the code
has kept getting ported and migrated.
At some point this has got broken, startplasma-x11 doesn't call this
path and we've not had any bug reports. We may as well clear this
legacy.
This reverts commit edc64d04a1.
This commit unfortunately caused a serious regression. Another approach
will be needed to solve 176650 and 417070.
BUG: 423995
FIXED-IN: 5.19.4
CCMAIL: alexander.lohnau@gmx.de
This reverts commit edc64d04a1.
This commit unfortunately caused a serious regression. Another approach
will be needed to solve 176650 and 417070.
BUG: 423995
FIXED-IN: 5.19.4
CCMAIL: alexander.lohnau@gmx.de
Startplasma monitors ksmserver and tears down the session if it goes
away, to match previous behaviour and as some lockscreen bypass
protection.
When we teardown our new binary plasma-shutdown appears, runs scripts
and makes the final shutdown call. ksmserver could gracefully quit in
the meantime, so startplasma guarded this case and waited till both
names exited. However it contains a really stupid typo.
BUG: 422870
Summary:
Sort environment scripts before they are sourced. User scripts should run after system scripts to ensure that user preferences take precendence over system defaults. Scripts in each location (user and system) are then separately sorted in lexical order to ensure deterministic source order.
BUG: 420085
FIXED-IN: 5.19.0
Reviewers: #plasma, davidedmundson, apol
Reviewed By: apol
Subscribers: cfeck, plasma-devel
Tags: #plasma
Differential Revision: https://phabricator.kde.org/D28941
Summary:
It was safeguarded by an environment variable so we don't retroactively
change behaviour of existing setups in a bugfix update.
See https://phabricator.kde.org/D27883
Test Plan: Compiles
Reviewers: #plasma, apol
Reviewed By: apol
Subscribers: plasma-devel
Tags: #plasma
Differential Revision: https://phabricator.kde.org/D28300
Summary:
Currently startplasma spawns plasma-session then sits around waiting for
that to finish
plasma-session spawns all the startup then also just sits around doing
nothing
This patch makes plasma-session spawn all the startup and then quit.
It also splits the owner of the org.kde.shutdown interface to be on
demand. plasma-shutdown asks ksmserver to quit and then if applicable
runs the shutdown scripts or not.
Startplasma then knows when to exit by monitoring the DBus service
status directly.
The benefits are that we save some resources by not needing
plasma-session lingering about.
It also means the shutdown interface is re-usable as-is when the pending
systemd startup method is used.
Test Plan:
Logged in and:
- ran killall ksmserver, session ended as before
- logged out and cancelled due to unsaved changes
- logged out and completed logout
- logged out and rebooted
Reviewers: #plasma, apol
Reviewed By: apol
Subscribers: apol, plasma-devel
Tags: #plasma
Differential Revision: https://phabricator.kde.org/D27629
Summary:
Since ksmserver was split, start-plasma launches plasma-session which in
turn invokes ksmserver.
Test Plan: No code changes, only a method rename
Reviewers: #plasma, broulik, apol
Reviewed By: #plasma, broulik, apol
Subscribers: plasma-devel
Tags: #plasma
Differential Revision: https://phabricator.kde.org/D27621