Commit graph

926 commits

Author SHA1 Message Date
Alexander Lohnau
1a38ea6aba Port to KCM desktop file generation method from kcmutils
This de-duplicates the translations needed for the KCMs.

Task: https://phabricator.kde.org/T15609
2022-07-24 15:52:12 +00:00
Vlad Zahorodnii
aa739c59cf wayland: Make mapping from xinerama indices to Output correct
We assume that outputs in kwinApp()->platform()->enabledOutputs() are
stored in the xinerama order. However, this is not the case on Wayland
and it's not going to be changed because it increases the complexity.

This change makes Workspace::xineramaIndexToOutput() use Xinerama
extension API to map a xinerama index to the associated Output object.

With this, Xwayland applications will be able to put on outputs as
expected.

Note that xinerama indices are not cached because
Workspace::xineramaIndexToOutput() is not used in any hot code path. If
that changes, xinerama indices can be cached. The cache must be
invalidated whenever we get screens changed notify event from RANDR.
2022-07-18 13:52:58 +00:00
Aleix Pol
d5ddf55e9b gbm: Don't pass any flags when creating buffers with modifiers
It seems it doesn't bring much and it may backfire. Especially don't
pass GBM_BO_USE_LINEAR as it will limit a lot the buffers that can be
created and GBM_BO_USE_RENDERING use seems to be more harmful than
helpful on most cases.
2022-07-04 22:52:40 +00:00
Jonathan Esk-Riddell
dfc6c87057 Update qt5 version requirement to 5.15.2
GIT_SILENT
2022-06-27 10:02:35 +01:00
Aleix Pol
aa59344be7 Platform: Improve our infrastructure to support dmabufs in backends
Allows creating buffers with modifiers.
Lets the windowed wayland backend support it, which makes testing
everything else much simpler.
2022-06-16 13:18:32 +00:00
Méven Car
9cc73a5bc6 Bump KF5_MIN_VERSION after b069aad160e514ec2f933f654ddcbbc6aca59ed5
GIT_SILENT
NO_CHANGELOG
2022-05-21 12:14:14 +02:00
Jonathan Esk-Riddell
e08cd40e8e Update version number for 5.25.80
GIT_SILENT
2022-05-19 12:25:51 +01:00
Jonathan Esk-Riddell
8f009c2db1 Update version number for 5.24.90
GIT_SILENT
2022-05-19 10:41:30 +01:00
Nicolas Fella
a902e78ff4 Mark libxcvt as required
It's used unconditionally later on

Make sure it fails at the appropriate time when not found
2022-05-11 23:24:09 +02:00
Nicolas Fella
774dbf8d2f Use ECMFindQmlModule instead of ECMQmlModules 2022-05-09 15:22:49 +02:00
Xaver Hugl
14e7afcb4e color management: refactor and move to its own directory
The pipeline stages are also now properly managed, which should prevent
use-after-free errors.

BUG: 453026
2022-04-26 16:20:47 +00:00
Alexander Lohnau
719e97194d Port KWin Scripts KCM to QML
Task: https://phabricator.kde.org/T7289
2022-04-24 09:58:34 +00:00
Xaver Hugl
08ad2c8ed3 add libxcvt as a new hard dependency 2022-04-23 19:45:48 +00:00
Vlad Zahorodnii
b64f95b703 Integrate kwaylandserver
This makes KWin switch to in-tree copy of KWaylandServer codebase.

KWaylandServer namespace has been left as is. It will be addressed later
by renaming classes in order to fit in the KWin namespace.
2022-04-22 12:27:33 +03:00
Xaver Hugl
f6eee463ba Make lcms2 a hard dependency
When we do more color management stuff we'll need it in more places,
making it a hard requirement reduces the amount of needed ifdefs and
should make adding color management features a little simpler.
2022-04-20 12:21:38 +02:00
Andreas Sturmlechner
2aaa9ed5c2 Add missing KF5Auth dependency
Used in src/helpers/killer

Signed-off-by: Andreas Sturmlechner <asturm@gentoo.org>
2022-03-30 09:40:44 +00:00
Vlad Zahorodnii
8fe567c4fa Add pre-commit hook for clang-format 2022-03-25 13:25:20 +02:00
Volker Krause
2a171e5fa8 Adapt build system to also support building against Qt6 2022-03-25 08:26:49 +00:00
Alex Richardson
0a0a1fd330 Use __has_include() instead of check_include_file()
Allows removing some CMake checks config-kwin.h contents. This is
supported by all compilers and required for C++17. While touching those
lines I also cleaned up an unnecessary HAVE_UNISTD_H check (glibc always
has it and and incorrect use of HAVE_SYS_PROCCTL_H.
2022-03-17 11:39:58 +02:00
Vlad Zahorodnii
994c5c24ae Drop fbdev backend
fbdev has been deprecated and unmaintained for a while. With Linux 5.14
including SimpleDRM driver, we can drop it. (at the time of writing this
commit message, the latest Linux version is 5.16).
2022-03-17 09:13:21 +00:00
Vlad Zahorodnii
b0982f7bbc wayland: Drop ptrace logic
kwin disables ptrace for a good reason - to prevent other processes from
attaching to kwin and snooping sensitive data or taking control of kwin.
But, that will also make things such as memory statistics unavailable to
read, etc.

On the other hand, the supported platforms where kwin runs all have
security measures in places to forbid shady processes ptrace'ing kwin.
For example, on Linux it's YAMA.

On Linux, by default, a process can ptrace only its descendants. For
example, this can be used by debuggers; otherwise you would need to be
the superuser to attach to any process.

This change drops our ptrace logic in favor of system provided security
measures. It allows the System Monitor to gather kwin's memory usage
statistics and also simplifies code, the current debugger detection
logic is not really robust.

If the system provided security measures are proven to be insufficient,
we can add the ptrace disabling logic back, but it would be great to
avoid that because system monitor won't be able to gather resource usage
statistics, which can be useful for detecting memory leaks in plasma
wayland session, etc.
2022-03-16 14:16:14 +00:00
Kai Uwe Broulik
9f9e32e57d Remove unused Qt QuickWidgets dependency
Signed-off-by: Victoria Fischer <victoria.fischer@mbition.io>
2022-03-16 11:31:09 +00:00
Kai Uwe Broulik
0793c24249 Add KWIN_BUILD_NOTIFICATIONS option
Notifications are really only useful in a setting with a full
shell environment where there is a notification center to display them.

Signed-off-by: Victoria Fischer <victoria.fischer@mbition.io>
2022-03-03 15:06:36 +01:00
Kai Uwe Broulik
d54723cbf2 Add KWIN_BUILD_SCREENLOCKER option
Allows to build KWin without lockscreen support and thus drops the
kscreenlocker dependency.

Signed-off-by: Eike Hein <eike.hein@mbition.io>
2022-02-23 14:39:25 +01:00
Kai Uwe Broulik
5db527a053 effects/mousemark: Port away from KPluralHandlingSpinBox
It's the only user of KTextWidgets in the entire repository.

Signed-off-by: Eike Hein <eike.hein@mbition.io>
2022-02-23 13:48:43 +01:00
Kai Uwe Broulik
aef8ba8d1a Port KComboBox to QComboBox
None of the features it adds ontop of `QComboBox` are used.

Allows to drop the dependency on KCompletion.

Signed-off-by: Eike Hein <eike.hein@mbition.io>
2022-02-23 11:28:47 +00:00
Kai Uwe Broulik
00f2dc1d88 Remove KIconThemes dependency
It has been unused since 7706e17d but was left in CMakeLists.txt

Signed-off-by: Eike Hein <eike.hein@mbition.io>
2022-02-15 08:43:15 +00:00
Nicolas Fella
a2ebad760f Implement services in our QPA
This is required for QDesktopServices to work.

Use QGenericUnixServices like the xcb and wayland QPA

BUG: 446144
2022-02-13 00:41:10 +01:00
Albert Astals Cid
858da39fa4 Increase minimum requirements
A newer kwindowsystem is needed for NET::WM2GTKApplicationId

kwin and kwayland-server version must match
2022-01-28 22:53:12 +00:00
Laurent Montel
f23ef4c858 Use not deprecated SYSTEMD_USER_UNIT_INSTALL_DIR 2022-01-18 07:03:45 +01:00
Jonathan Riddell
11763bb32c Update version number for 5.24.80
GIT_SILENT
2022-01-13 11:56:02 +00:00
Jonathan Riddell
307fcdf0e1 Update version number for 5.23.90
GIT_SILENT
2022-01-13 10:33:58 +00:00
Vlad Zahorodnii
e81a360194 Bump libepoxy to 1.3
1.3 has been released in 2015 which is sufficiently old enough.
2022-01-02 22:30:06 +02:00
Alexander Lohnau
bd17ca0110 kwinscripts kcm: Port to new KPluginWidget class
Task: https://phabricator.kde.org/T12265
2021-12-03 06:15:34 +00:00
David Edmundson
f4b870977b Re-enable systemd managed kwin
This was blocked on environment variables issues which are now resolved
2021-12-02 13:25:50 +00:00
David Edmundson
b3f5f9764f [kwin_wrapper] Sync kwin env after spawning 2021-12-02 13:25:50 +00:00
Alexander Lohnau
70a2fb877a Register KWin effect macros for moc
Otherwise we get lots of moc warnings about there not being any relevant macro used
2021-11-24 10:48:51 +00:00
Alexander Lohnau
66352bfc87 Utilize KCoreAddons infrastructure for static plugins 2021-11-24 10:48:51 +00:00
Xaver Hugl
c68f7f13f3 backends/drm,wayland: require gbm
The ifdefs for have_gbm obfuscate the code unnecessarily - the drm backend
is not a great experience with qpainter, so in practice noone should ship
it without gbm anyways.
2021-11-12 08:25:15 +00:00
Xaver Hugl
bad5752110 platforms/drm: kill the EglStreams backend
The proprietary NVidia driver now supports gbm, which vastly improves the
user experience. For older devices that will not get gbm support dropping
EglStreams will likely not have a big impact as it has several session breaking
issues anyways.

By removing the backend a lot of logic can be simplified, most notably multi-gpu.
2021-11-10 11:43:36 +00:00
Xaver Hugl
6ff4de2e05 port everything away from Q_FOREACH 2021-11-08 14:19:05 +00:00
David Redondo
60c3b3ddfa Add support for hold gestures 2021-10-26 08:16:52 +00:00
Vlad Zahorodnii
d6f02abad0 cmake: Make KF5Wayland required again
wayland platform plugin uses KF::Wayland.
2021-10-12 06:32:55 +00:00
Nicolas Fella
310684f1a7 Fix build by lowering KDE_COMPILERSETTINGS_LEVEL
It doesn't build against the stricter 5.85 level
2021-10-11 21:59:39 +02:00
Jonathan Riddell
57c06d0e00 Update kf5 version requirement to 5.86
GIT_SILENT
2021-10-11 20:48:20 +01:00
Vlad Zahorodnii
5be593d4e4 wayland: Drop internal connection
It's practically unused now.
2021-10-07 13:28:08 +00:00
Alex Richardson
8ab41804f0 Increase minimum KDecoration2 version
I just got a build failure because I hadn't updated KDecoration to
include 195bcf36df.
Bump the minimum version to trigger a CMake error instead of a
compilation failure. Since we expect to be using the same version of
KDecoration as KWin, this change uses ${PROJECT_VERSION} as the minimum
version.
2021-10-07 07:40:16 +00:00
Jonathan Riddell
35ff7eb0ed Update version number for 5.23.80
GIT_SILENT
2021-09-16 10:33:42 +01:00
Jonathan Riddell
ebc7851671 Update version number for 5.22.90
GIT_SILENT
2021-09-16 09:21:13 +01:00
Méven Car
2eb5da1d6f Port autotests/integration/outputmanagement_test to kde_output_management_v2 2021-09-14 14:42:31 +00:00
Ismael Asensio
2aacea5026 Set a minimum version check for pipewire
Fixes compilation on systems with a lesser version than required
The minimum version is set to 0.3.29 as indicated in
https://invent.kde.org/plasma/kwin/-/merge_requests/1210
2021-09-04 04:24:07 +02:00
Xaver Hugl
5cc5d81cea guard gbm version for gbm_bo_get_fd_for_plane 2021-08-25 14:39:35 +00:00
Laurent Montel
ee4c9cd6d5 Fix compile with last ecm
(With
https://invent.kde.org/frameworks/extra-cmake-modules/-/merge_requests/145
we have disabled the C and C++ specific compiler extensions)
2021-06-28 08:03:12 +02:00
Nicolas Fella
1e36e79fa3 Remove unused KIO dependency 2021-06-09 16:18:41 +02:00
Vlad Zahorodnii
811beb94e0 Remove Xrender backend
The Xrender backend was added at the time when OpenGL drivers were not
particularly stable. Nowadays though, it's a totally different situation.

The OpenGL render backend has been the default one for many years. It's
quite stable, and it allows implementing many advanced features that
other render backends don't.

Many features are not tested with it during the development cycle; the
only time when it is noticed is when changes in other parts of kwin break
the build in the xrender backend. Effectively, the xrender backend is
unmaintained nowadays.

Given that the xrender backend is effectively unmaintained and our focus
being shifted towards wayland, this change drops the xrender backend in
favor of the opengl backend.

Besides being de-facto unmaintained, another issue is that QtQuick does
not support and most likely will never support the Xrender API. This
poses a problem as we want thumbnail items to be natively integrated in
the qtquick scene graph.
2021-06-09 11:21:57 +03:00
Vlad Zahorodnii
7a063f9ab7 Build kwin with QT_NO_KEYWORDS 2021-06-08 10:52:15 +03:00
Vlad Zahorodnii
77a9d38166 Make libdrm required dependency
As is, kwin with the drm backend results in the most pleasant user
experience on Wayland. Given that and the fbdev being about to be
dropped, making libdrm a required dependency seems a reasonable decision.
2021-05-14 18:00:40 +00:00
Aleix Pol
3b05823f1f libinput: bump required version
So we can remove ifdefs and weird cases to support versions that are far
too old to support anyway.
2021-05-14 17:47:46 +00:00
Jonathan Riddell
2f0088de93 Update version number for 5.22.80
GIT_SILENT
2021-05-13 15:09:31 +01:00
Jonathan Riddell
0efc9e8e7f Update version number for 5.21.90
GIT_SILENT
2021-05-13 10:21:29 +01:00
Jonathan Riddell
2358a9b031 Update kf5 version requirement to 5.82
GIT_SILENT
2021-05-13 09:56:06 +01:00
Andrey Butirsky
91f47c9092 fix global shortcuts for non-Latin symbols
Re-use Qt's implementation of handling non-Latin layouts here
For full ASCII range support (Alt+`, etc.) Qt needs to be patched still,
see QTBUG-90611

BUG: 375518
2021-04-05 19:39:06 +00:00
Vlad Zahorodnii
ade861d6de Refactor session code
At the moment, the session code is far from being extensible. If we
decide to add support for libseatd, it will be a challenging task with
the current design of session management code. The goal of this
refactoring is to fix that.

Another motivation behind this change is to prepare session related code
for upstreaming to kwayland-server where it belongs.
2021-03-23 08:01:19 +00:00
Nicolas Fella
d7ab631e98 Find ECM with KF5 min version
Instead of some randon older version
2021-03-04 15:11:30 +00:00
Nicolas Fella
b7e13da70f Merge two CMAKE_MODULE_PATH set calls 2021-03-04 15:11:30 +00:00
Nicolas Fella
c777d5a3a7 Raise minimum CMake version to 3.16
As discussed in https://mail.kde.org/pipermail/plasma-devel/2021-February/119329.html

GIT_SILENT
2021-03-04 12:47:58 +01:00
Vlad Zahorodnii
6a26540065 wayland: Query pkg-config if Xwayland supports listenfd
-listen <fd> option is deprecated in favor of the -listenfd option. This
change makes kwin query whether Xwayland supports the -listenfd option
at build time. If the pkg-config file is missing, we'll use the old listen
option.
2021-03-02 13:29:22 +00:00
Aleix Pol
b409f523f0 Revert "cmake: Get XKB information directly from PkgConfig"
This reverts commit 3c97cecdb0.

It seems to break on the CI and I don't understand why.
2021-03-02 02:14:39 +01:00
Aleix Pol
3c97cecdb0 cmake: Get XKB information directly from PkgConfig
Rather than having it abstracted in a local FindXKB package.
Makes the code more standard and removes a custom finder we ultimately
don't need.
2021-03-01 20:33:38 +01:00
Vlad Zahorodnii
bd4d17b3a1 Drop QtScript dependency
QtScript is not used anywhere anymore plus it's dropped in Qt 6.
2021-02-23 07:47:01 +00:00
David Faure
abab1660aa Define -DQT_NO_CAST_TO_ASCII and fix compilation 2021-02-19 11:00:27 +02:00
Vlad Zahorodnii
93e0265e4e Move source code to src/ directory
Once in a while, we receive complaints from other fellow KDE developers
about the file organization of kwin. This change addresses some of those
complaints by moving all of source code in a separate directory, src/,
thus making the project structure more traditional. Things such as tests
are kept in their own toplevel directories.

This change may wreak havoc on merge requests that add new files to kwin,
but if a patch modifies an already existing file, git should be smart
enough to figure out that the file has been relocated.

We may potentially split the src/ directory further to make navigating
the source code easier, but hopefully this is good enough already.
2021-02-10 15:31:43 +00:00
Nicolas Fella
eedb8e44ea Use imported target for Threads 2021-02-09 20:32:29 +01:00
Nicolas Fella
a110231f68 Use imported target for QtGui private headers
It's nicer
2021-02-09 19:59:51 +01:00
Laurent Montel
3c63750f6e GIT_SILENT: don't use deprecated cmake variable 2021-02-08 20:19:33 +01:00
Nicolas Fella
99947c8bd8 Use versionless Qt cmake target
This makes it easier to build against both Qt5 and Qt6

GIT_SILENT
2021-01-30 17:18:21 +01:00
Laurent Montel
88b6076b2f GIT_SILENT: dont use deprecated cmake variable 2021-01-29 11:34:52 +01:00
David Edmundson
ca81be6635 Fix the systemd wayland boot
Plasma-workspace currently starts kwin_wayland before afterwards
continuing to spawn the full session, through whatever mechanism.

We ultimately want to just have systemd manage everything all at once,
but this was not realised in time for 5.21 due to a problem of
propogating environment variables.

By removing this file we go to a working state with the option enabled,
and can build on it for the next release.

BUG: 432189
2021-01-27 13:47:56 +00:00
Jonathan Riddell
f47ae2c0c5 Update version number for 5.21.80
GIT_SILENT
2021-01-21 13:38:08 +00:00
Jonathan Riddell
6f51a9cc8f Update kf5 version requirement to 5.78
GIT_SILENT
2021-01-21 12:28:31 +00:00
Jonathan Riddell
a0c7f997d4 Update version number for 5.20.90
GIT_SILENT
2021-01-21 12:07:20 +00:00
Vlad Zahorodnii
907480037a cmake: Don't search for Qt5Sensors 2021-01-15 23:30:25 +02:00
Vlad Zahorodnii
15d6be5c0c cmake: Drop Qt5::Sensors dependency
QOrientationSensor is no longer used by kwin.
2021-01-15 23:27:32 +02:00
Vlad Zahorodnii
19461f4413 cmake: Don't list linked libraries in variables
If a non-existing variable is used, no warning will be printed.
2021-01-15 23:18:20 +02:00
David Edmundson
85d04cf60d Add ftrace markers
This logs to a tracefs filesystem which can be viewed in tools such as
gpuvis to see precise timings of activities in relation to other trace
markers in X or graphic drivers.

This patch is loosely based on D23114. Though modified with thread
safety, support for string building, and a RAII pattern for durations.
Ultimately that expanded it somewhat.
2021-01-14 09:31:59 +00:00
Vlad Zahorodnii
5bf421ef83 cmake: Specify min version for wayland-protocols 2021-01-07 09:50:55 +00:00
Vlad Zahorodnii
5302094f30 cmake: Link against imported Xinput target 2021-01-07 09:50:24 +00:00
Vlad Zahorodnii
b67f743795 cmake: Drop libkwin's unused Xlib dependencies 2021-01-07 09:50:24 +00:00
Vlad Zahorodnii
ad5f8c5c59 Introduce RenderJournal
Currently, we estimate the expected render time purely based on the
latency policy.

The problem with doing so is that the real render time might be larger,
this can result in frame drops.

In order to avoid frame drops, we need to take into account previous
render times while estimating the next render time. For now, we just
measure how long it takes to record rendering commands on the CPU.

In the future, we might want consider using OpenGL timer queries for
measuring the real render time, but for now, it's good enough.
2021-01-06 16:59:29 +00:00
Vlad Zahorodnii
b8a70e62d5 Introduce RenderLoop
At the moment, our frame scheduling infrastructure is still heavily
based on Xinerama-style rendering. Specifically, we assume that painting
is driven by a single timer, etc.

This change introduces a new type - RenderLoop. Its main purpose is to
drive compositing on a specific output, or in case of X11, on the
overlay window.

With RenderLoop, compositing is synchronized to vblank events. It
exposes the last and the next estimated presentation timestamp. The
expected presentation timestamp can be used by effects to ensure that
animations are synchronized with the upcoming vblank event.

On Wayland, every outputs has its own render loop. On X11, per screen
rendering is not possible, therefore the platform exposes the render
loop for the overlay window. Ideally, the Scene has to expose the
RenderLoop, but as the first step towards better compositing scheduling
it's good as is for the time being.

The RenderLoop tries to minimize the latency by delaying compositing as
close as possible to the next vblank event. One tricky thing about it is
that if compositing is too close to the next vblank event, animations
may become a little bit choppy. However, increasing the latency reduces
the choppiness.

Given that, there is no any "silver bullet" solution for the choppiness
issue, a new option has been added in the Compositing KCM to specify the
amount of latency. By default, it's "Medium," but if a user is not
satisfied with the upstream default, they can tweak it.
2021-01-06 16:59:29 +00:00
Nate Graham
3800181ac2 Revert "cmake: Remove redundant include_directories()"
This reverts commit 9b1ea1c7f7.

This breaks compilation; apparently the include is not implicit and is
thus needed after all.
2021-01-05 19:29:15 -07:00
Vlad Zahorodnii
26b249061e cmake: Remove FindUDev.cmake
It's in extra-cmake-modules now.
2021-01-05 23:08:47 +02:00
Vlad Zahorodnii
9b1ea1c7f7 cmake: Remove redundant include_directories()
libkwin is linked against imported XKB::XKB target. Thus the
include_directories() is redundant.
2021-01-05 22:58:04 +02:00
Vlad Zahorodnii
7e5c16989e Drop hwcomposer backend
Plasma Mobile announced that they plan to drop support for Halium
devices, see the announcement blog post [1] for the reasons that led to
such a decision.

But just to summarize, here are some of the key points from the post:

 * Some of our team members no longer have access to reference LG Nexus
   5X device anymore
 * After KDE Neon switched to using Ubuntu 20.04 we no longer are
   updating the rootfs for halium devices
 * After several important architecture changes in upstream KWin, the
   hwcomposer backend might be broken and we have no way of verifying it

If the community members are interested in reviving the hwcomposer
backend,

  * it pretty much needs rewrite/re-thinking given differences of hwc1
    and hwc2 API for hwcomposer part of it, see also [2]
  * It also needs removal of Android 5 based libhardware API as we don't
    think code can be kept sane with 3 different levels of ifdefs
  * This backend needs better way of fixing difference between
    CAF/non-CAF devices then just recompiling with different headers,
    maybe env vars?
  * This backend does not support various things like transformation/
    rotation etc, and is not exactly feature complete as the DRM backend

[1] https://www.plasma-mobile.org/2020/12/14/plasma-mobile-technical-debt.html
[2] 83f563c339
2021-01-05 17:38:36 +00:00
Vlad Zahorodnii
ccfaf1a1d6 cmake: Rework how tabbox is conditionally compiled into libkwin
In modern CMake code, it is highly advised to avoid using variables. One
should instead try to use targets and properties more extensively.
2020-12-31 11:00:27 +00:00
Vlad Zahorodnii
9af78c0e7f cmake: Rework how activities support is compiled into libkwin
In modern CMake code, it is highly advised to avoid using variables. One
should instead try to use targets and properties more extensively.
2020-12-31 11:00:27 +00:00
Vlad Zahorodnii
d16c15301f cmake: Rework Findepoxy.cmake
This makes Findepoxy.cmake more upstreamable and easier to use.
2020-12-31 10:52:03 +00:00
Vlad Zahorodnii
79ca5ccd26 Merge OutputScreens into Screens
Since all platforms have been ported to AbstractOutput, OutputScreens
can be merged into Screens. This simplifies the class hierarchy.
2020-12-17 13:36:30 +00:00
Vlad Zahorodnii
64ad9a61d8 Introduce ColorManager component
This change introduces a new component - ColorManager that is
responsible for color management stuff.

At the moment, it's very naive. It is useful only for updating gamma
ramps. But in the future, it will be extended with more CMS-related
features.

The ColorManager depends on lcms2 library. This is an optional
dependency. If lcms2 is not installed, the color manager won't be built.

This also fixes the issue where colord and nightcolor overwrite each
other's gamma ramps. With this change, the ColorManager will resolve the
conflict between two.
2020-12-13 23:53:33 +02:00
Vlad Zahorodnii
b06fb6b060 Drop redundant find_package(Qt5Multimedia)
We need the multimedia component only to play preview videos in a KCM.

The find_package(Qt5Multimedia) is not needed because we already check
if Qt5Multimedia QML module is present using ecm_find_qmlmodule().

The main motivation behind this change is to work around constant build
failures caused by buggy config file of the Qt5::Multimedia component.
2020-12-13 16:22:35 +02:00