Review Request 120147: Add frame arount KTextEditor::View, with proper handling of focus and mouse over, for widget themes that support it
Aleix Pol Gonzalez
aleixpol at kde.org
Thu Sep 11 22:19:38 UTC 2014
-----------------------------------------------------------
This is an automatically generated e-mail. To reply, visit:
https://git.reviewboard.kde.org/r/120147/#review66298
-----------------------------------------------------------
Why is the component responsible for defining how it's going to be visually integrated with the host application?
Do we get to hit the scrollbar if the component doesn't have a margin and it's by the screen's border?
- Aleix Pol Gonzalez
On Sept. 11, 2014, 9:25 p.m., Hugo Pereira Da Costa wrote:
>
> -----------------------------------------------------------
> This is an automatically generated e-mail. To reply, visit:
> https://git.reviewboard.kde.org/r/120147/
> -----------------------------------------------------------
>
> (Updated Sept. 11, 2014, 9:25 p.m.)
>
>
> Review request for KDE Frameworks and Christoph Cullmann.
>
>
> Bugs: 158379
> https://bugs.kde.org/show_bug.cgi?id=158379
>
>
> Repository: ktexteditor
>
>
> Description
> -------
>
> Short description is in title and bug report.
> The idea is to implement sunken frame in KTextEditor::View (kate, kwrite, etc.) with 'native' focus and mouse-over effects for styles that support it.
> This makes KateView look again like QTextEdit
>
> Some changes are needed to the layouting in order to accomodate a frame either around the contents only, or around contents+scrollbar, depending on style hint.
>
> The detail changes are:
> - Use QGridLayout for setting up View layout
> - Added QSpacerItems in order to properly implement frame around edition area.
> - properly account for whether style requires frame around contents only, or around contents + scrollbars
> - Call style primitive (CE_ShapedFrame) in order to render a frame around the said area, with proper mouse-over and focus set.
> - Adjust scrollbar background based on whether frame must be drawn around contents only, or scrollbars+contents
> - Force update of widget and scrollbars on focusIn and focusOut events
>
>
> Diffs
> -----
>
> src/view/kateview.h 624072e
> src/view/kateview.cpp 08b4d28
>
> Diff: https://git.reviewboard.kde.org/r/120147/diff/
>
>
> Testing
> -------
>
> Tested with Breeze, Oxygen, Virtuality, and fusion.
> The first three have focus and mouse-over effect.
> The last one does not, but still, the "correct" frame is rendered, with proper margins.
>
> Tested in Kate, KWrite and KDevelop.
> Screenshots attached with kate.
>
>
> File Attachments
> ----------------
>
> before
> https://git.reviewboard.kde.org/media/uploaded/files/2014/09/11/d8a70e3b-e5ea-4fae-aeee-df073c801d86__kate-old.png
> after (breeze)
> https://git.reviewboard.kde.org/media/uploaded/files/2014/09/11/b9968e2b-9104-4022-ab7d-e89b2ce73116__kate-new-breeze.png
> after (oxygen)
> https://git.reviewboard.kde.org/media/uploaded/files/2014/09/11/1be8a8d2-053d-4002-9d83-ad2afd129042__kate-new-oxygen.png
>
>
> Thanks,
>
> Hugo Pereira Da Costa
>
>
-------------- next part --------------
An HTML attachment was scrubbed...
URL: <http://mail.kde.org/pipermail/kde-frameworks-devel/attachments/20140911/952eaa07/attachment.html>
More information about the Kde-frameworks-devel
mailing list