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/files/, kde-frameworks/plasma/
Date: Wed, 29 Jun 2022 19:53:27 +0000 (UTC)	[thread overview]
Message-ID: <1656532396.cffb8d30918d2a9ee78eb63e0cc2603a0feb06c6.asturm@gentoo> (raw)

commit:     cffb8d30918d2a9ee78eb63e0cc2603a0feb06c6
Author:     Andreas Sturmlechner <asturm <AT> gentoo <DOT> org>
AuthorDate: Wed Jun 29 19:32:46 2022 +0000
Commit:     Andreas Sturmlechner <asturm <AT> gentoo <DOT> org>
CommitDate: Wed Jun 29 19:53:16 2022 +0000
URL:        https://gitweb.gentoo.org/repo/gentoo.git/commit/?id=cffb8d30

kde-frameworks/plasma: Units: Fix sizeForLabels double-scaling icons

...with Plasma scaling.

Upstream commit 26ae86dff198fbce05ba3824b89786224b3792a9
KDE-bug: https://bugs.kde.org/show_bug.cgi?id=454131

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

 ...a-5.95.0-fix-sizeForLabels-double-scaling.patch | 38 +++++++++++
 kde-frameworks/plasma/plasma-5.95.0-r4.ebuild      | 78 ++++++++++++++++++++++
 2 files changed, 116 insertions(+)

diff --git a/kde-frameworks/plasma/files/plasma-5.95.0-fix-sizeForLabels-double-scaling.patch b/kde-frameworks/plasma/files/plasma-5.95.0-fix-sizeForLabels-double-scaling.patch
new file mode 100644
index 000000000000..84022d815b55
--- /dev/null
+++ b/kde-frameworks/plasma/files/plasma-5.95.0-fix-sizeForLabels-double-scaling.patch
@@ -0,0 +1,38 @@
+From 26ae86dff198fbce05ba3824b89786224b3792a9 Mon Sep 17 00:00:00 2001
+From: Nate Graham <nate@kde.org>
+Date: Thu, 23 Jun 2022 12:47:32 -0600
+Subject: [PATCH] Units: Fix sizeForLabels double-scaling icons with Plasma
+ scaling
+
+The sizeForLabels unit internally uses roundToIconSize(), giving it a
+value and feeding that into devicePixelIconSize() to take into account
+required icons size differences when using Plasma scaling. But
+roundToIconSize() internally does that automatically! So as a result,
+the size is double-scaled and looks too big. To fix this, we simply have
+to stop using devicePixelIconSize() for this unit.
+
+BUG: 454131
+FIXED-IN: 5.96
+---
+ src/declarativeimports/core/units.cpp | 5 +++--
+ 1 file changed, 3 insertions(+), 2 deletions(-)
+
+diff --git a/src/declarativeimports/core/units.cpp b/src/declarativeimports/core/units.cpp
+index 0cdffcbfd..8d655d11f 100644
+--- a/src/declarativeimports/core/units.cpp
++++ b/src/declarativeimports/core/units.cpp
+@@ -115,8 +115,9 @@ void Units::iconLoaderSettingsChanged()
+     m_iconSizes->insert(QStringLiteral("large"), devicePixelIconSize(KIconLoader::SizeLarge));
+     m_iconSizes->insert(QStringLiteral("huge"), devicePixelIconSize(KIconLoader::SizeHuge));
+     m_iconSizes->insert(QStringLiteral("enormous"), devicePixelIconSize(KIconLoader::SizeEnormous));
+-    // gridUnit is always the font height here
+-    m_iconSizes->insert(QStringLiteral("sizeForLabels"), devicePixelIconSize(roundToIconSize(QFontMetrics(QGuiApplication::font()).height())));
++    // We deliberately don't feed the result into devicePixelIconSize() because
++    // roundToIconSize() already does that internally.
++    m_iconSizes->insert(QStringLiteral("sizeForLabels"), roundToIconSize(QFontMetrics(QGuiApplication::font()).height()));
+ 
+     m_iconSizeHints->insert(QStringLiteral("panel"), devicePixelIconSize(KIconLoader::global()->currentSize(KIconLoader::Panel)));
+     m_iconSizeHints->insert(QStringLiteral("desktop"), devicePixelIconSize(KIconLoader::global()->currentSize(KIconLoader::Desktop)));
+-- 
+GitLab
+

diff --git a/kde-frameworks/plasma/plasma-5.95.0-r4.ebuild b/kde-frameworks/plasma/plasma-5.95.0-r4.ebuild
new file mode 100644
index 000000000000..0eede884b46f
--- /dev/null
+++ b/kde-frameworks/plasma/plasma-5.95.0-r4.ebuild
@@ -0,0 +1,78 @@
+# Copyright 1999-2022 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.3
+VIRTUALX_REQUIRED="test"
+inherit ecm kde.org
+
+DESCRIPTION="Plasma framework"
+
+LICENSE="LGPL-2+"
+KEYWORDS="~amd64 ~arm ~arm64 ~loong ~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[qml]
+	=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}-revert-QT_FEATURE_foo.patch"
+	"${FILESDIR}/${P}-fix-sizeForLabels-double-scaling.patch"
+)
+
+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:[~2022-06-29 19:53 UTC|newest]

Thread overview: 23+ messages / expand[flat|nested]  mbox.gz  Atom feed  top
2022-06-29 19:53 Andreas Sturmlechner [this message]
  -- strict thread matches above, loose matches on Subject: below --
2023-04-22 16:21 [gentoo-commits] repo/gentoo:master commit in: kde-frameworks/plasma/files/, kde-frameworks/plasma/ Andreas Sturmlechner
2022-12-10 10:47 Andreas Sturmlechner
2022-11-16 19:17 Andreas Sturmlechner
2022-10-10  8:15 Andreas Sturmlechner
2022-09-24  8:53 Andreas Sturmlechner
2022-05-14 11:33 Andreas Sturmlechner
2022-05-04 20:50 Andreas Sturmlechner
2022-04-09 16:07 Andreas Sturmlechner
2022-01-20 13:26 Andreas Sturmlechner
2021-12-15 11:28 Andreas Sturmlechner
2021-12-08 15:08 Andreas Sturmlechner
2021-09-04 21:01 Andreas Sturmlechner
2021-09-04 21:01 Andreas Sturmlechner
2020-09-29 12:49 Andreas Sturmlechner
2020-06-23 13:49 Andreas Sturmlechner
2020-06-23 13:49 Andreas Sturmlechner
2020-02-13 21:28 Andreas Sturmlechner
2019-12-31 20:09 Andreas Sturmlechner
2019-03-13 10:18 Andreas Sturmlechner
2017-03-13 21:00 Andreas Sturmlechner
2016-11-17 11:35 Michael Palimaka
2016-02-17 11:13 Michael Palimaka

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=1656532396.cffb8d30918d2a9ee78eb63e0cc2603a0feb06c6.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