Fix bug #334271 : bad display of Dolphin status bar wdgets when a high DPI resolution is used
Review Request #119701 - Created Aug. 10, 2014 and submitted
Fixes display issues of dolphin statusbar widgets when a high DPI value is used (>= 196 for example).
- remove setFixedHeight to fix vertical alignement
- changes fixed values in setMaximumWidth from 150 to averageCharWidth of m_label * 15
So, the font width now respects the dpi settings because averageCharWidth will get it's value.
But there is still an hardcoded value (15).
Note : QtCurve seemed to be bugged (see screenshots)
set DPI to 196 (System Settings -> Appearance -> Fonts)
look at widgets width in statusbar
Please keep the setFixedHeight for m_spaceInfo and m_progressBar.
You should only remove it for m_zoomSlider, because the zoom slider does add an empty area underneath and so the vertical alignment is incorrect in high dpi environments + we also guarantee that the height of the status bar is always equal or bigger then the zoom slider height (line 110), so it is safe to remove the setMaximumHeight for the zoom slider.
Maybe the qtcurve problem will be fixed with these changes ;)
Thanks for working on this, and thanks everyone for the comments! Looks good to me - I think that you don't have a git account, right? So we'll push the patch for you and close https://bugs.kde.org/show_bug.cgi?id=334271 .
I agree that there is room for further improvements. At least some of them (like eliding the text and providing a tool tip) could be done directly in KCapacityBar though, such that all applications which use that class benefit from them.