Bug 412829 - KMessageWidget: Wrong vertical size after show animation with word-wrap enabled
Summary: KMessageWidget: Wrong vertical size after show animation with word-wrap enabled
Status: CONFIRMED
Alias: None
Product: frameworks-kwidgetsaddons
Classification: Frameworks and Libraries
Component: general (show other bugs)
Version: 5.62.0
Platform: Arch Linux Linux
: NOR normal
Target Milestone: ---
Assignee: Christoph Feck
URL:
Keywords:
Depends on:
Blocks:
 
Reported: 2019-10-10 19:53 UTC by Juraj
Modified: 2022-10-03 12:29 UTC (History)
2 users (show)

See Also:
Latest Commit:
Version Fixed In:


Attachments
Video recording of the mentioned behaviour. (1.02 MB, video/x-matroska)
2019-10-10 19:53 UTC, Juraj
Details

Note You need to log in before you can comment on or make changes to this bug.
Description Juraj 2019-10-10 19:53:57 UTC
Created attachment 123137 [details]
Video recording of the mentioned behaviour.

SUMMARY
The message widget resizes wrongly after animation with word-wrap enabled.

STEPS TO REPRODUCE
1. Enable word-wrap
2. set text to something which will be wrapped with default size, let it resize (or qt resize ?)
3. observe

OBSERVED RESULT
- The widget picked the initial size (width and height) while the toolview size was not determined and started animation with these values. Small width and big height in this case.
- After animation finished the coloured message box was resized to match the size of the toolview. It matched the width and adjusted its height as needed.
- After it finished it left the black vertical space between its own coloured message box and other elements in layout.
- When the massage box is closed by clicking on the big X, the message box is gone and the excess space is also removed, when the message box shows next it picks the current size of the toolview.

EXPECTED RESULT
The widget properly takes care of the required space and adjust accordingly without leaving blank space.

SOFTWARE/OS VERSIONS
Operating System: Artix Linux 
KDE Plasma Version: 5.16.5
KDE Frameworks Version: 5.62.0
Qt Version: 5.13.1
Kernel Version: 4.19.74-1-lts
OS Type: 64-bit


ADDITIONAL INFORMATION
I found this during tweaking KDevelop`s plugin fileteplates and its TemplatePreviewToolview.
The bug appears when the toolview "Template Preview" is added to some dock, if word-wrap is enabled.

The required changes to KDevelop to reproduce the bug can be found in KDE GitLab.
https://invent.kde.org/kde/kdevelop/merge_requests/68
Comment 1 Juraj 2020-01-18 13:19:51 UTC
Hello, me again.

I created small application just to replicate this bug.
It can be found at:
https://invent.kde.org/jurajo/bug-412829-test-app