hyperspyUI
hyperspyUI copied to clipboard
QDockWidgets Titlebar have giant toolbars on Mac
The Titlebar of the docked windows in the UI are very vertically wide on Mac. On Linux and Windows they look great.
Undocked they look like this:

Could you try the style edit PR ( #133 ), and enter the following in the style editor:
QDockWidget::title {
padding: 0px; /* try varying this number */
}
The padding can also be 0px 5px for different padding horz/vert or 4 values for left/right/top/bottom (not sure about order).
See comments to #133
QDockWidget::title {
padding: 10px; /* try varying this number */
}
is the minimum padding size I can specify. Will try to play max/min.
padding: 20 works, without the px ending.
Padding seems to be dependent only on the first number, see example and comment below:
QDockWidget::title {
padding: 10px 20px 30px 40px; /* All just 10*/
}
Edit:
On further testing, only padding-top has any effect, so it seems like all other paddings are "turned off". Negative values have no effect.
Does the other paddings work if you replace the icons?
Will try tonight.
Minimum example that is "acceptable" on my Mac:
QDockWidget::close-button, QDockWidget::float-button {
icon-size: 15px;
padding: 1px;
}
Just to show, I can make it a lot more sexy for Mac as well:

Making the button image change on hover is difficult (probably a bug), but there is a workaround: http://stackoverflow.com/questions/32145080/qdockwidget-float-close-button-hover-images