D11650: Fix alignment of icons in Places panel and Compact view mode
Vlad Zagorodniy
noreply at phabricator.kde.org
Tue Mar 27 16:28:35 BST 2018
zzag added a comment.
In D11650#235016 <https://phabricator.kde.org/D11650#235016>, @ngraham wrote:
> Hmm, I still see a problem with 11pt Noto Sans. Take a look at this blown-up screenshot, and specifically, the Pictures item:
No, it's an issue specific to Noto Sans.. It seems like Noto Sans has "lowered baseline". Maybe, it can be fixed by aligning icons relative to font's mean line.
With other fonts, everything look good. :)
INLINE COMMENTS
> kstandarditemlistwidget.cpp:1027
> + // Derive icon's vertical center from the center of the text frame
> + m_pixmapPos.setY(m_textRect.center().y() - (m_scaledPixmapSize.height() / 2 ));
> }
Please notice, you're doing an integer division. Cast m_scaledPixmapSize.height() to qreal or divide by 2.0.
(it seems like the code above does the same too)
REPOSITORY
R318 Dolphin
REVISION DETAIL
https://phabricator.kde.org/D11650
To: sharvey, #dolphin, ngraham, cfeck
Cc: zzag, elvisangelaccio, #dolphin
-------------- next part --------------
An HTML attachment was scrubbed...
URL: <https://mail.kde.org/mailman/private/kfm-devel/attachments/20180327/840083f6/attachment.htm>
More information about the kfm-devel
mailing list