Summary: | font rendering in list view broken with no unread feeds | ||
---|---|---|---|
Product: | [Applications] akregator | Reporter: | Andreas Kuhl <mail> |
Component: | general | Assignee: | kdepim bugs <kdepim-bugs> |
Status: | RESOLVED FIXED | ||
Severity: | normal | CC: | jjm, osterfeld |
Priority: | NOR | ||
Version: | unspecified | ||
Target Milestone: | --- | ||
Platform: | Compiled Sources | ||
OS: | Unspecified | ||
Latest Commit: | Version Fixed In: | ||
Attachments: |
Screen shot of problem still remaining
Patch to explicitly specify row height Updated patch to explictly specify row height Screen shot of same problem in KMail |
Description
Andreas Kuhl
2008-12-26 18:25:53 UTC
Analyzing both screenshots side-by-side, I need to substantiate my bug report: The font rendering seems to stay the same, but the line height of each feed entry does not: When there is at least one bold (unread) feed entry, all feed entries have a slightly larger line-height. All lines have the height of the largest font (the bold one). With no bold (unread feeds), the line height of every feed entry decreases. Compare both screenshots side-by-side and you'll understand what I mean! :-) Still a bug, though. Version: KDE 4.2 Beta 2 (4.1.85) from openSUSE 11.1 BuildService RPMs. SVN commit 909046 by osterfeld: don't assume uniform row heights in the feed list (which changes with unread items) BUG: 178821 _M . (directory) M +0 -1 akregator/src/subscriptionlistview.cpp WebSVN link: http://websvn.kde.org/?view=rev&revision=909046 *** Bug 177297 has been marked as a duplicate of this bug. *** SVN commit 911028 by osterfeld: backport: don't assume uniform row heights in the feed list (which changes with unread items) CCBUG: 178821 M +0 -1 subscriptionlistview.cpp WebSVN link: http://websvn.kde.org/?view=rev&revision=911028 Row height changing has now been fixed in trunk, but with the worse of the two possible outcomes - the feed list icons are now squashed together with no space between them. See attached screen shot. Created attachment 30343 [details]
Screen shot of problem still remaining
With no unread feeds, but still with squashed rows
Would the attached patch solve the problem (without being too inefficient?) Created attachment 30344 [details]
Patch to explicitly specify row height
Doesn't your patch break if the font is bigger than the icons? Er, just tried it and it does. Perhaps it needs to check the font height as well, and not return a hint if the font would be bigger than (icon size + margin)? Created attachment 30595 [details]
Updated patch to explictly specify row height
Calculate the row height as the maximum of the icon size and both normal and bold font variants.
Surely there must be an easier way of specifying a fixed row spacing in a simple tree view...
This behaviour does not happen in KMail, so maybe we should have a look at how it's done over there. Created attachment 30635 [details] Screen shot of same problem in KMail Regarding comment #13: KMail does seem to have partly the same problem. The row height does not change as new messages come and go, because they also have setUniformRowHeights(false) as the Akgregator commit in comment #3 removed. However, the rows do run together (no space between them) as this screenshot shows - it's just that the standard "folder" icons in KMail have a top and bottom margin so the effect is not so obvious. Patch in comment #12 submitted as http://reviewboard.kde.org/r/668/ SVN commit 964725 by marten: Add some line spacing between Akregator's feed list rows, so that the site favicons do not run into each other. Particularly noticeable in this application, because many sites' favicons are square with no margin. Do this via an item delegate (SubscriptionListDelegate) so that the model need not concern itself with the intended list appearance. To follow this principle, also move the unread articles => bold font setting to the delegate. Add a new data role HasUnreadRole so that the delegate can fetch this information from the model. BUG:178821 M +1 -0 CMakeLists.txt A subscriptionlistdelegate.cpp [License: GPL (v2+) (+Qt exception)] A subscriptionlistdelegate.h [License: GPL (v2+) (+Qt exception)] M +4 -8 subscriptionlistmodel.cpp M +2 -1 subscriptionlistmodel.h M +3 -0 subscriptionlistview.cpp WebSVN link: http://websvn.kde.org/?view=rev&revision=964725 |