From c4ae37fe532d175b503ee46f9902c6b4e70c0df0 Mon Sep 17 00:00:00 2001 From: Christoph Wolk Date: Thu, 8 May 2025 15:27:47 +0200 Subject: [PATCH] [PATCH] applets/notifications: don't allow horizontal scrolling Notification bodies have their width constrained by the notification and the horizontal scrollbar forced off, but they can still be scrolled with a horizontal wheel, touchpad, or similiar. This is surprising and pointless. Instead explicitly set the contentWidth, which is otherwise ultimately based on the underlying TextEdit (and that's the width it would have on a single line without wrapping). Gbp-Pq: Name upstream_2c27c9db_applets-notifications-don-t-allow-horizontal-scrolling.patch --- .../package/contents/ui/delegates/DelegatePopup.qml | 1 + 1 file changed, 1 insertion(+) diff --git a/applets/notifications/package/contents/ui/delegates/DelegatePopup.qml b/applets/notifications/package/contents/ui/delegates/DelegatePopup.qml index e22a8322..0aee40a5 100644 --- a/applets/notifications/package/contents/ui/delegates/DelegatePopup.qml +++ b/applets/notifications/package/contents/ui/delegates/DelegatePopup.qml @@ -137,6 +137,7 @@ BaseDelegate { PlasmaComponents3.ScrollView { id: scroll anchors.fill: parent + contentWidth: bodyLabel.width // This avoids a binding loop PlasmaComponents3.ScrollBar.vertical.visible: modelInterface.maximumLineCount > 0 && bodyLabel.implicitHeight > parent.Layout.maximumHeight -- 2.30.2