Script 'mail_helper' called by obssrc Hello community, here is the log from the commit of package breeze for openSUSE:Factory checked in at 2023-03-17 17:01:58 ++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++ Comparing /work/SRC/openSUSE:Factory/breeze (Old) and /work/SRC/openSUSE:Factory/.breeze.new.31432 (New) ++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++
Package is "breeze" Fri Mar 17 17:01:58 2023 rev:156 rq:1072484 version:5.27.3 Changes: -------- --- /work/SRC/openSUSE:Factory/breeze/breeze.changes 2023-03-02 23:02:13.838818766 +0100 +++ /work/SRC/openSUSE:Factory/.breeze.new.31432/breeze.changes 2023-03-17 17:02:20.429076211 +0100 @@ -1,0 +2,18 @@ +Thu Mar 16 20:52:25 UTC 2023 - Fabian Vogt <fab...@ritter-vogt.de> + +- Add patches to make the window outline configurable (kde#465948): + * 0001-Outline-intensity-setting.patch + * 0002-Undo-some-string-changes-from-the-preceding-commit.patch + +------------------------------------------------------------------- +Tue Mar 14 15:05:46 UTC 2023 - Fabian Vogt <fab...@ritter-vogt.de> + +- Update to 5.27.3 + * New bugfix release + * For more details please see: + * https://kde.org/announcements/plasma/5/5.27.3 +- Changes since 5.27.2: + * Setting height before adding margins + * Calling expandSize in flat comboboxes too + +------------------------------------------------------------------- Old: ---- breeze-5.27.2.tar.xz breeze-5.27.2.tar.xz.sig New: ---- 0001-Outline-intensity-setting.patch 0002-Undo-some-string-changes-from-the-preceding-commit.patch breeze-5.27.3.tar.xz breeze-5.27.3.tar.xz.sig ++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++ Other differences: ------------------ ++++++ breeze.spec ++++++ --- /var/tmp/diff_new_pack.Jufiv4/_old 2023-03-17 17:02:22.665087927 +0100 +++ /var/tmp/diff_new_pack.Jufiv4/_new 2023-03-17 17:02:22.669087948 +0100 @@ -22,7 +22,7 @@ %{!?_plasma5_version: %define _plasma5_version %(echo %{_plasma5_bugfix} | awk -F. '{print $1"."$2}')} %bcond_without released Name: breeze -Version: 5.27.2 +Version: 5.27.3 Release: 0 Summary: Plasma Desktop artwork, styles and assets License: GPL-2.0-or-later @@ -33,6 +33,10 @@ Source1: https://download.kde.org/stable/plasma/%{version}/breeze-%{version}.tar.xz.sig Source2: plasma.keyring %endif +# PATCH-FEATURE-UPSTREAM +Patch100: 0001-Outline-intensity-setting.patch +# PATCH-FIX-OPENSUSE for ^ +Patch101: 0002-Undo-some-string-changes-from-the-preceding-commit.patch BuildRequires: cmake >= 3.16 BuildRequires: extra-cmake-modules >= 5.98.0 BuildRequires: fdupes ++++++ 0001-Outline-intensity-setting.patch ++++++ >From edc3b64ac4ff06a2213e2a34a78b75287295387b Mon Sep 17 00:00:00 2001 From: Akseli Lahtinen <akse...@akselmo.dev> Date: Fri, 3 Mar 2023 20:51:47 +0000 Subject: [PATCH 1/2] Outline intensity setting This MR adds a tiny outline intensity combobox to Breeze settings in the Shadow tab. I chose shadow tab since the outline is drawn in the shadow drawcall, so maybe this will help people realise it's not part of the borders. BUG: 465948 FIXED-IN: 6.0 --- Here's examples with default breeze dark theme Off  Low  Medium  High  Maximum  Currently the effect only appears after pressing OK. This is same with all the Breeze window decoration settings afaik. _Also, dont mind the settings window having same outline at the same time in the images: I'm not using the dev environment so it doesnt affect anything outside of the preview image. In dev env it changes everywhere._ (cherry picked from commit 9b93fb968ed6a2817cee367aab5cfef7003b4073) --- kdecoration/breezedecoration.cpp | 82 ++++++++++++------- kdecoration/breezesettingsdata.kcfg | 10 +++ kdecoration/config/breezeconfigwidget.cpp | 12 +++ .../config/ui/breezeconfigurationui.ui | 52 ++++++++++-- 4 files changed, 121 insertions(+), 35 deletions(-) diff --git a/kdecoration/breezedecoration.cpp b/kdecoration/breezedecoration.cpp index cc5bb75d..410943f2 100644 --- a/kdecoration/breezedecoration.cpp +++ b/kdecoration/breezedecoration.cpp @@ -111,6 +111,25 @@ inline CompositeShadowParams lookupShadowParams(int size) return s_shadowParams[3]; } } + +inline int lookupOutlineIntensity(int intensity) +{ + switch (intensity) { + case Breeze::InternalSettings::OutlineOff: + return 100; + case Breeze::InternalSettings::OutlineLow: + return 130; + case Breeze::InternalSettings::OutlineMedium: + return 170; + case Breeze::InternalSettings::OutlineHigh: + return 210; + case Breeze::InternalSettings::OutlineMaximum: + return 250; + default: + // Fallback to the Medium intensity. + return 170; + } +} } namespace Breeze @@ -743,7 +762,8 @@ void Decoration::updateShadow() outlineColor.hslSaturationF(), qBound(0.1, outlineColor.lightnessF(), 1.0), s->isAlphaChannelSupported() ? 0.9 : 1.0); - outlineColor.lightnessF() >= 0.5 ? outlineColor = outlineColor.darker(170) : outlineColor = outlineColor.lighter(170); + outlineColor.lightnessF() >= 0.5 ? outlineColor = outlineColor.darker(lookupOutlineIntensity(m_internalSettings->outlineIntensity())) + : outlineColor = outlineColor.lighter(lookupOutlineIntensity(m_internalSettings->outlineIntensity())); // Animated case, no cached shadow object if ((m_shadowAnimation->state() == QAbstractAnimation::Running) && (m_shadowOpacity != 0.0) && (m_shadowOpacity != 1.0)) { @@ -821,36 +841,38 @@ QSharedPointer<KDecoration2::DecorationShadow> Decoration::createShadowObject(co painter.drawRoundedRect(innerRect, m_scaledCornerRadius + 0.5, m_scaledCornerRadius + 0.5); // Draw window outline - const qreal outlineWidth = 1.001; - const qreal penOffset = outlineWidth / 2; - - QRectF outlineRect = innerRect + QMarginsF(penOffset, penOffset, penOffset, penOffset); - qreal cornerSize = m_scaledCornerRadius * 2; - QRectF cornerRect(outlineRect.x(), outlineRect.y(), cornerSize, cornerSize); - QPainterPath outlinePath; - - outlinePath.arcMoveTo(cornerRect, 180); - outlinePath.arcTo(cornerRect, 180, -90); - cornerRect.moveTopRight(outlineRect.topRight()); - outlinePath.arcTo(cornerRect, 90, -90); - - // Check if border size is "no borders" or "no side-borders" - if (borderSize(true) == 0) { - outlinePath.lineTo(outlineRect.bottomRight()); - outlinePath.lineTo(outlineRect.bottomLeft()); - } else { - cornerRect.moveBottomRight(outlineRect.bottomRight()); - outlinePath.arcTo(cornerRect, 0, -90); - cornerRect.moveBottomLeft(outlineRect.bottomLeft()); - outlinePath.arcTo(cornerRect, 270, -90); - } - outlinePath.closeSubpath(); + if (lookupOutlineIntensity(m_internalSettings->outlineIntensity()) > 100) { + const qreal outlineWidth = 1.001; + const qreal penOffset = outlineWidth / 2; + + QRectF outlineRect = innerRect + QMarginsF(penOffset, penOffset, penOffset, penOffset); + qreal cornerSize = m_scaledCornerRadius * 2; + QRectF cornerRect(outlineRect.x(), outlineRect.y(), cornerSize, cornerSize); + QPainterPath outlinePath; + + outlinePath.arcMoveTo(cornerRect, 180); + outlinePath.arcTo(cornerRect, 180, -90); + cornerRect.moveTopRight(outlineRect.topRight()); + outlinePath.arcTo(cornerRect, 90, -90); + + // Check if border size is "no borders" or "no side-borders" + if (borderSize(true) == 0) { + outlinePath.lineTo(outlineRect.bottomRight()); + outlinePath.lineTo(outlineRect.bottomLeft()); + } else { + cornerRect.moveBottomRight(outlineRect.bottomRight()); + outlinePath.arcTo(cornerRect, 0, -90); + cornerRect.moveBottomLeft(outlineRect.bottomLeft()); + outlinePath.arcTo(cornerRect, 270, -90); + } + outlinePath.closeSubpath(); - painter.setPen(QPen(outlineColor, outlineWidth)); - painter.setBrush(Qt::NoBrush); - painter.setCompositionMode(QPainter::CompositionMode_Source); - painter.setRenderHint(QPainter::Antialiasing); - painter.drawPath(outlinePath); + painter.setPen(QPen(outlineColor, outlineWidth)); + painter.setBrush(Qt::NoBrush); + painter.setCompositionMode(QPainter::CompositionMode_Source); + painter.setRenderHint(QPainter::Antialiasing); + painter.drawPath(outlinePath); + } painter.end(); diff --git a/kdecoration/breezesettingsdata.kcfg b/kdecoration/breezesettingsdata.kcfg index f57f61fe..559983d7 100644 --- a/kdecoration/breezesettingsdata.kcfg +++ b/kdecoration/breezesettingsdata.kcfg @@ -35,6 +35,16 @@ <default>false</default> </entry> + <entry name="OutlineIntensity" type = "Enum"> + <choices> + <choice name="OutlineOff"/> + <choice name="OutlineLow"/> + <choice name="OutlineMedium"/> + <choice name="OutlineHigh"/> + <choice name="OutlineMaximum"/> + </choices> + <default>OutlineMedium</default> + </entry> </group> <group name="Windeco"> diff --git a/kdecoration/config/breezeconfigwidget.cpp b/kdecoration/config/breezeconfigwidget.cpp index f75e1b3b..d57c0846 100644 --- a/kdecoration/config/breezeconfigwidget.cpp +++ b/kdecoration/config/breezeconfigwidget.cpp @@ -38,6 +38,7 @@ ConfigWidget::ConfigWidget(QWidget *parent, const QVariantList &args) connect(m_ui.shadowSize, SIGNAL(currentIndexChanged(int)), SLOT(updateChanged())); connect(m_ui.shadowStrength, SIGNAL(valueChanged(int)), SLOT(updateChanged())); connect(m_ui.shadowColor, &KColorButton::changed, this, &ConfigWidget::updateChanged); + connect(m_ui.outlineIntensity, SIGNAL(valueChanged(int)), SLOT(updateChanged())); // track exception changes connect(m_ui.exceptions, &ExceptionListWidget::changed, this, &ConfigWidget::updateChanged); @@ -70,6 +71,13 @@ void ConfigWidget::load() m_ui.shadowStrength->setValue(qRound(qreal(m_internalSettings->shadowStrength() * 100) / 255)); m_ui.shadowColor->setColor(m_internalSettings->shadowColor()); + // load outline intensity + if (m_internalSettings->outlineIntensity() <= InternalSettings::OutlineMaximum) { + m_ui.outlineIntensity->setCurrentIndex(m_internalSettings->outlineIntensity()); + } else { + m_ui.outlineIntensity->setCurrentIndex(InternalSettings::OutlineMedium); + } + // load exceptions ExceptionList exceptions; exceptions.readConfig(m_configuration); @@ -94,6 +102,7 @@ void ConfigWidget::save() m_internalSettings->setShadowSize(m_ui.shadowSize->currentIndex()); m_internalSettings->setShadowStrength(qRound(qreal(m_ui.shadowStrength->value() * 255) / 100)); m_internalSettings->setShadowColor(m_ui.shadowColor->color()); + m_internalSettings->setOutlineIntensity(m_ui.outlineIntensity->currentIndex()); // save configuration m_internalSettings->save(); @@ -136,6 +145,7 @@ void ConfigWidget::defaults() m_ui.shadowSize->setCurrentIndex(m_internalSettings->shadowSize()); m_ui.shadowStrength->setValue(qRound(qreal(m_internalSettings->shadowStrength() * 100) / 255)); m_ui.shadowColor->setColor(m_internalSettings->shadowColor()); + m_ui.outlineIntensity->setCurrentIndex(m_internalSettings->outlineIntensity()); } //_______________________________________________ @@ -167,6 +177,8 @@ void ConfigWidget::updateChanged() modified = true; } else if (m_ui.shadowColor->color() != m_internalSettings->shadowColor()) { modified = true; + } else if (m_ui.outlineIntensity->currentIndex() != m_internalSettings->outlineIntensity()) { + modified = true; // exceptions } else if (m_ui.exceptions->isChanged()) { diff --git a/kdecoration/config/ui/breezeconfigurationui.ui b/kdecoration/config/ui/breezeconfigurationui.ui index f29e38c1..a760f7b7 100644 --- a/kdecoration/config/ui/breezeconfigurationui.ui +++ b/kdecoration/config/ui/breezeconfigurationui.ui @@ -193,13 +193,13 @@ </widget> <widget class="QWidget" name="tab_4"> <attribute name="title"> - <string>Shadows</string> + <string>Shadows and Outline</string> </attribute> <layout class="QGridLayout" name="gridLayout"> <item row="0" column="0"> <widget class="QLabel" name="label"> <property name="text"> - <string>Si&ze:</string> + <string>Shadow size:</string> </property> <property name="alignment"> <set>Qt::AlignRight|Qt::AlignTrailing|Qt::AlignVCenter</set> @@ -241,7 +241,7 @@ <item row="1" column="0"> <widget class="QLabel" name="label_2"> <property name="text"> - <string comment="strength of the shadow (from transparent to opaque)">S&trength:</string> + <string comment="strength of the shadow (from transparent to opaque)">Shadow strength:</string> </property> <property name="alignment"> <set>Qt::AlignRight|Qt::AlignTrailing|Qt::AlignVCenter</set> @@ -280,7 +280,7 @@ <item row="2" column="0"> <widget class="QLabel" name="label_5"> <property name="text"> - <string>Color:</string> + <string>Shadow color:</string> </property> <property name="alignment"> <set>Qt::AlignRight|Qt::AlignTrailing|Qt::AlignVCenter</set> @@ -290,7 +290,49 @@ <item row="2" column="1"> <widget class="KColorButton" name="shadowColor"/> </item> - <item row="3" column="0" colspan="3"> + <item row="3" column="0"> + <widget class="QLabel" name="label_6"> + <property name="text"> + <string comment="outline intensity">Outline intensity:</string> + </property> + <property name="alignment"> + <set>Qt::AlignRight|Qt::AlignTrailing|Qt::AlignVCenter</set> + </property> + <property name="buddy"> + <cstring>outlineIntensity</cstring> + </property> + </widget> + </item> + <item row="3" column="1"> + <widget class="QComboBox" name="outlineIntensity"> + <item> + <property name="text"> + <string comment="@item:inlistbox Outline intensity:">Off</string> + </property> + </item> + <item> + <property name="text"> + <string comment="@item:inlistbox Outline intensity:">Low</string> + </property> + </item> + <item> + <property name="text"> + <string comment="@item:inlistbox Outline intensity:">Medium</string> + </property> + </item> + <item> + <property name="text"> + <string comment="@item:inlistbox Outline intensity:">High</string> + </property> + </item> + <item> + <property name="text"> + <string comment="@item:inlistbox Outline intensity:">Maximum</string> + </property> + </item> + </widget> + </item> + <item row="4" column="0" colspan="3"> <spacer name="verticalSpacer_3"> <property name="orientation"> <enum>Qt::Vertical</enum> -- 2.39.2 ++++++ 0002-Undo-some-string-changes-from-the-preceding-commit.patch ++++++ >From 9bdf353d8cbce8d602ce799ab56179861888629f Mon Sep 17 00:00:00 2001 From: Fabian Vogt <fab...@ritter-vogt.de> Date: Thu, 16 Mar 2023 21:43:33 +0100 Subject: [PATCH 2/2] Undo some string changes from the preceding commit To avoid breaking translations, revert some not really necessary string changes. Makes the option a bit harder to find though. --- kdecoration/config/ui/breezeconfigurationui.ui | 8 ++++---- 1 file changed, 4 insertions(+), 4 deletions(-) diff --git a/kdecoration/config/ui/breezeconfigurationui.ui b/kdecoration/config/ui/breezeconfigurationui.ui index a760f7b7..e0283c93 100644 --- a/kdecoration/config/ui/breezeconfigurationui.ui +++ b/kdecoration/config/ui/breezeconfigurationui.ui @@ -193,13 +193,13 @@ </widget> <widget class="QWidget" name="tab_4"> <attribute name="title"> - <string>Shadows and Outline</string> + <string>Shadows</string> </attribute> <layout class="QGridLayout" name="gridLayout"> <item row="0" column="0"> <widget class="QLabel" name="label"> <property name="text"> - <string>Shadow size:</string> + <string>Si&ze:</string> </property> <property name="alignment"> <set>Qt::AlignRight|Qt::AlignTrailing|Qt::AlignVCenter</set> @@ -241,7 +241,7 @@ <item row="1" column="0"> <widget class="QLabel" name="label_2"> <property name="text"> - <string comment="strength of the shadow (from transparent to opaque)">Shadow strength:</string> + <string comment="strength of the shadow (from transparent to opaque)">S&trength:</string> </property> <property name="alignment"> <set>Qt::AlignRight|Qt::AlignTrailing|Qt::AlignVCenter</set> @@ -280,7 +280,7 @@ <item row="2" column="0"> <widget class="QLabel" name="label_5"> <property name="text"> - <string>Shadow color:</string> + <string>Color:</string> </property> <property name="alignment"> <set>Qt::AlignRight|Qt::AlignTrailing|Qt::AlignVCenter</set> -- 2.39.2 ++++++ breeze-5.27.2.tar.xz -> breeze-5.27.3.tar.xz ++++++ /work/SRC/openSUSE:Factory/breeze/breeze-5.27.2.tar.xz /work/SRC/openSUSE:Factory/.breeze.new.31432/breeze-5.27.3.tar.xz differ: char 26, line 1