Review Request 129414: KMessageWidget: fix layout when word-wrap is enabled without actions

Elvis Angelaccio elvis.angelaccio at kde.org
Wed Nov 16 11:48:36 UTC 2016


-----------------------------------------------------------
This is an automatically generated e-mail. To reply, visit:
https://git.reviewboard.kde.org/r/129414/
-----------------------------------------------------------

Review request for KDE Frameworks, KDE Usability and Christoph Feck.


Repository: kwidgetsaddons


Description
-------

If we enable word-wrap on a vanilla KMessageWidget (with no additional tool buttons added), the close button is placed on row number 1 (in the grid layout), resulting in wasted space (see first messagewidget in the screenshots).

This patch places the close button on row number 1 only when we actually have other buttons in the messagewidget. This way we save space in the normal case.


Diffs
-----

  src/kmessagewidget.cpp e8b25f6427534a4991bb1dfe9f820cb651238e18 
  tests/kmessagewidgettest.cpp 441e961ac9b851ccc713ab1713e797bd20389efd 

Diff: https://git.reviewboard.kde.org/r/129414/diff/


Testing
-------

Manual testing in the (expanded) kmessagewidgettest.


File Attachments
----------------

Before: wasted space in the first messagewidget
  https://git.reviewboard.kde.org/media/uploaded/files/2016/11/16/e2fb5bce-e249-44fc-9ece-d49c0cf656e1__Spectacle.E12435.png
After: no wasted space in the first messagewidget
  https://git.reviewboard.kde.org/media/uploaded/files/2016/11/16/09986a2d-f1be-48ad-92f0-87d264873ad9__Spectacle.J13060.png


Thanks,

Elvis Angelaccio

-------------- next part --------------
An HTML attachment was scrubbed...
URL: <http://mail.kde.org/pipermail/kde-frameworks-devel/attachments/20161116/1eedab12/attachment-0001.html>


More information about the Kde-frameworks-devel mailing list