Bug 487533 - Notifications are sometimes shrinked on Plasma 6.1 Beta
Summary: Notifications are sometimes shrinked on Plasma 6.1 Beta
Status: RESOLVED FIXED
Alias: None
Product: plasmashell
Classification: Plasma
Component: Notifications (other bugs)
Version First Reported In: git-stable-Plasma/6.1
Platform: Arch Linux Linux
: NOR normal
Target Milestone: 1.0
Assignee: Plasma Bugs List
URL:
Keywords: regression
: 487935 490365 491825 (view as bug list)
Depends on:
Blocks:
 
Reported: 2024-05-25 14:34 UTC by smow
Modified: 2024-10-02 09:45 UTC (History)
9 users (show)

See Also:
Latest Commit:
Version Fixed/Implemented In: 6.2.0
Sentry Crash Report:


Attachments
shrinked notification (1) (171.47 KB, image/png)
2024-05-25 14:34 UTC, smow
Details

Note You need to log in before you can comment on or make changes to this bug.
Description smow 2024-05-25 14:34:00 UTC
Created attachment 169815 [details]
shrinked notification (1)

SUMMARY
After upgrading to Plasma 6.0.90 I noticed that notifications are sometimes shrinked or squashed in Notifications tray.

STEPS TO REPRODUCE
1. Start copying some, preferably large, files in Dolphin. It's supposed to take significant amount of time, so that the notification won't disappear right away.
2. When popup notication appears, minimize it to tray.
3. Open notification tray.

OBSERVED RESULT
Notification about copying is shrinked.

EXPECTED RESULT
Notifications are always full-width of the notification tray. Sometimes it sort of "fixes itself".

SOFTWARE/OS VERSIONS
Operating System: Arch Linux 
KDE Plasma Version: 6.0.90
KDE Frameworks Version: 6.2.0
Qt Version: 6.7.1
Kernel Version: 6.9.1-zen1-2-zen (64-bit)
Graphics Platform: Wayland
Graphics Processor: NVIDIA GeForce GTX 1060 6GB/PCIe/SSE2
Comment 1 Akseli Lahtinen 2024-06-04 08:07:15 UTC
Can confirm this happens on Plasma 6.1

1. Have two notifications with image (spectacle screenshots)
2. Remove the newest notification
3. The other notification gets smaller when its changed from group notification to regular one


Operating System: Fedora Linux 40
KDE Plasma Version: 6.1.80
KDE Frameworks Version: 6.4.0
Qt Version: 6.7.1
Kernel Version: 6.8.11-300.fc40.x86_64 (64-bit)
Graphics Platform: Wayland
Processors: 12 × AMD Ryzen 5 3600 6-Core Processor
Memory: 15.5 GiB of RAM
Graphics Processor: AMD Radeon RX 6600
Comment 2 Bug Janitor Service 2024-06-04 10:12:31 UTC
A possibly relevant merge request was started @ https://invent.kde.org/plasma/plasma-workspace/-/merge_requests/4406
Comment 3 Nate Graham 2024-06-04 19:55:39 UTC
*** Bug 487935 has been marked as a duplicate of this bug. ***
Comment 4 Akseli Lahtinen 2024-06-05 10:49:13 UTC
Git commit aa77ae7d752d3b2544448c720030b83233e214df by Akseli Lahtinen.
Committed on 05/06/2024 at 10:49.
Pushed by akselmo into branch 'master'.

notifications/NotificationItem.qml: use implicitWidth only when grouped

Outside of group this will cause the notification to shrink,
but if preferredWidth is  completely removed, inside the group it will
take too much space and make the buttons out of screen.

M  +1    -1    applets/notifications/package/contents/ui/NotificationItem.qml

https://invent.kde.org/plasma/plasma-workspace/-/commit/aa77ae7d752d3b2544448c720030b83233e214df
Comment 5 Akseli Lahtinen 2024-06-05 11:20:58 UTC
Git commit 7a700862f820e6aff958ed7129b62fb2b771ac45 by Akseli Lahtinen.
Committed on 05/06/2024 at 10:57.
Pushed by akselmo into branch 'Plasma/6.1'.

notifications/NotificationItem.qml: use implicitWidth only when grouped

Outside of group this will cause the notification to shrink,
but if preferredWidth is  completely removed, inside the group it will
take too much space and make the buttons out of screen.


(cherry picked from commit aa77ae7d752d3b2544448c720030b83233e214df)

9ebb3009 notifications/NotificationItem.qml: use implicitWidth only when grouped

Co-authored-by: Akseli Lahtinen <akselmo@akselmo.dev>

M  +1    -1    applets/notifications/package/contents/ui/NotificationItem.qml

https://invent.kde.org/plasma/plasma-workspace/-/commit/7a700862f820e6aff958ed7129b62fb2b771ac45
Comment 6 Marco Martin 2024-06-06 10:38:25 UTC
Git commit c25acbad5950e089d4c20684fa8d2b5779bce877 by Marco Martin.
Committed on 06/06/2024 at 10:38.
Pushed by mart into branch 'master'.

Simpler layout switch

instead of messing with the margins to make headingElement overlap
summaryRow, reparent heading to summaryrow when we are in a group
and reparent in headingElement when the notification is single.
headingElement is hidden when in group

### Reason for the change

The previous way was very hacky, this is still not perfect, but much less and required much less manual margin play to correctly layout things

### Test plan

creating a lot of notifications, and go between grouped and not grouped

### Bugs fixed

M  +38   -47   applets/notifications/package/contents/ui/NotificationItem.qml

https://invent.kde.org/plasma/plasma-workspace/-/commit/c25acbad5950e089d4c20684fa8d2b5779bce877
Comment 7 TraceyC 2024-07-20 01:55:18 UTC
Verified fixed in git-master. Changing fixed version to 6.2.0 per Nate
Comment 8 TraceyC 2024-07-20 01:55:30 UTC
*** Bug 490365 has been marked as a duplicate of this bug. ***
Comment 9 Nate Graham 2024-08-20 16:27:52 UTC
*** Bug 491825 has been marked as a duplicate of this bug. ***
Comment 10 Bug Janitor Service 2024-09-30 12:32:49 UTC
A possibly relevant merge request was started @ https://invent.kde.org/plasma/plasma-workspace/-/merge_requests/4770
Comment 11 Marco Martin 2024-10-02 08:38:32 UTC
Git commit f0475b8a2bf76ac9afb346e7fda2ce911d2a69d5 by Marco Martin.
Committed on 02/10/2024 at 08:38.
Pushed by mart into branch 'master'.

applets/notifications: Different workaround for layout bugs

Don't set a preferred width which may cause an infinite resize loop.
Invoking a particular undocumented slot will force the layout
to be reevaluated and all items resized again, making fillWidth
actually work
Related: bug 492540

M  +7    -3    applets/notifications/package/contents/ui/NotificationItem.qml

https://invent.kde.org/plasma/plasma-workspace/-/commit/f0475b8a2bf76ac9afb346e7fda2ce911d2a69d5
Comment 12 Bug Janitor Service 2024-10-02 09:25:06 UTC
A possibly relevant merge request was started @ https://invent.kde.org/plasma/plasma-workspace/-/merge_requests/4776
Comment 13 Marco Martin 2024-10-02 09:45:35 UTC
Git commit 19eba9a220022bc2303ce4b89b929a2f4ca3c603 by Marco Martin.
Committed on 02/10/2024 at 09:24.
Pushed by mart into branch 'Plasma/6.2'.

applets/notifications: Different workaround for layout bugs

Don't set a preferred width which may cause an infinite resize loop.
Invoking a particular undocumented slot will force the layout
to be reevaluated and all items resized again, making fillWidth
actually work
Related: bug 492540


(cherry picked from commit f0475b8a2bf76ac9afb346e7fda2ce911d2a69d5)

05440835 applets/notification: Different workaround for layout bugs

Co-authored-by: Marco Martin <notmart@gmail.com>

M  +7    -3    applets/notifications/package/contents/ui/NotificationItem.qml

https://invent.kde.org/plasma/plasma-workspace/-/commit/19eba9a220022bc2303ce4b89b929a2f4ca3c603