Summary: | wasted space in toolbars | ||
---|---|---|---|
Product: | [Plasma] Oxygen | Reporter: | Roland Leißa <roland.leissa> |
Component: | style | Assignee: | Camilla Boemann <cbo> |
Status: | RESOLVED FIXED | ||
Severity: | normal | CC: | ivo |
Priority: | NOR | ||
Version: | unspecified | ||
Target Milestone: | --- | ||
Platform: | Gentoo Packages | ||
OS: | Linux | ||
Latest Commit: | Version Fixed In: | ||
Sentry Crash Report: | |||
Attachments: |
toolbar mockup
toolbar situation now toolbar margin mockup improved gaps between menubars/toolbars, toolbars/toolbars and toolbars/UI less wasted spaces |
Description
Roland Leißa
2009-01-15 18:44:16 UTC
Could you please provide a mockup? Created attachment 30294 [details]
toolbar mockup
At the left you see the mockup of system settings. On the right you see how it is now.
First of thank you for showing interest in oxygen. The dot have nothing to do with the space. The dots are created depending on how much space there is. not the other way around. And the space is actually decided on purpose. Now that we don't have that many lines we need space to separate the various elements. And actually we use less space in all than many other styles. However I'll talk to Nuno Pinheiro about it again - just to be sure. Ah ok. I would agree that my mockup is perhaps a bit too narrow but the orignal has definitely too much space. After playing around a bit with toolbars this is what I think now: About half the space between toolbars, between the menubar and a toolbar and between the last toolbar and the actual GUI would just be fine. However if you have a look at system settings and -- let's say -- dolphin without menubar with just the toolbar at the top, you'll notice that system settings has a gap between the window decoration and the toolbar what dolphin does not have. Dunno whether this is a oxygen bug. It not that easy - we don't have that fine control we mixing elements all we can do is add margins to individual elements, but we can't speculate on combinations. The current solution actually took quite a long time to compromise Not closing though - we'll take a look at it Note to self: maybe base margin on font size Created attachment 30325 [details]
toolbar situation now
I've upgraded my system today and the extra gap between the window-deco and the toolbar in system settings is gone. System settings looks better like this. Dunno whether a Qt or a KDE update (4.1.3 -> 4.1.4) solved this issue.
@toolbar margins: Have a look at the toolbar situation now (see attachment):
toolbar - toolbar: gap is too large
menubar - toolbar: gap seems even larger
toolbar - gui: gap is slightly too large
Assume we have now a margin of 4 pixels around the toolbars. The first thing I would try is to set the margin to 2 pixels. If the bottom toolbar seems to be too near to the GUI and the menubar is still too far from the toolbar, one could set the top margin to 1 and the bottom margin to 3.
I don't know how hard this is to do. But perhaps you can post some screenshot of different margin settings?
Created attachment 30326 [details]
toolbar margin mockup
Here's a mockup I made. The top margin is reduced by 4 pixels. The bottom margin is reduced by one. I really like this version.
Can it be that there is somehow extra margin set for tabs? You can see this effect in tabbed konqueror, Kopete's tabbed chat window and system settings, for instance. Even reducing this gap by one leaves quite a gap. This would be one thing left from resolving this optimally :)
Where can I find the source code? Perhaps I play with the code a bit by myself. svn.kde.org/home/kde/trunk/KDE/kdebase/runtime/kstyles/oxygen/ Today I played a bit with the code. This is what I've found out: This makes the gap between menubar and toolbar bar a bit better: - setWidgetLayoutProp(WT_MenuBar, MenuBar::Margin + Bot, 2); + setWidgetLayoutProp(WT_MenuBar, MenuBar::Margin + Bot, 0); With this, the gaps between toolbars are better: - setWidgetLayoutProp(WT_ToolButton, ToolButton::ContentsMargin, 4); + setWidgetLayoutProp(WT_ToolButton, ToolButton::ContentsMargin, 0); // perhaps 1, or just the bottum gap 1 + setWidgetLayoutProp(WT_ToolButton, ToolButton::ContentsMargin + Left, 4); + setWidgetLayoutProp(WT_ToolButton, ToolButton::ContentsMargin + Right, 4); However, this looks only nicely, if "Text alongside icon" or "Icons only" is chosen. Chosing Text under icons are causing some artefacts: The heading isn't completly seen. I see two solutions: 1. Make the margin bigger, when this option is set. 2. Somewhere in the depths of KDE or Qt is a bug which doesn't take the heading's size into account. This must be fixed. Created attachment 30766 [details] improved gaps between menubars/toolbars, toolbars/toolbars and toolbars/UI Ok, fixed the issue with text under icons. In the attachment is a patch, which makes some gaps a bit smaller. I really like this version. One thing that still annoys me is the gap which is caused by LineEdits in ToolBars. You can see that the bottom gap is larger than the top one if you drag systemsetting's toolbar away or Konqueror's location bar. I've also sent this patch to bug 17108 but nobody seems to read this anymore. I'll mark that on as a duplicate of this one. Sorry, meant bug 171085 *** Bug 171085 has been marked as a duplicate of this bug. *** Created attachment 30767 [details]
less wasted spaces
This version is even slightly better.
SVN commit 926664 by boemann: Dont wast so much space around toolbars. Thanks to Roland Leißa for the patch. BUG:180852 M +8 -8 oxygen.cpp WebSVN link: http://websvn.kde.org/?view=rev&revision=926664 SVN commit 927610 by boemann: revert a good part of the spacesaving commit CCBUG:180852 instead do someother stuff that does save a little BUG:184542 M +3 -7 oxygen.cpp WebSVN link: http://websvn.kde.org/?view=rev&revision=927610 |