Hello community, here is the log from the commit of package qqc2-desktop-style for openSUSE:Factory checked in at 2019-03-22 15:07:07 ++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++ Comparing /work/SRC/openSUSE:Factory/qqc2-desktop-style (Old) and /work/SRC/openSUSE:Factory/.qqc2-desktop-style.new.25356 (New) ++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++
Package is "qqc2-desktop-style" Fri Mar 22 15:07:07 2019 rev:20 rq:686782 version:5.56.0 Changes: -------- --- /work/SRC/openSUSE:Factory/qqc2-desktop-style/qqc2-desktop-style.changes 2019-02-25 17:57:24.722287322 +0100 +++ /work/SRC/openSUSE:Factory/.qqc2-desktop-style.new.25356/qqc2-desktop-style.changes 2019-03-22 15:07:33.317484773 +0100 @@ -1,0 +2,16 @@ +Sun Mar 10 20:15:38 UTC 2019 - [email protected] + +- Update to 5.56.0 + * New feature release + * For more details please see: + * https://www.kde.org/announcements/kde-frameworks-5.56.0.php +- Changes since 5.55.0: + * Use PointingHand when hovering links in Label + * Respect the display property of buttons + * clicking on empty areas behaves like pgup/pgdown (kde#402578) + * Support icon on ComboBox + * support text positioning api + * Support icons from local files in buttons + * Use the correct cursor when hovering over the editable part of a spinbox + +------------------------------------------------------------------- Old: ---- qqc2-desktop-style-5.55.0.tar.xz New: ---- qqc2-desktop-style-5.56.0.tar.xz ++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++ Other differences: ------------------ ++++++ qqc2-desktop-style.spec ++++++ --- /var/tmp/diff_new_pack.Khq16X/_old 2019-03-22 15:07:35.037483285 +0100 +++ /var/tmp/diff_new_pack.Khq16X/_new 2019-03-22 15:07:35.045483278 +0100 @@ -16,9 +16,9 @@ # -%define _tar_path 5.55 +%define _tar_path 5.56 Name: qqc2-desktop-style -Version: 5.55.0 +Version: 5.56.0 Release: 0 Summary: A Qt Quick Controls 2 Style for Desktop UIs License: GPL-2.0-or-later ++++++ qqc2-desktop-style-5.55.0.tar.xz -> qqc2-desktop-style-5.56.0.tar.xz ++++++ diff -urN '--exclude=CVS' '--exclude=.cvsignore' '--exclude=.svn' '--exclude=.svnignore' old/qqc2-desktop-style-5.55.0/CMakeLists.txt new/qqc2-desktop-style-5.56.0/CMakeLists.txt --- old/qqc2-desktop-style-5.55.0/CMakeLists.txt 2019-02-02 18:25:15.000000000 +0100 +++ new/qqc2-desktop-style-5.56.0/CMakeLists.txt 2019-03-02 14:31:26.000000000 +0100 @@ -1,7 +1,7 @@ cmake_minimum_required(VERSION 3.5) -set(KF5_VERSION "5.55.0") # handled by release scripts -set(KF5_DEP_VERSION "5.55.0") # handled by release scripts +set(KF5_VERSION "5.56.0") # handled by release scripts +set(KF5_DEP_VERSION "5.56.0") # handled by release scripts project(qqc2-desktop-style VERSION ${KF5_VERSION}) @@ -21,7 +21,7 @@ ################# set KDE specific information ################# -find_package(ECM 5.55.0 REQUIRED NO_MODULE) +find_package(ECM 5.56.0 REQUIRED NO_MODULE) # where to look first for cmake modules, before ${CMAKE_ROOT}/Modules/ is checked set(CMAKE_MODULE_PATH ${CMAKE_MODULE_PATH} ${ECM_MODULE_PATH} ${ECM_KDE_MODULE_DIR}) diff -urN '--exclude=CVS' '--exclude=.cvsignore' '--exclude=.svn' '--exclude=.svnignore' old/qqc2-desktop-style-5.55.0/kirigami-plasmadesktop-integration/plasmadesktoptheme.cpp new/qqc2-desktop-style-5.56.0/kirigami-plasmadesktop-integration/plasmadesktoptheme.cpp --- old/qqc2-desktop-style-5.55.0/kirigami-plasmadesktop-integration/plasmadesktoptheme.cpp 2019-02-02 18:25:15.000000000 +0100 +++ new/qqc2-desktop-style-5.56.0/kirigami-plasmadesktop-integration/plasmadesktoptheme.cpp 2019-03-02 14:31:26.000000000 +0100 @@ -232,6 +232,7 @@ //background setBackgroundColor(colors.scheme.background(KColorScheme::NormalBackground).color()); + setAlternateBackgroundColor(colors.scheme.background(KColorScheme::AlternateBackground).color()); setHighlightColor(colors.selectionScheme.background(KColorScheme::NormalBackground).color()); //decoration diff -urN '--exclude=CVS' '--exclude=.cvsignore' '--exclude=.svn' '--exclude=.svnignore' old/qqc2-desktop-style-5.55.0/org.kde.desktop/Button.qml new/qqc2-desktop-style-5.56.0/org.kde.desktop/Button.qml --- old/qqc2-desktop-style-5.55.0/org.kde.desktop/Button.qml 2019-02-02 18:25:15.000000000 +0100 +++ new/qqc2-desktop-style-5.56.0/org.kde.desktop/Button.qml 2019-03-02 14:31:26.000000000 +0100 @@ -39,7 +39,7 @@ contentItem: Item {} Kirigami.MnemonicData.enabled: controlRoot.enabled && controlRoot.visible Kirigami.MnemonicData.controlType: Kirigami.MnemonicData.ActionElement - Kirigami.MnemonicData.label: controlRoot.text + Kirigami.MnemonicData.label: controlRoot.display !== T.AbstractButton.IconOnly ? controlRoot.text : "" Shortcut { //in case of explicit & the button manages it by itself enabled: !(RegExp(/\&[^\&]/).test(controlRoot.text)) @@ -58,7 +58,7 @@ hasFocus: controlRoot.activeFocus activeControl: controlRoot.isDefault ? "default" : "f" properties: { - "icon": controlRoot.icon ? (controlRoot.icon.name || controlRoot.icon.source) : "", + "icon": controlRoot.icon && controlRoot.display !== T.AbstractButton.TextOnly ? (controlRoot.icon.name || controlRoot.icon.source) : "", "iconColor": controlRoot.icon && controlRoot.icon.color.a > 0? controlRoot.icon.color : Kirigami.Theme.textColor, "iconWidth": controlRoot.icon && controlRoot.icon.width ? controlRoot.icon.width : 0, "iconHeight": controlRoot.icon && controlRoot.icon.height ? controlRoot.icon.height : 0, diff -urN '--exclude=CVS' '--exclude=.cvsignore' '--exclude=.svn' '--exclude=.svnignore' old/qqc2-desktop-style-5.55.0/org.kde.desktop/Label.qml new/qqc2-desktop-style-5.56.0/org.kde.desktop/Label.qml --- old/qqc2-desktop-style-5.55.0/org.kde.desktop/Label.qml 2019-02-02 18:25:15.000000000 +0100 +++ new/qqc2-desktop-style-5.56.0/org.kde.desktop/Label.qml 2019-03-02 14:31:26.000000000 +0100 @@ -37,7 +37,16 @@ // Work around Qt bug where NativeRendering breaks for non-integer scale factors // https://bugreports.qt.io/browse/QTBUG-67007 renderType: Screen.devicePixelRatio % 1 !== 0 ? Text.QtRendering : Text.NativeRendering - + + // Since Text (and Label) lack cursor-changing abilities of their own, + // as suggested by QTBUG-30804, use a MouseAra to do our dirty work. + // See comment https://bugreports.qt.io/browse/QTBUG-30804?#comment-206287 + // TODO: Once HoverHandler and friends are able to change cursor shapes, this will want changing to that method + MouseArea { + anchors.fill: parent + cursorShape: parent.hoveredLink ? Qt.PointingHandCursor : Qt.ArrowCursor + acceptedButtons: Qt.NoButton // Not actually accepting clicks, just changing the cursor + } font.capitalization: Kirigami.Theme.defaultFont.capitalization font.family: Kirigami.Theme.defaultFont.family diff -urN '--exclude=CVS' '--exclude=.cvsignore' '--exclude=.svn' '--exclude=.svnignore' old/qqc2-desktop-style-5.55.0/org.kde.desktop/ScrollBar.qml new/qqc2-desktop-style-5.56.0/org.kde.desktop/ScrollBar.qml --- old/qqc2-desktop-style-5.55.0/org.kde.desktop/ScrollBar.qml 2019-02-02 18:25:15.000000000 +0100 +++ new/qqc2-desktop-style-5.56.0/org.kde.desktop/ScrollBar.qml 2019-03-02 14:31:26.000000000 +0100 @@ -43,10 +43,14 @@ visible: controlRoot.size < 1.0 hoverEnabled: true state: "inactive" - onPositionChanged: style.activeControl = style.hitTest(mouse.x, mouse.y) + acceptedButtons: Qt.LeftButton | Qt.MiddleButton onExited: style.activeControl = "groove"; onPressed: { - if (style.activeControl == "down") { + if (mouse.buttons & Qt.MiddleButton) { + style.activeControl = "handle"; + controlRoot.position = Math.min(1 - controlRoot.size, Math.max(0, mouse.y/(controlRoot.orientation == Qt.Vertical ? height: width) - controlRoot.size/2)); + mouse.accepted = true; + } else if (style.activeControl == "down") { buttonTimer.increment = 1; buttonTimer.running = true; mouse.accepted = true @@ -54,10 +58,26 @@ buttonTimer.increment = -1; buttonTimer.running = true; mouse.accepted = true + } else if (style.activeControl == "downPage") { + buttonTimer.increment = controlRoot.size; + buttonTimer.running = true; + mouse.accepted = true + } else if (style.activeControl == "upPage") { + buttonTimer.increment = -controlRoot.size; + buttonTimer.running = true; + mouse.accepted = true } else { mouse.accepted = false } } + onPositionChanged: { + style.activeControl = style.hitTest(mouse.x, mouse.y) + if (mouse.buttons & Qt.MiddleButton) { + style.activeControl = "handle"; + controlRoot.position = Math.min(1 - controlRoot.size, Math.max(0, mouse.y/(controlRoot.orientation == Qt.Vertical ? height: width) - controlRoot.size/2)); + mouse.accepted = true; + } + } onReleased: { buttonTimer.running = false; mouse.accepted = false @@ -89,11 +109,14 @@ property real increment repeat: true interval: 150 + triggeredOnStart: true onTriggered: { - if (increment > 0) { + if (increment == 1) { controlRoot.increase(); - } else { + } else if (increment == -1) { controlRoot.decrease(); + } else { + controlRoot.position = Math.min(1 - controlRoot.size, Math.max(0, controlRoot.position + increment)); } } } diff -urN '--exclude=CVS' '--exclude=.cvsignore' '--exclude=.svn' '--exclude=.svnignore' old/qqc2-desktop-style-5.55.0/org.kde.desktop/SpinBox.qml new/qqc2-desktop-style-5.56.0/org.kde.desktop/SpinBox.qml --- old/qqc2-desktop-style-5.55.0/org.kde.desktop/SpinBox.qml 2019-02-02 18:25:15.000000000 +0100 +++ new/qqc2-desktop-style-5.56.0/org.kde.desktop/SpinBox.qml 2019-03-02 14:31:26.000000000 +0100 @@ -73,6 +73,9 @@ controlRoot.increase(); } } + // Normally the TextInput does this automatically, but the MouseArea on + // top of it blocks that behavior, so we need to explicitly do it here + cursorShape: Qt.IBeamCursor } } diff -urN '--exclude=CVS' '--exclude=.cvsignore' '--exclude=.svn' '--exclude=.svnignore' old/qqc2-desktop-style-5.55.0/org.kde.desktop/ToolButton.qml new/qqc2-desktop-style-5.56.0/org.kde.desktop/ToolButton.qml --- old/qqc2-desktop-style-5.55.0/org.kde.desktop/ToolButton.qml 2019-02-02 18:25:15.000000000 +0100 +++ new/qqc2-desktop-style-5.56.0/org.kde.desktop/ToolButton.qml 2019-03-02 14:31:26.000000000 +0100 @@ -61,7 +61,15 @@ activeControl: controlRoot.isDefault ? "default" : "f" properties: { "icon": controlRoot.icon ? (controlRoot.icon.name || controlRoot.icon.source) : "", - "iconColor": controlRoot.icon && controlRoot.icon.color.a > 0? controlRoot.icon.color : Kirigami.Theme.textColor + "iconColor": controlRoot.icon && controlRoot.icon.color.a > 0? controlRoot.icon.color : Kirigami.Theme.textColor, + "toolButtonStyle": controlRoot.display == T.ToolButton.IconOnly + ? Qt.ToolButtonIconOnly : + controlRoot.display == T.ToolButton.TextOnly + ? Qt.ToolButtonTextOnly : + controlRoot.display == T.ToolButton.TextBesideIcon + ? Qt.ToolButtonTextBesideIcon : + controlRoot.display == T.ToolButton.TextUnderIcon + ? Qt.ToolButtonTextUnderIcon : Qt.ToolButtonFollowStyle } } } diff -urN '--exclude=CVS' '--exclude=.cvsignore' '--exclude=.svn' '--exclude=.svnignore' old/qqc2-desktop-style-5.55.0/plugin/kquickstyleitem.cpp new/qqc2-desktop-style-5.56.0/plugin/kquickstyleitem.cpp --- old/qqc2-desktop-style-5.55.0/plugin/kquickstyleitem.cpp 2019-02-02 18:25:15.000000000 +0100 +++ new/qqc2-desktop-style-5.56.0/plugin/kquickstyleitem.cpp 2019-03-02 14:31:26.000000000 +0100 @@ -209,6 +209,8 @@ const QVariant icon = m_properties[QStringLiteral("icon")]; if (icon.canConvert<QIcon>()) { opt->icon = icon.value<QIcon>(); + } else if (icon.canConvert<QUrl>() && icon.value<QUrl>().isLocalFile()) { + opt->icon = QIcon(icon.value<QUrl>().toLocalFile()); } else if (icon.canConvert<QString>()) { opt->icon = m_theme->iconFromTheme(icon.value<QString>(), m_properties[QStringLiteral("iconColor")].value<QColor>()); } @@ -335,7 +337,19 @@ opt->features = QStyleOptionToolButton::HasMenu; } - opt->toolButtonStyle = Qt::ToolButtonFollowStyle; + const int toolButtonStyle = m_properties.value(QStringLiteral("toolButtonStyle")).toInt(); + + switch (toolButtonStyle) { + case Qt::ToolButtonIconOnly: + case Qt::ToolButtonTextOnly: + case Qt::ToolButtonTextBesideIcon: + case Qt::ToolButtonTextUnderIcon: + case Qt::ToolButtonFollowStyle: + opt->toolButtonStyle = (Qt::ToolButtonStyle)toolButtonStyle; + break; + default: + opt->toolButtonStyle = Qt::ToolButtonFollowStyle; + } int e = KQuickStyleItem::style()->pixelMetric(QStyle::PM_ToolBarIconSize, m_styleoption, nullptr); opt->iconSize = QSize(e, e); @@ -527,6 +541,24 @@ opt->fontMetrics = QFontMetrics(font); opt->currentText = text(); opt->editable = m_properties[QStringLiteral("editable")].toBool(); + + const QVariant icon = m_properties[QStringLiteral("currentIcon")]; + if (icon.canConvert<QIcon>()) { + opt->currentIcon = icon.value<QIcon>(); + } else if (icon.canConvert<QString>()) { + opt->currentIcon = m_theme->iconFromTheme(icon.value<QString>(), m_properties[QStringLiteral("iconColor")].value<QColor>()); + } + auto iconSize = QSize(m_properties[QStringLiteral("iconWidth")].toInt(), m_properties[QStringLiteral("iconHeight")].toInt()); + if (iconSize.isEmpty()) { + int e = KQuickStyleItem::style()->pixelMetric(QStyle::PM_ButtonIconSize, m_styleoption, nullptr); + if (iconSize.width() <= 0) { + iconSize.setWidth(e); + } + if (iconSize.height() <= 0) { + iconSize.setHeight(e); + } + } + opt->iconSize = iconSize; } break; case SpinBox: {
