public inbox for gentoo-commits@lists.gentoo.org
 help / color / mirror / Atom feed
From: "Andreas Sturmlechner" <asturm@gentoo.org>
To: gentoo-commits@lists.gentoo.org
Subject: [gentoo-commits] repo/gentoo:master commit in: kde-frameworks/plasma/, kde-frameworks/plasma/files/
Date: Tue, 23 Nov 2021 14:59:34 +0000 (UTC)	[thread overview]
Message-ID: <1637679551.6cd2d37aef9a8974b31772a99496f0905e25c64b.asturm@gentoo> (raw)

commit:     6cd2d37aef9a8974b31772a99496f0905e25c64b
Author:     Andreas Sturmlechner <asturm <AT> gentoo <DOT> org>
AuthorDate: Mon Nov 15 14:38:30 2021 +0000
Commit:     Andreas Sturmlechner <asturm <AT> gentoo <DOT> org>
CommitDate: Tue Nov 23 14:59:11 2021 +0000
URL:        https://gitweb.gentoo.org/repo/gentoo.git/commit/?id=6cd2d37a

kde-frameworks/plasma: Visual fixes

Make the OSD an actual wayland OSD
KDE-bug: https://bugs.kde.org/show_bug.cgi?id=428859
Upstream commit 2ba1b0b642d540f74f0e21e7aaa272644ea4eda5

Fixed a visual glitch with Plasma tooltips flickering
KDE-bug: https://bugs.kde.org/show_bug.cgi?id=305247
Upstream commit 6176d8ef8f36290075c5bd8932d623e68468a1cd

Fix centered icons and text in Plasma applet tabs
KDE-bug: https://bugs.kde.org/show_bug.cgi?id=442830
Upstream commit 92ac1038cff333d70a71331b2a5fa0b9d91bc39d

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

 .../files/plasma-5.88.0-fix-centered-text.patch    | 121 +++++++++++++++++++++
 ....88.0-fix-misrenderings-with-transparency.patch |  34 ++++++
 ...sma-5.88.0-make-OSD-an-actual-wayland-OSD.patch |  34 ++++++
 kde-frameworks/plasma/plasma-5.88.0-r1.ebuild      |  79 ++++++++++++++
 4 files changed, 268 insertions(+)

diff --git a/kde-frameworks/plasma/files/plasma-5.88.0-fix-centered-text.patch b/kde-frameworks/plasma/files/plasma-5.88.0-fix-centered-text.patch
new file mode 100644
index 000000000000..8fb393a568d6
--- /dev/null
+++ b/kde-frameworks/plasma/files/plasma-5.88.0-fix-centered-text.patch
@@ -0,0 +1,121 @@
+From 92ac1038cff333d70a71331b2a5fa0b9d91bc39d Mon Sep 17 00:00:00 2001
+From: Eugene Popov <popov895@ukr.net>
+Date: Fri, 19 Nov 2021 11:13:03 +0000
+Subject: [PATCH] Fix IconLabel
+
+---
+ .../plasmacomponents3/private/IconLabel.qml   | 97 +++++++++++--------
+ 1 file changed, 55 insertions(+), 42 deletions(-)
+
+diff --git a/src/declarativeimports/plasmacomponents3/private/IconLabel.qml b/src/declarativeimports/plasmacomponents3/private/IconLabel.qml
+index 467c2f54b..74a8ff3a5 100644
+--- a/src/declarativeimports/plasmacomponents3/private/IconLabel.qml
++++ b/src/declarativeimports/plasmacomponents3/private/IconLabel.qml
+@@ -24,49 +24,62 @@ T.Control {
+     PlasmaCore.ColorScope.inherit: true
+     implicitWidth: implicitContentWidth + leftPadding + rightPadding
+     implicitHeight: implicitContentHeight + topPadding + bottomPadding
+-    contentItem: GridLayout {
+-        rowSpacing: root.spacing
+-        columnSpacing: root.spacing
+-        flow: root.display === T.AbstractButton.TextUnderIcon ? GridLayout.TopToBottom : GridLayout.LeftToRight
+-        PlasmaCore.IconItem {
+-            id: iconItem
+-            visible: valid && width > 0 && height > 0 && root.display !== T.AbstractButton.TextOnly
+-            colorGroup: root.PlasmaCore.ColorScope.colorGroup
+-            implicitWidth: PlasmaCore.Units.iconSizes.sizeForLabels
+-            implicitHeight: PlasmaCore.Units.iconSizes.sizeForLabels
+-            Layout.fillWidth: true
+-            Layout.fillHeight: true
+-            Layout.maximumWidth: implicitWidth > 0 ? implicitWidth : Number.POSITIVE_INFINITY
+-            Layout.maximumHeight: implicitHeight > 0 ? implicitHeight : Number.POSITIVE_INFINITY
+-            Layout.alignment: if (root.textBesideIcon) {
+-                Qt.AlignRight | Qt.AlignVCenter
+-            } else if (root.textUnderIcon) {
+-                Qt.AlignHCenter | Qt.AlignBottom
+-            } else {
+-                Qt.AlignCenter
++    contentItem: Item {
++        implicitWidth: gridLayout.implicitWidth
++        implicitHeight: gridLayout.implicitHeight
++        GridLayout {
++            id: gridLayout
++            rowSpacing: root.spacing
++            columnSpacing: root.spacing
++            flow: root.display === T.AbstractButton.TextUnderIcon ? GridLayout.TopToBottom : GridLayout.LeftToRight
++            x: {
++                if (root.alignment & Qt.AlignLeft) {
++                    return 0;
++                }
++                if (root.alignment & Qt.AlignRight) {
++                    return parent.width - width;
++                }
++                return Math.round((parent.width - width) / 2);
+             }
+-        }
+-        T.Label {
+-            id: label
+-            visible: text.length > 0 && root.display !== T.AbstractButton.IconOnly
+-            palette: root.palette
+-            font: root.font
+-            horizontalAlignment: root.alignment & Qt.AlignHorizontal_Mask || Text.AlignHCenter
+-            verticalAlignment: root.alignment & Qt.AlignVertical_Mask || Text.AlignVCenter
+-            // Work around Qt bug where NativeRendering breaks for non-integer scale factors
+-            // https://bugreports.qt.io/browse/QTBUG-70481
+-            renderType: Screen.devicePixelRatio % 1 !== 0 ? Text.QtRendering : Text.NativeRendering
+-            color: PlasmaCore.ColorScope.textColor
+-            linkColor: PlasmaCore.Theme.linkColor
+-            elide: Text.ElideRight
+-            Layout.fillWidth: root.alignment & Qt.AlignHorizontal_Mask
+-            Layout.fillHeight: root.alignment & Qt.AlignVertical_Mask
+-            Layout.alignment: if (root.textBesideIcon) {
+-                Qt.AlignLeft | Qt.AlignVCenter
+-            } else if (root.textUnderIcon) {
+-                Qt.AlignHCenter | Qt.AlignTop
+-            } else {
+-                Qt.AlignCenter
++            y: {
++                if (root.alignment & Qt.AlignTop) {
++                    return 0;
++                }
++                if (root.alignment & Qt.AlignBottom) {
++                    return parent.height - height;
++                }
++                return Math.round((parent.height - height) / 2);
++            }
++            width: Math.min(parent.width, implicitWidth)
++            height: Math.min(parent.height, implicitHeight)
++            PlasmaCore.IconItem {
++                id: iconItem
++                visible: valid && width > 0 && height > 0 && root.display !== T.AbstractButton.TextOnly
++                colorGroup: root.PlasmaCore.ColorScope.colorGroup
++                implicitWidth: PlasmaCore.Units.iconSizes.sizeForLabels
++                implicitHeight: PlasmaCore.Units.iconSizes.sizeForLabels
++                Layout.alignment: Qt.AlignCenter
++                Layout.maximumWidth: implicitWidth > 0 ? implicitWidth : Number.POSITIVE_INFINITY
++                Layout.maximumHeight: implicitHeight > 0 ? implicitHeight : Number.POSITIVE_INFINITY
++            }
++            T.Label {
++                id: label
++                visible: text.length > 0 && root.display !== T.AbstractButton.IconOnly
++                palette: root.palette
++                font: root.font
++                // Work around Qt bug where NativeRendering breaks for non-integer scale factors
++                // https://bugreports.qt.io/browse/QTBUG-70481
++                renderType: Screen.devicePixelRatio % 1 !== 0 ? Text.QtRendering : Text.NativeRendering
++                color: PlasmaCore.ColorScope.textColor
++                linkColor: PlasmaCore.Theme.linkColor
++                elide: Text.ElideRight
++                Layout.alignment: Qt.AlignCenter
++                Layout.fillWidth: {
++                    if (!iconItem.visible || parent.flow === GridLayout.TopToBottom) {
++                        return implicitWidth > parent.width;
++                    }
++                    return iconItem.implicitWidth + parent.columnSpacing + implicitWidth > parent.width;
++                }
+             }
+         }
+     }
+-- 
+GitLab
+

diff --git a/kde-frameworks/plasma/files/plasma-5.88.0-fix-misrenderings-with-transparency.patch b/kde-frameworks/plasma/files/plasma-5.88.0-fix-misrenderings-with-transparency.patch
new file mode 100644
index 000000000000..d1e6f37d8a2b
--- /dev/null
+++ b/kde-frameworks/plasma/files/plasma-5.88.0-fix-misrenderings-with-transparency.patch
@@ -0,0 +1,34 @@
+From 6176d8ef8f36290075c5bd8932d623e68468a1cd Mon Sep 17 00:00:00 2001
+From: Marco Martin <notmart@gmail.com>
+Date: Tue, 16 Nov 2021 11:05:17 +0100
+Subject: [PATCH] Do updateTheme after QQuickWindow::event
+
+doing updatetheme there will ensure that the window size is correct,
+so then when the surface commit will happen, we'll have the blur
+and contrast regions wit hthe proper geometry
+
+BUG:305247
+---
+ src/plasmaquick/dialog.cpp | 2 ++
+ 1 file changed, 2 insertions(+)
+
+diff --git a/src/plasmaquick/dialog.cpp b/src/plasmaquick/dialog.cpp
+index eac7d432a..343bfe4c0 100644
+--- a/src/plasmaquick/dialog.cpp
++++ b/src/plasmaquick/dialog.cpp
+@@ -1243,10 +1243,12 @@ bool Dialog::event(QEvent *event)
+         // sometimes non null regions arrive even for non visible windows
+         // for which surface creation would fail
+         if (!d->shellSurface && isVisible()) {
++            const bool ret = QQuickWindow::event(event);
+             KWindowSystem::setState(winId(), NET::SkipTaskbar | NET::SkipPager | NET::SkipSwitcher);
+             d->setupWaylandIntegration();
+             d->updateVisibility(true);
+             d->updateTheme();
++            return ret;
+         }
+ #endif
+     } else if (event->type() == QEvent::PlatformSurface) {
+-- 
+GitLab
+

diff --git a/kde-frameworks/plasma/files/plasma-5.88.0-make-OSD-an-actual-wayland-OSD.patch b/kde-frameworks/plasma/files/plasma-5.88.0-make-OSD-an-actual-wayland-OSD.patch
new file mode 100644
index 000000000000..0631155c89bf
--- /dev/null
+++ b/kde-frameworks/plasma/files/plasma-5.88.0-make-OSD-an-actual-wayland-OSD.patch
@@ -0,0 +1,34 @@
+From 2ba1b0b642d540f74f0e21e7aaa272644ea4eda5 Mon Sep 17 00:00:00 2001
+From: Marco Martin <notmart@gmail.com>
+Date: Mon, 8 Nov 2021 16:12:38 +0000
+Subject: [PATCH] make the OSD an actual wayland OSD
+
+when the OnScreenDisplay type is set, set it on the plasma shell surface
+so KWin can actually treat it as such
+
+CCBUG:428859
+---
+ src/plasmaquick/dialog.cpp | 7 +++++++
+ 1 file changed, 7 insertions(+)
+
+diff --git a/src/plasmaquick/dialog.cpp b/src/plasmaquick/dialog.cpp
+index 4cea3a28e..3254b8320 100644
+--- a/src/plasmaquick/dialog.cpp
++++ b/src/plasmaquick/dialog.cpp
+@@ -736,6 +736,13 @@ void DialogPrivate::applyType()
+         if (!wmType) {
+             KWindowSystem::setType(q->winId(), static_cast<NET::WindowType>(type));
+         }
++#if HAVE_KWAYLAND
++        if (type == Dialog::OnScreenDisplay) {
++            if (shellSurface) {
++                shellSurface->setRole(KWayland::Client::PlasmaShellSurface::Role::OnScreenDisplay);
++            }
++        }
++#endif
+     } else {
+         q->setFlags(Qt::FramelessWindowHint | q->flags());
+ 
+-- 
+GitLab
+

diff --git a/kde-frameworks/plasma/plasma-5.88.0-r1.ebuild b/kde-frameworks/plasma/plasma-5.88.0-r1.ebuild
new file mode 100644
index 000000000000..5a0e6848003e
--- /dev/null
+++ b/kde-frameworks/plasma/plasma-5.88.0-r1.ebuild
@@ -0,0 +1,79 @@
+# Copyright 1999-2021 Gentoo Authors
+# Distributed under the terms of the GNU General Public License v2
+
+EAPI=8
+
+KDE_ORG_NAME="${PN}-framework"
+PVCUT=$(ver_cut 1-2)
+QTMIN=5.15.2
+VIRTUALX_REQUIRED="test"
+inherit ecm kde.org
+
+DESCRIPTION="Plasma framework"
+
+LICENSE="LGPL-2+"
+KEYWORDS="~amd64 ~arm ~arm64 ~ppc64 ~riscv ~x86"
+IUSE="gles2-only man wayland X"
+
+RESTRICT="test"
+
+RDEPEND="
+	>=dev-qt/qtdbus-${QTMIN}:5
+	>=dev-qt/qtdeclarative-${QTMIN}:5
+	>=dev-qt/qtgui-${QTMIN}:5[gles2-only=,X=]
+	>=dev-qt/qtquickcontrols-${QTMIN}:5
+	>=dev-qt/qtsql-${QTMIN}:5
+	>=dev-qt/qtsvg-${QTMIN}:5
+	>=dev-qt/qtwidgets-${QTMIN}:5
+	=kde-frameworks/kactivities-${PVCUT}*:5
+	=kde-frameworks/karchive-${PVCUT}*:5
+	=kde-frameworks/kconfig-${PVCUT}*:5
+	=kde-frameworks/kconfigwidgets-${PVCUT}*:5
+	=kde-frameworks/kcoreaddons-${PVCUT}*:5
+	=kde-frameworks/kdeclarative-${PVCUT}*:5
+	=kde-frameworks/kglobalaccel-${PVCUT}*:5
+	=kde-frameworks/kguiaddons-${PVCUT}*:5
+	=kde-frameworks/ki18n-${PVCUT}*:5
+	=kde-frameworks/kiconthemes-${PVCUT}*:5
+	=kde-frameworks/kio-${PVCUT}*:5
+	=kde-frameworks/kirigami-${PVCUT}*:5
+	=kde-frameworks/knotifications-${PVCUT}*:5
+	=kde-frameworks/kpackage-${PVCUT}*:5
+	=kde-frameworks/kservice-${PVCUT}*:5
+	=kde-frameworks/kwidgetsaddons-${PVCUT}*:5
+	=kde-frameworks/kwindowsystem-${PVCUT}*:5
+	=kde-frameworks/kxmlgui-${PVCUT}*:5
+	!gles2-only? ( media-libs/libglvnd[X?] )
+	wayland? (
+		=kde-frameworks/kwayland-${PVCUT}*:5
+		media-libs/libglvnd
+	)
+	X? (
+		>=dev-qt/qtx11extras-${QTMIN}:5
+		x11-libs/libX11
+		x11-libs/libxcb
+	)
+"
+DEPEND="${RDEPEND}
+	X? ( x11-base/xorg-proto )
+"
+BDEPEND="man? ( >=kde-frameworks/kdoctools-${PVCUT}:5 )"
+
+PATCHES=(
+	"${FILESDIR}"/${P}-make-OSD-an-actual-wayland-OSD.patch
+	"${FILESDIR}"/${P}-fix-misrenderings-with-transparency.patch # KDE-bug 305247
+	"${FILESDIR}"/${P}-fix-centered-text.patch # KDE-bug 442830
+)
+
+src_configure() {
+	local mycmakeargs=(
+		$(cmake_use_find_package !gles2-only OpenGL)
+		$(cmake_use_find_package man KF5DocTools)
+		$(cmake_use_find_package wayland EGL)
+		$(cmake_use_find_package wayland KF5Wayland)
+		$(cmake_use_find_package X X11)
+		$(cmake_use_find_package X XCB)
+	)
+
+	ecm_src_configure
+}


             reply	other threads:[~2021-11-23 14:59 UTC|newest]

Thread overview: 24+ messages / expand[flat|nested]  mbox.gz  Atom feed  top
2021-11-23 14:59 Andreas Sturmlechner [this message]
  -- strict thread matches above, loose matches on Subject: below --
2023-02-01 19:46 [gentoo-commits] repo/gentoo:master commit in: kde-frameworks/plasma/, kde-frameworks/plasma/files/ Andreas Sturmlechner
2023-01-29  0:12 Andreas Sturmlechner
2022-11-27 11:20 Andreas Sturmlechner
2022-08-06  7:44 Andreas Sturmlechner
2022-07-26 12:08 Andreas Sturmlechner
2022-06-14 12:44 Andreas Sturmlechner
2022-04-21  8:56 Andreas Sturmlechner
2022-04-15 18:27 Andreas Sturmlechner
2022-03-30 14:41 Andreas Sturmlechner
2022-02-10  9:13 Andreas Sturmlechner
2021-12-08 15:08 Andreas Sturmlechner
2021-10-11 11:01 Andreas Sturmlechner
2021-09-30 17:24 Andreas Sturmlechner
2021-08-26 17:28 Andreas Sturmlechner
2021-08-15 18:57 Andreas Sturmlechner
2021-08-15 18:57 Andreas Sturmlechner
2021-01-11 12:28 Andreas Sturmlechner
2020-11-16 23:41 Andreas Sturmlechner
2020-10-26 19:06 Andreas Sturmlechner
2020-04-17 20:59 Andreas Sturmlechner
2020-02-13 23:20 Andreas Sturmlechner
2019-03-13 11:05 Andreas Sturmlechner
2017-04-15 20:31 Andreas Sturmlechner

Reply instructions:

You may reply publicly to this message via plain-text email
using any one of the following methods:

* Save the following mbox file, import it into your mail client,
  and reply-to-all from there: mbox

  Avoid top-posting and favor interleaved quoting:
  https://en.wikipedia.org/wiki/Posting_style#Interleaved_style

* Reply using the --to, --cc, and --in-reply-to
  switches of git-send-email(1):

  git send-email \
    --in-reply-to=1637679551.6cd2d37aef9a8974b31772a99496f0905e25c64b.asturm@gentoo \
    --to=asturm@gentoo.org \
    --cc=gentoo-commits@lists.gentoo.org \
    --cc=gentoo-dev@lists.gentoo.org \
    /path/to/YOUR_REPLY

  https://kernel.org/pub/software/scm/git/docs/git-send-email.html

* If your mail client supports setting the In-Reply-To header
  via mailto: links, try the mailto: link
Be sure your reply has a Subject: header at the top and a blank line before the message body.
This is a public inbox, see mirroring instructions
for how to clone and mirror all data and code used for this inbox