public inbox for gentoo-commits@lists.gentoo.org
 help / color / mirror / Atom feed
* [gentoo-commits] repo/gentoo:master commit in: kde-plasma/kscreen/, kde-plasma/kscreen/files/
@ 2016-06-25 18:30 Michael Palimaka
  0 siblings, 0 replies; 6+ messages in thread
From: Michael Palimaka @ 2016-06-25 18:30 UTC (permalink / raw
  To: gentoo-commits

commit:     e8ecf8e32790fec99329c16cb2be96ce4f5ff513
Author:     Andreas Sturmlechner <andreas.sturmlechner <AT> gmail <DOT> com>
AuthorDate: Thu Jun 23 17:16:16 2016 +0000
Commit:     Michael Palimaka <kensington <AT> gentoo <DOT> org>
CommitDate: Sat Jun 25 18:30:28 2016 +0000
URL:        https://gitweb.gentoo.org/repo/gentoo.git/commit/?id=e8ecf8e3

kde-plasma/kscreen: Add fix for multiscreen config persistance

Reported-by: gorg86 (forums.gentoo.org)

https://forums.gentoo.org/viewtopic-t-1046956.html

Upstream bug: https://bugs.kde.org/show_bug.cgi?id=346961

Package-Manager: portage-2.2.28

 .../kscreen/files/kscreen-5.6.5-config-fix.patch   | 159 +++++++++++++++++++++
 kde-plasma/kscreen/kscreen-5.6.5-r1.ebuild         |  40 ++++++
 2 files changed, 199 insertions(+)

diff --git a/kde-plasma/kscreen/files/kscreen-5.6.5-config-fix.patch b/kde-plasma/kscreen/files/kscreen-5.6.5-config-fix.patch
new file mode 100644
index 0000000..56474aa
--- /dev/null
+++ b/kde-plasma/kscreen/files/kscreen-5.6.5-config-fix.patch
@@ -0,0 +1,159 @@
+From: Sebastian Kügler <sebas@kde.org>
+Date: Wed, 01 Jun 2016 14:54:16 +0000
+Subject: address race condition around setoperation
+X-Git-Tag: v5.6.95
+X-Git-Url: http://quickgit.kde.org/?p=kscreen.git&a=commitdiff&h=17199d32f292f7c44eb8cdce5b35396d3bd19eb8
+---
+address race condition around setoperation
+
+Summary:
+Use a timer to avoid catching configChanged signals after we set
+changes.
+
+The long version:
+
+TL;DR: We have a race condition when the kscreen daemon starts. It looks
+up a known config, then applies it and subsequently resaves the config.
+The same happens on config changes, it writes, then re-reads and then
+re-writes the config change.
+I've managed to prevent this from happening by adding a timer that does
+avoids saving the config as a direct reaction to our own config changes.
+
+So what happens on kded5 startup after loading the kscreen2 module:
+
+- the kscreen config is requested and received
+- the kscreen daemon (KD) looks into its config directory for a suitable
+config file
+(a config file is identified by a combined hash of all screen
+attached, so unique per connected set of outputs)
+- KD usually finds a config
+- KD ignores configChanged events before it starts ...
+- a KScreen::SetConfigOperation to apply the "known config"
+- SetConfigOperation returns after a while (say 100ms later)
+- we re-enable the change monitor
+- we receive a configChanged signal
+- we save the new config (usually to the existing config file)
+
+I don't think this behavior is desirable. I don't see a reason why the
+daemon should save its config right after applying it. I think this
+causes more problems than we want, since the startup may overwrite the
+user's config. This behavior seems to be desired by the code in KD, it's
+already blocking configChanged signals during the SetOperation (which,
+to be honest may result in nightmarish behavior in any way, so it might
+be a kludge which aims too short).
+
+From libkscreen perspective, SetConfigOperation::finished cannot
+guarantee that all configChanged signals are already fired and that it's
+safe to watch for new, independent changes now. At least on X11, we
+simply don't know, and what we can do is wait a bit and cross fingers
+that we're not catching our own noise. The changed signal *may* come
+from a re-request of the edid information, but this is a bit hard to
+track down, and not too useful, anyway, since changed Edid may affect a
+large number of a screen's properties.
+In the Wayland backend, that's a different story and we can prevent this
+behavior at an earlier stage, so this timer is "probably not needed" (I
+haven't tested that).
+
+This effectively prevents KD from catching reactions to its own changes
+and does not trigger saving the config file on every login. It still
+reacts to changes from libkscreen, but will avoid re-saving the config a
+few times. The timer may not be the neatest of solutions for this, but
+it does help narrowing down the problem and may be a last resort action.
+Most importantly, it avoids the re-writing of the config on startup and
+plugging/unplugging a monitor effectively.
+
+The timer value of 100ms is also used in kwin, which should make the
+behavior (which is no problem in kwin) more solid.
+
+CCBUG:346961
+CCBUG:358011
+
+Reviewers: graesslin
+
+Reviewed By: graesslin
+
+Subscribers: plasma-devel, #plasma
+
+Tags: #plasma
+
+Differential Revision: https://phabricator.kde.org/D1730
+---
+
+
+--- a/kded/daemon.cpp
++++ b/kded/daemon.cpp
+@@ -23,6 +23,7 @@
+ #include "kscreenadaptor.h"
+ #include "debug.h"
+ 
++#include <QElapsedTimer>
+ #include <QTimer>
+ #include <QAction>
+ #include <QShortcut>
+@@ -52,6 +53,7 @@
+  , m_buttonTimer(new QTimer())
+  , m_saveTimer(new QTimer())
+  , m_lidClosedTimer(new QTimer())
++ , m_changeBlockTimer(new QElapsedTimer())
+  
+ {
+     QMetaObject::invokeMethod(this, "requestConfig", Qt::QueuedConnection);
+@@ -82,6 +84,7 @@
+     delete m_saveTimer;
+     delete m_buttonTimer;
+     delete m_lidClosedTimer;
++    delete m_changeBlockTimer;
+ 
+     Generator::destroy();
+     Device::destroy();
+@@ -112,7 +115,6 @@
+     m_lidClosedTimer->setInterval(1000);
+     m_lidClosedTimer->setSingleShot(true);
+     connect(m_lidClosedTimer, &QTimer::timeout, this, &KScreenDaemon::lidClosedTimeout);
+-
+ 
+     connect(Device::self(), &Device::lidClosedChanged, this, &KScreenDaemon::lidClosedChanged);
+     connect(Device::self(), &Device::resumingFromSuspend,
+@@ -145,6 +147,9 @@
+     connect(new KScreen::SetConfigOperation(config), &KScreen::SetConfigOperation::finished,
+             [&]() {
+                 qCDebug(KSCREEN_KDED) << "Config applied";
++                // We enable monitoring already, but we will ignore the first signals that come
++                // in the next 100ms, since these are likely our own changes still flushing out
++                m_changeBlockTimer->start();
+                 setMonitorForChanges(true);
+             });
+ }
+@@ -182,6 +187,12 @@
+ 
+ void KScreenDaemon::configChanged()
+ {
++    if (m_changeBlockTimer->isValid() && !m_changeBlockTimer->hasExpired(100)) {
++        m_changeBlockTimer->start();
++        qCDebug(KSCREEN_KDED) << "Change detected, but ignoring since it's our own noise";
++        return;
++    }
++    m_changeBlockTimer->invalidate();
+     qCDebug(KSCREEN_KDED) << "Change detected";
+     // Reset timer, delay the writeback
+     m_saveTimer->start();
+
+--- a/kded/daemon.h
++++ b/kded/daemon.h
+@@ -27,6 +27,7 @@
+ 
+ #include "generator.h"
+ 
++class QElapsedTimer;
+ class QTimer;
+ 
+ namespace KScreen
+@@ -79,6 +80,7 @@
+         QTimer* m_buttonTimer;
+         QTimer* m_saveTimer;
+         QTimer* m_lidClosedTimer;
++        QElapsedTimer* m_changeBlockTimer;
+ };
+ 
+ #endif /*KSCREN_DAEMON_H*/
+

diff --git a/kde-plasma/kscreen/kscreen-5.6.5-r1.ebuild b/kde-plasma/kscreen/kscreen-5.6.5-r1.ebuild
new file mode 100644
index 0000000..a219d75
--- /dev/null
+++ b/kde-plasma/kscreen/kscreen-5.6.5-r1.ebuild
@@ -0,0 +1,40 @@
+# Copyright 1999-2016 Gentoo Foundation
+# Distributed under the terms of the GNU General Public License v2
+# $Id$
+
+EAPI=6
+
+KDE_TEST="forceoptional"
+inherit kde5
+
+DESCRIPTION="KDE Plasma screen management"
+HOMEPAGE="https://projects.kde.org/projects/extragear/base/kscreen"
+
+KEYWORDS="~amd64 ~arm ~x86"
+IUSE=""
+
+DEPEND="
+	$(add_frameworks_dep kconfig)
+	$(add_frameworks_dep kconfigwidgets)
+	$(add_frameworks_dep kcoreaddons)
+	$(add_frameworks_dep kdbusaddons)
+	$(add_frameworks_dep kglobalaccel)
+	$(add_frameworks_dep ki18n)
+	$(add_frameworks_dep kwidgetsaddons)
+	$(add_frameworks_dep kxmlgui)
+	$(add_plasma_dep libkscreen)
+	$(add_qt_dep qtdbus)
+	$(add_qt_dep qtdeclarative 'widgets')
+	$(add_qt_dep qtgui)
+	$(add_qt_dep qtwidgets)
+"
+RDEPEND="${DEPEND}
+	$(add_plasma_dep kde-cli-tools)
+	$(add_qt_dep qtgraphicaleffects)
+	!kde-misc/kscreen
+"
+
+PATCHES=( "${FILESDIR}/${P}-config-fix.patch" )
+
+# bug #580440, last checked 5.6.3
+RESTRICT="test"


^ permalink raw reply related	[flat|nested] 6+ messages in thread

* [gentoo-commits] repo/gentoo:master commit in: kde-plasma/kscreen/, kde-plasma/kscreen/files/
@ 2022-05-17 19:02 Andreas Sturmlechner
  0 siblings, 0 replies; 6+ messages in thread
From: Andreas Sturmlechner @ 2022-05-17 19:02 UTC (permalink / raw
  To: gentoo-commits

commit:     de40a4db73bc5972feef63106982b5db8f3f853a
Author:     Andreas Sturmlechner <asturm <AT> gentoo <DOT> org>
AuthorDate: Tue May 17 18:41:21 2022 +0000
Commit:     Andreas Sturmlechner <asturm <AT> gentoo <DOT> org>
CommitDate: Tue May 17 19:01:49 2022 +0000
URL:        https://gitweb.gentoo.org/repo/gentoo.git/commit/?id=de40a4db

kde-plasma/kscreen: Backport several 5.24.6 fixes

Package-Manager: Portage-3.0.30, Repoman-3.0.3
Signed-off-by: Andreas Sturmlechner <asturm <AT> gentoo.org>

 ...ct-ext-monitors-when-a-monitor-is-rotated.patch | 31 +++++++++++++
 ...reen-5.24.5-kcm-fix-choosing-refresh-rate.patch | 28 ++++++++++++
 ...4.5-kcm-fix-refresh-rate-list-not-updated.patch | 29 ++++++++++++
 kde-plasma/kscreen/kscreen-5.24.5-r1.ebuild        | 52 ++++++++++++++++++++++
 4 files changed, 140 insertions(+)

diff --git a/kde-plasma/kscreen/files/kscreen-5.24.5-fix-connect-ext-monitors-when-a-monitor-is-rotated.patch b/kde-plasma/kscreen/files/kscreen-5.24.5-fix-connect-ext-monitors-when-a-monitor-is-rotated.patch
new file mode 100644
index 000000000000..d2efce69b9e5
--- /dev/null
+++ b/kde-plasma/kscreen/files/kscreen-5.24.5-fix-connect-ext-monitors-when-a-monitor-is-rotated.patch
@@ -0,0 +1,31 @@
+From ff8dc215e8d2691fcf41d0bb305f820531d95150 Mon Sep 17 00:00:00 2001
+From: Aleix Pol <aleixpol@kde.org>
+Date: Sat, 14 May 2022 01:29:01 +0200
+Subject: [PATCH] Fix connecting external monitors when a monitor is rotated
+
+It would be placed right by the unrotated geometry and after rotating it
+the new output would end up floating in the logical space.
+This happened because the explicitLogicalSize is cached and needs
+updating after changing its settings.
+
+
+(cherry picked from commit cc832fd4296440fcd9298cb03b0cc736a99ed8bb)
+---
+ kded/generator.cpp | 1 +
+ 1 file changed, 1 insertion(+)
+
+diff --git a/kded/generator.cpp b/kded/generator.cpp
+index e5117a9..e311b04 100644
+--- a/kded/generator.cpp
++++ b/kded/generator.cpp
+@@ -85,6 +85,7 @@ KScreen::ConfigPtr Generator::idealConfig(const KScreen::ConfigPtr &currentConfi
+ 
+     for (const auto &output : connectedOutputs) {
+         initializeOutput(output, config->supportedFeatures());
++        output->setExplicitLogicalSize(config->logicalSizeForOutput(*output));
+     }
+ 
+     if (connectedOutputs.count() == 1) {
+-- 
+GitLab
+

diff --git a/kde-plasma/kscreen/files/kscreen-5.24.5-kcm-fix-choosing-refresh-rate.patch b/kde-plasma/kscreen/files/kscreen-5.24.5-kcm-fix-choosing-refresh-rate.patch
new file mode 100644
index 000000000000..2d0d3ba1e851
--- /dev/null
+++ b/kde-plasma/kscreen/files/kscreen-5.24.5-kcm-fix-choosing-refresh-rate.patch
@@ -0,0 +1,28 @@
+From 6ecb832923612820c721f58d1d12dd176e10528a Mon Sep 17 00:00:00 2001
+From: Xaver Hugl <xaver.hugl@gmail.com>
+Date: Thu, 5 May 2022 18:27:38 +0200
+Subject: [PATCH] kcm: fix choosing the refresh rate
+
+It always chose the last one, and not the highest one
+
+
+(cherry picked from commit 5e1be88dbe6e5160dcc232631df81d9bdc9d179e)
+---
+ kcm/output_model.cpp | 1 +
+ 1 file changed, 1 insertion(+)
+
+diff --git a/kcm/output_model.cpp b/kcm/output_model.cpp
+index 92e4ea3..3672b49 100644
+--- a/kcm/output_model.cpp
++++ b/kcm/output_model.cpp
+@@ -394,6 +394,7 @@ bool OutputModel::setResolution(int outputIndex, int resIndex)
+         auto it = modes.begin();
+         while (it != modes.end()) {
+             if ((*it)->size() == size && (*it)->refreshRate() > bestRefreshRate) {
++                bestRefreshRate = (*it)->refreshRate();
+                 modeIt = it;
+             }
+             it++;
+-- 
+GitLab
+

diff --git a/kde-plasma/kscreen/files/kscreen-5.24.5-kcm-fix-refresh-rate-list-not-updated.patch b/kde-plasma/kscreen/files/kscreen-5.24.5-kcm-fix-refresh-rate-list-not-updated.patch
new file mode 100644
index 000000000000..e7d85fd87013
--- /dev/null
+++ b/kde-plasma/kscreen/files/kscreen-5.24.5-kcm-fix-refresh-rate-list-not-updated.patch
@@ -0,0 +1,29 @@
+From 584ed8a067a7c0329e1572dd9970b6e3dae6a56f Mon Sep 17 00:00:00 2001
+From: Xaver Hugl <xaver.hugl@gmail.com>
+Date: Thu, 5 May 2022 18:22:46 +0200
+Subject: [PATCH] kcm: fix refresh rate list not being updated
+
+BUG: 453392
+
+
+(cherry picked from commit 8c1e2cffda762fef83ea48658a08847382c71486)
+---
+ kcm/output_model.cpp | 2 +-
+ 1 file changed, 1 insertion(+), 1 deletion(-)
+
+diff --git a/kcm/output_model.cpp b/kcm/output_model.cpp
+index fcdb738..92e4ea3 100644
+--- a/kcm/output_model.cpp
++++ b/kcm/output_model.cpp
+@@ -417,7 +417,7 @@ bool OutputModel::setResolution(int outputIndex, int resIndex)
+     QModelIndex index = createIndex(outputIndex, 0);
+     // Calling this directly ignores possible optimization when the
+     // refresh rate hasn't changed in fact. But that's ok.
+-    Q_EMIT dataChanged(index, index, {ResolutionIndexRole, ResolutionRole, SizeRole, RefreshRateIndexRole});
++    Q_EMIT dataChanged(index, index, {ResolutionIndexRole, ResolutionRole, SizeRole, RefreshRatesRole, RefreshRateIndexRole});
+     Q_EMIT sizeChanged();
+     return true;
+ }
+-- 
+GitLab
+

diff --git a/kde-plasma/kscreen/kscreen-5.24.5-r1.ebuild b/kde-plasma/kscreen/kscreen-5.24.5-r1.ebuild
new file mode 100644
index 000000000000..0fa224e22205
--- /dev/null
+++ b/kde-plasma/kscreen/kscreen-5.24.5-r1.ebuild
@@ -0,0 +1,52 @@
+# Copyright 1999-2022 Gentoo Authors
+# Distributed under the terms of the GNU General Public License v2
+
+EAPI=8
+
+ECM_TEST="forceoptional"
+KFMIN=5.90.0
+PVCUT=$(ver_cut 1-3)
+QTMIN=5.15.2
+inherit ecm kde.org
+
+DESCRIPTION="KDE Plasma screen management"
+HOMEPAGE="https://invent.kde.org/plasma/kscreen"
+
+LICENSE="GPL-2" # TODO: CHECK
+SLOT="5"
+KEYWORDS="~amd64 ~arm ~arm64 ~ppc64 ~riscv ~x86"
+IUSE=""
+
+# bug #580440, last checked 5.6.3
+RESTRICT="test"
+
+DEPEND="
+	>=dev-qt/qtdbus-${QTMIN}:5
+	>=dev-qt/qtdeclarative-${QTMIN}:5[widgets]
+	>=dev-qt/qtgui-${QTMIN}:5
+	>=dev-qt/qtsensors-${QTMIN}:5
+	>=dev-qt/qtwidgets-${QTMIN}:5
+	>=kde-frameworks/kcmutils-${KFMIN}:5
+	>=kde-frameworks/kconfig-${KFMIN}:5
+	>=kde-frameworks/kconfigwidgets-${KFMIN}:5
+	>=kde-frameworks/kcoreaddons-${KFMIN}:5
+	>=kde-frameworks/kdeclarative-${KFMIN}:5
+	>=kde-frameworks/kdbusaddons-${KFMIN}:5
+	>=kde-frameworks/kglobalaccel-${KFMIN}:5
+	>=kde-frameworks/ki18n-${KFMIN}:5
+	>=kde-frameworks/kiconthemes-${KFMIN}:5
+	>=kde-frameworks/kwidgetsaddons-${KFMIN}:5
+	>=kde-frameworks/kxmlgui-${KFMIN}:5
+	>=kde-frameworks/plasma-${KFMIN}:5
+	>=kde-plasma/libkscreen-${PVCUT}:5
+"
+RDEPEND="${DEPEND}
+	>=dev-qt/qtgraphicaleffects-${QTMIN}:5
+	>=kde-plasma/kde-cli-tools-${PVCUT}:5
+"
+
+PATCHES=(
+	"${FILESDIR}/${P}-kcm-fix-refresh-rate-list-not-updated.patch" # KDE-bug 453392
+	"${FILESDIR}/${P}-kcm-fix-choosing-refresh-rate.patch"
+	"${FILESDIR}/${P}-fix-connect-ext-monitors-when-a-monitor-is-rotated.patch"
+)


^ permalink raw reply related	[flat|nested] 6+ messages in thread

* [gentoo-commits] repo/gentoo:master commit in: kde-plasma/kscreen/, kde-plasma/kscreen/files/
@ 2023-03-26  9:52 Andreas Sturmlechner
  0 siblings, 0 replies; 6+ messages in thread
From: Andreas Sturmlechner @ 2023-03-26  9:52 UTC (permalink / raw
  To: gentoo-commits

commit:     3ded8160a8f1446c1d923adb8bb737bad58d1563
Author:     Andreas Sturmlechner <asturm <AT> gentoo <DOT> org>
AuthorDate: Fri Mar 24 20:54:45 2023 +0000
Commit:     Andreas Sturmlechner <asturm <AT> gentoo <DOT> org>
CommitDate: Sun Mar 26 09:50:05 2023 +0000
URL:        https://gitweb.gentoo.org/repo/gentoo.git/commit/?id=3ded8160

kde-plasma/kscreen: Display connector name instead of type name

...when serial number is identical

Upstream commit 7f2c1f8b104efb748cae5814ed2aa87fb2046796

KDE-bug: https://bugs.kde.org/show_bug.cgi?id=466046

Signed-off-by: Andreas Sturmlechner <asturm <AT> gentoo.org>

 .../kscreen-5.27.3-display-connector-name.patch    | 36 +++++++++++++++
 kde-plasma/kscreen/kscreen-5.27.3-r1.ebuild        | 51 ++++++++++++++++++++++
 2 files changed, 87 insertions(+)

diff --git a/kde-plasma/kscreen/files/kscreen-5.27.3-display-connector-name.patch b/kde-plasma/kscreen/files/kscreen-5.27.3-display-connector-name.patch
new file mode 100644
index 000000000000..54497b3d99f8
--- /dev/null
+++ b/kde-plasma/kscreen/files/kscreen-5.27.3-display-connector-name.patch
@@ -0,0 +1,36 @@
+From 74c99d3afda09d9a715c84150f0bb9afe4003c33 Mon Sep 17 00:00:00 2001
+From: David Redondo <kde@david-redondo.de>
+Date: Thu, 23 Mar 2023 09:37:27 +0100
+Subject: [PATCH] Display connector name instead of type name when serial
+ number is identical
+
+Displays the name of the connector ("DP-1") instead of just
+typeName ("DisplayPort"). When two identical outputs are connected
+to the same connector type it doesn't help differntiating.
+Furthermore it matches what will be shown by the output locator
+effect.
+BUG:466046
+FIXED-IN:5.27.4
+
+
+(cherry picked from commit 21155f81fee953d5b5e1bab92565b85ef99a0260)
+---
+ common/utils.cpp | 2 +-
+ 1 file changed, 1 insertion(+), 1 deletion(-)
+
+diff --git a/common/utils.cpp b/common/utils.cpp
+index 7aaa926..a9eb80c 100644
+--- a/common/utils.cpp
++++ b/common/utils.cpp
+@@ -35,7 +35,7 @@ QString Utils::outputName(const KScreen::Output *output, bool shouldShowSerialNu
+             name += output->edid()->serial() + QLatin1Char(' ');
+         }
+         if (shouldShowConnector) {
+-            name += output->typeName();
++            name += output->name();
+         }
+         if (!name.trimmed().isEmpty()) {
+             return name;
+-- 
+2.40.0
+

diff --git a/kde-plasma/kscreen/kscreen-5.27.3-r1.ebuild b/kde-plasma/kscreen/kscreen-5.27.3-r1.ebuild
new file mode 100644
index 000000000000..9c1f4faf09a7
--- /dev/null
+++ b/kde-plasma/kscreen/kscreen-5.27.3-r1.ebuild
@@ -0,0 +1,51 @@
+# Copyright 1999-2023 Gentoo Authors
+# Distributed under the terms of the GNU General Public License v2
+
+EAPI=8
+
+ECM_TEST="forceoptional"
+KFMIN=5.102.0
+PVCUT=$(ver_cut 1-3)
+QTMIN=5.15.7
+inherit ecm plasma.kde.org
+
+DESCRIPTION="KDE Plasma screen management"
+HOMEPAGE="https://invent.kde.org/plasma/kscreen"
+
+LICENSE="GPL-2" # TODO: CHECK
+SLOT="5"
+KEYWORDS="~amd64 ~arm ~arm64 ~loong ~ppc64 ~riscv ~x86"
+IUSE=""
+
+# bug #580440, last checked 5.6.3
+RESTRICT="test"
+
+DEPEND="
+	>=dev-qt/qtdbus-${QTMIN}:5
+	>=dev-qt/qtdeclarative-${QTMIN}:5[widgets]
+	>=dev-qt/qtgui-${QTMIN}:5
+	>=dev-qt/qtsensors-${QTMIN}:5
+	>=dev-qt/qtwidgets-${QTMIN}:5
+	>=kde-frameworks/kcmutils-${KFMIN}:5
+	>=kde-frameworks/kconfig-${KFMIN}:5
+	>=kde-frameworks/kconfigwidgets-${KFMIN}:5
+	>=kde-frameworks/kcoreaddons-${KFMIN}:5
+	>=kde-frameworks/kdeclarative-${KFMIN}:5
+	>=kde-frameworks/kdbusaddons-${KFMIN}:5
+	>=kde-frameworks/kglobalaccel-${KFMIN}:5
+	>=kde-frameworks/ki18n-${KFMIN}:5
+	>=kde-frameworks/kiconthemes-${KFMIN}:5
+	>=kde-frameworks/kwidgetsaddons-${KFMIN}:5
+	>=kde-frameworks/kxmlgui-${KFMIN}:5
+	>=kde-frameworks/plasma-${KFMIN}:5
+	>=kde-plasma/layer-shell-qt-${PVCUT}:5
+	>=kde-plasma/libkscreen-${PVCUT}:5
+	x11-libs/libX11
+"
+RDEPEND="${DEPEND}
+	>=dev-qt/qtgraphicaleffects-${QTMIN}:5
+	>=kde-plasma/kde-cli-tools-${PVCUT}:5
+"
+BDEPEND=">=kde-frameworks/kcmutils-${KFMIN}:5"
+
+PATCHES=( "${FILESDIR}/${P}-display-connector-name.patch" ) # KDE-bug 466046


^ permalink raw reply related	[flat|nested] 6+ messages in thread

* [gentoo-commits] repo/gentoo:master commit in: kde-plasma/kscreen/, kde-plasma/kscreen/files/
@ 2023-04-09 22:43 Andreas Sturmlechner
  0 siblings, 0 replies; 6+ messages in thread
From: Andreas Sturmlechner @ 2023-04-09 22:43 UTC (permalink / raw
  To: gentoo-commits

commit:     5c63907316d26abc7a8e5e7eafb8688bc4f34ac7
Author:     Andreas Sturmlechner <asturm <AT> gentoo <DOT> org>
AuthorDate: Sun Apr  9 22:05:05 2023 +0000
Commit:     Andreas Sturmlechner <asturm <AT> gentoo <DOT> org>
CommitDate: Sun Apr  9 22:34:21 2023 +0000
URL:        https://gitweb.gentoo.org/repo/gentoo.git/commit/?id=5c639073

kde-plasma/kscreen: kcm: notify global scale changes in kcmfonts

KDE-bug: https://bugs.kde.org/show_bug.cgi?id=468203

Signed-off-by: Andreas Sturmlechner <asturm <AT> gentoo.org>

 ...-notify-changes-when-global-scale-changes.patch | 37 ++++++++++++++++
 kde-plasma/kscreen/kscreen-5.27.4-r1.ebuild        | 51 ++++++++++++++++++++++
 2 files changed, 88 insertions(+)

diff --git a/kde-plasma/kscreen/files/kscreen-5.27.4-kcm-notify-changes-when-global-scale-changes.patch b/kde-plasma/kscreen/files/kscreen-5.27.4-kcm-notify-changes-when-global-scale-changes.patch
new file mode 100644
index 000000000000..9c1e862ff480
--- /dev/null
+++ b/kde-plasma/kscreen/files/kscreen-5.27.4-kcm-notify-changes-when-global-scale-changes.patch
@@ -0,0 +1,37 @@
+From e9384150d8e41dd9c869f5f502e02c70a5c6f002 Mon Sep 17 00:00:00 2001
+From: Fushan Wen <qydwhotmail@gmail.com>
+Date: Sat, 8 Apr 2023 00:33:24 +0800
+Subject: [PATCH] kcm: notify changes in kcmfonts when global scale changes
+
+Otherwise kde-gtk-config will use the old font DPI value.
+
+CCBUG: 468203
+---
+ kcm/kcm.cpp | 4 ++--
+ 1 file changed, 2 insertions(+), 2 deletions(-)
+
+diff --git a/kcm/kcm.cpp b/kcm/kcm.cpp
+index 6d96625d..f292699c 100644
+--- a/kcm/kcm.cpp
++++ b/kcm/kcm.cpp
+@@ -438,7 +438,7 @@ void KCMKScreen::exportGlobalScale()
+                 loadProc.waitForFinished();
+             }
+         }
+-        fontConfigGroup.writeEntry("forceFontDPI", 0);
++        fontConfigGroup.writeEntry("forceFontDPI", 0, KConfig::Notify);
+     } else {
+         const int scaleDpi = qRound(globalScale() * 96.0);
+         QProcess proc;
+@@ -448,7 +448,7 @@ void KCMKScreen::exportGlobalScale()
+             proc.closeWriteChannel();
+             proc.waitForFinished();
+         }
+-        fontConfigGroup.writeEntry("forceFontDPI", scaleDpi);
++        fontConfigGroup.writeEntry("forceFontDPI", scaleDpi, KConfig::Notify);
+     }
+ 
+     Q_EMIT globalScaleWritten();
+-- 
+GitLab
+

diff --git a/kde-plasma/kscreen/kscreen-5.27.4-r1.ebuild b/kde-plasma/kscreen/kscreen-5.27.4-r1.ebuild
new file mode 100644
index 000000000000..efbf3dea06d4
--- /dev/null
+++ b/kde-plasma/kscreen/kscreen-5.27.4-r1.ebuild
@@ -0,0 +1,51 @@
+# Copyright 1999-2023 Gentoo Authors
+# Distributed under the terms of the GNU General Public License v2
+
+EAPI=8
+
+ECM_TEST="forceoptional"
+KFMIN=5.102.0
+PVCUT=$(ver_cut 1-3)
+QTMIN=5.15.7
+inherit ecm plasma.kde.org
+
+DESCRIPTION="KDE Plasma screen management"
+HOMEPAGE="https://invent.kde.org/plasma/kscreen"
+
+LICENSE="GPL-2" # TODO: CHECK
+SLOT="5"
+KEYWORDS="~amd64 ~arm ~arm64 ~loong ~ppc64 ~riscv ~x86"
+IUSE=""
+
+# bug #580440, last checked 5.6.3
+RESTRICT="test"
+
+DEPEND="
+	>=dev-qt/qtdbus-${QTMIN}:5
+	>=dev-qt/qtdeclarative-${QTMIN}:5[widgets]
+	>=dev-qt/qtgui-${QTMIN}:5
+	>=dev-qt/qtsensors-${QTMIN}:5
+	>=dev-qt/qtwidgets-${QTMIN}:5
+	>=kde-frameworks/kcmutils-${KFMIN}:5
+	>=kde-frameworks/kconfig-${KFMIN}:5
+	>=kde-frameworks/kconfigwidgets-${KFMIN}:5
+	>=kde-frameworks/kcoreaddons-${KFMIN}:5
+	>=kde-frameworks/kdeclarative-${KFMIN}:5
+	>=kde-frameworks/kdbusaddons-${KFMIN}:5
+	>=kde-frameworks/kglobalaccel-${KFMIN}:5
+	>=kde-frameworks/ki18n-${KFMIN}:5
+	>=kde-frameworks/kiconthemes-${KFMIN}:5
+	>=kde-frameworks/kwidgetsaddons-${KFMIN}:5
+	>=kde-frameworks/kxmlgui-${KFMIN}:5
+	>=kde-frameworks/plasma-${KFMIN}:5
+	>=kde-plasma/layer-shell-qt-${PVCUT}:5
+	>=kde-plasma/libkscreen-${PVCUT}:5
+	x11-libs/libX11
+"
+RDEPEND="${DEPEND}
+	>=dev-qt/qtgraphicaleffects-${QTMIN}:5
+	>=kde-plasma/kde-cli-tools-${PVCUT}:5
+"
+BDEPEND=">=kde-frameworks/kcmutils-${KFMIN}:5"
+
+PATCHES=( "${FILESDIR}/${P}-kcm-notify-changes-when-global-scale-changes.patch" ) # KDE-bug 468203


^ permalink raw reply related	[flat|nested] 6+ messages in thread

* [gentoo-commits] repo/gentoo:master commit in: kde-plasma/kscreen/, kde-plasma/kscreen/files/
@ 2023-05-10 11:37 Andreas Sturmlechner
  0 siblings, 0 replies; 6+ messages in thread
From: Andreas Sturmlechner @ 2023-05-10 11:37 UTC (permalink / raw
  To: gentoo-commits

commit:     4ff79860762c6c2fec39ee90dfb52aba36bcead6
Author:     Andreas Sturmlechner <asturm <AT> gentoo <DOT> org>
AuthorDate: Wed May 10 11:33:51 2023 +0000
Commit:     Andreas Sturmlechner <asturm <AT> gentoo <DOT> org>
CommitDate: Wed May 10 11:37:06 2023 +0000
URL:        https://gitweb.gentoo.org/repo/gentoo.git/commit/?id=4ff79860

kde-plasma/kscreen: drop 5.27.4-r2

Signed-off-by: Andreas Sturmlechner <asturm <AT> gentoo.org>

 ...nullptrs-if-outputs-changed-during-saving.patch | 39 ----------------
 ...-notify-changes-when-global-scale-changes.patch | 37 ---------------
 kde-plasma/kscreen/kscreen-5.27.4-r2.ebuild        | 54 ----------------------
 3 files changed, 130 deletions(-)

diff --git a/kde-plasma/kscreen/files/kscreen-5.27.4-avoid-nullptrs-if-outputs-changed-during-saving.patch b/kde-plasma/kscreen/files/kscreen-5.27.4-avoid-nullptrs-if-outputs-changed-during-saving.patch
deleted file mode 100644
index 795773a679f6..000000000000
--- a/kde-plasma/kscreen/files/kscreen-5.27.4-avoid-nullptrs-if-outputs-changed-during-saving.patch
+++ /dev/null
@@ -1,39 +0,0 @@
-From 8af1cfac332f6f7c4e6db40c851dd5ac719236f1 Mon Sep 17 00:00:00 2001
-From: Harald Sitter <sitter@kde.org>
-Date: Mon, 17 Apr 2023 16:01:50 +0200
-Subject: [PATCH] don't stumble over nullptrs if outputs changed during saving
-
-exec() opens a nested eventloop that does event processing and may end
-up processing output changes when e.g. a screen is getting unplugged. as
-part of this our m_configHandler may get reset to null, so make sure the
-pointers are still valid after exec
-
-BUG: 466960
-
-
-(cherry picked from commit 0bfa16bd2b59ac9b2ce8112c06d86e5e29c69654)
----
- kcm/kcm.cpp | 7 +++++++
- 1 file changed, 7 insertions(+)
-
-diff --git a/kcm/kcm.cpp b/kcm/kcm.cpp
-index f292699c..931509eb 100644
---- a/kcm/kcm.cpp
-+++ b/kcm/kcm.cpp
-@@ -172,6 +172,13 @@ void KCMKScreen::doSave()
-     m_stopUpdatesFromBackend = true;
-     op->exec();
- 
-+    // exec() opens a nested eventloop that may have unset m_configHandler if (e.g.)
-+    // outputs changed during saving. https://bugs.kde.org/show_bug.cgi?id=466960
-+    if (!m_configHandler || !m_configHandler->config()) {
-+        Q_EMIT errorOnSave();
-+        return;
-+    }
-+
-     const auto updateInitialData = [this]() {
-         if (!m_configHandler || !m_configHandler->config()) {
-             return;
--- 
-GitLab
-

diff --git a/kde-plasma/kscreen/files/kscreen-5.27.4-kcm-notify-changes-when-global-scale-changes.patch b/kde-plasma/kscreen/files/kscreen-5.27.4-kcm-notify-changes-when-global-scale-changes.patch
deleted file mode 100644
index 9c1e862ff480..000000000000
--- a/kde-plasma/kscreen/files/kscreen-5.27.4-kcm-notify-changes-when-global-scale-changes.patch
+++ /dev/null
@@ -1,37 +0,0 @@
-From e9384150d8e41dd9c869f5f502e02c70a5c6f002 Mon Sep 17 00:00:00 2001
-From: Fushan Wen <qydwhotmail@gmail.com>
-Date: Sat, 8 Apr 2023 00:33:24 +0800
-Subject: [PATCH] kcm: notify changes in kcmfonts when global scale changes
-
-Otherwise kde-gtk-config will use the old font DPI value.
-
-CCBUG: 468203
----
- kcm/kcm.cpp | 4 ++--
- 1 file changed, 2 insertions(+), 2 deletions(-)
-
-diff --git a/kcm/kcm.cpp b/kcm/kcm.cpp
-index 6d96625d..f292699c 100644
---- a/kcm/kcm.cpp
-+++ b/kcm/kcm.cpp
-@@ -438,7 +438,7 @@ void KCMKScreen::exportGlobalScale()
-                 loadProc.waitForFinished();
-             }
-         }
--        fontConfigGroup.writeEntry("forceFontDPI", 0);
-+        fontConfigGroup.writeEntry("forceFontDPI", 0, KConfig::Notify);
-     } else {
-         const int scaleDpi = qRound(globalScale() * 96.0);
-         QProcess proc;
-@@ -448,7 +448,7 @@ void KCMKScreen::exportGlobalScale()
-             proc.closeWriteChannel();
-             proc.waitForFinished();
-         }
--        fontConfigGroup.writeEntry("forceFontDPI", scaleDpi);
-+        fontConfigGroup.writeEntry("forceFontDPI", scaleDpi, KConfig::Notify);
-     }
- 
-     Q_EMIT globalScaleWritten();
--- 
-GitLab
-

diff --git a/kde-plasma/kscreen/kscreen-5.27.4-r2.ebuild b/kde-plasma/kscreen/kscreen-5.27.4-r2.ebuild
deleted file mode 100644
index f7712247e82d..000000000000
--- a/kde-plasma/kscreen/kscreen-5.27.4-r2.ebuild
+++ /dev/null
@@ -1,54 +0,0 @@
-# Copyright 1999-2023 Gentoo Authors
-# Distributed under the terms of the GNU General Public License v2
-
-EAPI=8
-
-ECM_TEST="forceoptional"
-KFMIN=5.102.0
-PVCUT=$(ver_cut 1-3)
-QTMIN=5.15.7
-inherit ecm plasma.kde.org
-
-DESCRIPTION="KDE Plasma screen management"
-HOMEPAGE="https://invent.kde.org/plasma/kscreen"
-
-LICENSE="GPL-2" # TODO: CHECK
-SLOT="5"
-KEYWORDS="amd64 ~arm arm64 ~loong ~ppc64 ~riscv x86"
-IUSE=""
-
-# bug #580440, last checked 5.6.3
-RESTRICT="test"
-
-DEPEND="
-	>=dev-qt/qtdbus-${QTMIN}:5
-	>=dev-qt/qtdeclarative-${QTMIN}:5[widgets]
-	>=dev-qt/qtgui-${QTMIN}:5
-	>=dev-qt/qtsensors-${QTMIN}:5
-	>=dev-qt/qtwidgets-${QTMIN}:5
-	>=kde-frameworks/kcmutils-${KFMIN}:5
-	>=kde-frameworks/kconfig-${KFMIN}:5
-	>=kde-frameworks/kconfigwidgets-${KFMIN}:5
-	>=kde-frameworks/kcoreaddons-${KFMIN}:5
-	>=kde-frameworks/kdeclarative-${KFMIN}:5
-	>=kde-frameworks/kdbusaddons-${KFMIN}:5
-	>=kde-frameworks/kglobalaccel-${KFMIN}:5
-	>=kde-frameworks/ki18n-${KFMIN}:5
-	>=kde-frameworks/kiconthemes-${KFMIN}:5
-	>=kde-frameworks/kwidgetsaddons-${KFMIN}:5
-	>=kde-frameworks/kxmlgui-${KFMIN}:5
-	>=kde-frameworks/plasma-${KFMIN}:5
-	>=kde-plasma/layer-shell-qt-${PVCUT}:5
-	>=kde-plasma/libkscreen-${PVCUT}:5
-	x11-libs/libX11
-"
-RDEPEND="${DEPEND}
-	>=dev-qt/qtgraphicaleffects-${QTMIN}:5
-	>=kde-plasma/kde-cli-tools-${PVCUT}:5
-"
-BDEPEND=">=kde-frameworks/kcmutils-${KFMIN}:5"
-
-PATCHES=(
-	"${FILESDIR}/${P}-kcm-notify-changes-when-global-scale-changes.patch" # KDE-bug 468203
-	"${FILESDIR}/${P}-avoid-nullptrs-if-outputs-changed-during-saving.patch" # KDE-bug 466960
-)


^ permalink raw reply related	[flat|nested] 6+ messages in thread

* [gentoo-commits] repo/gentoo:master commit in: kde-plasma/kscreen/, kde-plasma/kscreen/files/
@ 2023-09-24 21:47 Andreas Sturmlechner
  0 siblings, 0 replies; 6+ messages in thread
From: Andreas Sturmlechner @ 2023-09-24 21:47 UTC (permalink / raw
  To: gentoo-commits

commit:     beb5670f68dee46f558dd195ab11d7e145b024a3
Author:     Andreas Sturmlechner <asturm <AT> gentoo <DOT> org>
AuthorDate: Sun Sep 24 19:41:15 2023 +0000
Commit:     Andreas Sturmlechner <asturm <AT> gentoo <DOT> org>
CommitDate: Sun Sep 24 21:46:49 2023 +0000
URL:        https://gitweb.gentoo.org/repo/gentoo.git/commit/?id=beb5670f

kde-plasma/kscreen: Only modify `Coordinate Transformation Matrix`

KDE-bug: https://bugs.kde.org/show_bug.cgi?id=474110

Signed-off-by: Andreas Sturmlechner <asturm <AT> gentoo.org>

 ...screen-5.27.8-libinput-calibration-matrix.patch | 60 ++++++++++++++++++++++
 kde-plasma/kscreen/kscreen-5.27.8-r2.ebuild        | 55 ++++++++++++++++++++
 2 files changed, 115 insertions(+)

diff --git a/kde-plasma/kscreen/files/kscreen-5.27.8-libinput-calibration-matrix.patch b/kde-plasma/kscreen/files/kscreen-5.27.8-libinput-calibration-matrix.patch
new file mode 100644
index 000000000000..f6e404ae1d52
--- /dev/null
+++ b/kde-plasma/kscreen/files/kscreen-5.27.8-libinput-calibration-matrix.patch
@@ -0,0 +1,60 @@
+From 49dbf9b9fb021d63ef5b712460483e6fe8c23a1c Mon Sep 17 00:00:00 2001
+From: theofficial gman <dofficialgman@gmail.com>
+Date: Sun, 24 Sep 2023 11:59:21 +0000
+Subject: [PATCH] Only modify `Coordinate Transformation Matrix`
+
+Allow `libinput Calibration Matrix` to exist as whatever it has set to by default.
+This allows for a UDEV rule to be made to set the calibration matrix in cases where
+the display and touchscreen do not have the same orientation or pixel sizing.
+This now matches the mutter implementation.
+
+BUG: 474110
+
+If my authorship is unsuitable (no real name used), I give permission for you to pick and reauthor at your wish.
+
+
+(cherry picked from commit c8f33c8fa3b194c883443457801119016cbbfe9f)
+---
+ kded/daemon.cpp | 9 +--------
+ 1 file changed, 1 insertion(+), 8 deletions(-)
+
+diff --git a/kded/daemon.cpp b/kded/daemon.cpp
+index f7cadee2..63ddf51a 100644
+--- a/kded/daemon.cpp
++++ b/kded/daemon.cpp
+@@ -483,7 +483,6 @@ void KScreenDaemon::alignX11TouchScreen()
+     if (matrixAtom == 0) {
+         return;
+     }
+-    auto calibrationMatrixAtom = getAtom(connection, "libinput Calibration Matrix");
+     auto floatAtom = getAtom(connection, "FLOAT");
+     if (floatAtom == 0) {
+         return;
+@@ -532,23 +531,17 @@ void KScreenDaemon::alignX11TouchScreen()
+         std::unique_ptr<Atom, XDeleter> properties(XIListProperties(display, info->id, &nProperties));
+ 
+         bool matrixAtomFound = false;
+-        bool libInputCalibrationAtomFound = false;
+ 
+         Atom *atom = properties.get();
+         Atom *atomEnd = properties.get() + nProperties;
+         for (; atom != atomEnd; atom++) {
+             if (!internalOutputRect.isEmpty() && *atom == matrixAtom) {
+                 matrixAtomFound = true;
+-            } else if (!internalOutputRect.isEmpty() && *atom == calibrationMatrixAtom) {
+-                libInputCalibrationAtomFound = true;
+             }
+         }
+ 
+-        if (libInputCalibrationAtomFound) {
+-            setMatrixAtom(info, calibrationMatrixAtom, transform);
+-        }
+         if (matrixAtomFound) {
+-            setMatrixAtom(info, matrixAtom, libInputCalibrationAtomFound ? QTransform() : transform);
++            setMatrixAtom(info, matrixAtom, transform);
+         }
+ 
+         // For now we assume there is only one touchscreen
+-- 
+GitLab
+

diff --git a/kde-plasma/kscreen/kscreen-5.27.8-r2.ebuild b/kde-plasma/kscreen/kscreen-5.27.8-r2.ebuild
new file mode 100644
index 000000000000..4016d62b3484
--- /dev/null
+++ b/kde-plasma/kscreen/kscreen-5.27.8-r2.ebuild
@@ -0,0 +1,55 @@
+# Copyright 1999-2023 Gentoo Authors
+# Distributed under the terms of the GNU General Public License v2
+
+EAPI=8
+
+ECM_TEST="forceoptional"
+KFMIN=5.106.0
+PVCUT=$(ver_cut 1-3)
+QTMIN=5.15.9
+inherit ecm plasma.kde.org
+
+DESCRIPTION="KDE Plasma screen management"
+HOMEPAGE="https://invent.kde.org/plasma/kscreen"
+
+LICENSE="GPL-2" # TODO: CHECK
+SLOT="5"
+KEYWORDS="~amd64 ~arm ~arm64 ~loong ~ppc64 ~riscv ~x86"
+IUSE=""
+
+# bug #580440, last checked 5.6.3
+RESTRICT="test"
+
+DEPEND="
+	>=dev-qt/qtdbus-${QTMIN}:5
+	>=dev-qt/qtdeclarative-${QTMIN}:5[widgets]
+	>=dev-qt/qtgui-${QTMIN}:5
+	>=dev-qt/qtsensors-${QTMIN}:5
+	>=dev-qt/qtwidgets-${QTMIN}:5
+	>=dev-qt/qtx11extras-${QTMIN}:5
+	>=kde-frameworks/kcmutils-${KFMIN}:5
+	>=kde-frameworks/kconfig-${KFMIN}:5
+	>=kde-frameworks/kcoreaddons-${KFMIN}:5
+	>=kde-frameworks/kdeclarative-${KFMIN}:5
+	>=kde-frameworks/kdbusaddons-${KFMIN}:5
+	>=kde-frameworks/kglobalaccel-${KFMIN}:5
+	>=kde-frameworks/ki18n-${KFMIN}:5
+	>=kde-frameworks/kwindowsystem-${KFMIN}:5
+	>=kde-frameworks/kxmlgui-${KFMIN}:5
+	>=kde-frameworks/plasma-${KFMIN}:5
+	>=kde-plasma/layer-shell-qt-${PVCUT}:5
+	>=kde-plasma/libkscreen-${PVCUT}:5=
+	x11-libs/libX11
+	x11-libs/libxcb:=
+	x11-libs/libXi
+"
+RDEPEND="${DEPEND}
+	>=dev-qt/qtgraphicaleffects-${QTMIN}:5
+	>=kde-plasma/kde-cli-tools-${PVCUT}:5
+"
+BDEPEND=">=kde-frameworks/kcmutils-${KFMIN}:5"
+
+PATCHES=(
+	"${FILESDIR}/${P}-cmake.patch" # bug 914142
+	"${FILESDIR}/${P}-libinput-calibration-matrix.patch" # KDE-bug 474110
+)


^ permalink raw reply related	[flat|nested] 6+ messages in thread

end of thread, other threads:[~2023-09-24 21:47 UTC | newest]

Thread overview: 6+ messages (download: mbox.gz follow: Atom feed
-- links below jump to the message on this page --
2022-05-17 19:02 [gentoo-commits] repo/gentoo:master commit in: kde-plasma/kscreen/, kde-plasma/kscreen/files/ Andreas Sturmlechner
  -- strict thread matches above, loose matches on Subject: below --
2023-09-24 21:47 Andreas Sturmlechner
2023-05-10 11:37 Andreas Sturmlechner
2023-04-09 22:43 Andreas Sturmlechner
2023-03-26  9:52 Andreas Sturmlechner
2016-06-25 18:30 Michael Palimaka

This is a public inbox, see mirroring instructions
for how to clone and mirror all data and code used for this inbox