View Full Version : MacOS and QToolBar?

15th September 2008, 12:24

I have a issue while using QToolBar on my Mac, I'm using the


command to get the QToolBar to look like the normal Mac Toolbars, but it never comes out the way it is normaly on the Mac, the QToolBar is always a bit too big, anyone seen this issue before?
It looks like there is a extra margin below the text.
Any suggestions on how to shrink the QToolBar down to the standard Mac size?

Thanks for any help.

16th September 2008, 07:58

Maybe setting the icon size will help.

setIconSize ( const QSize & iconSize )

16th September 2008, 08:03

I tried that, the whole size of the toolbar gets smaller, but then it looks really strange, because the empty margin around the text is still really big and the icon is quite small, looks even more strange.

What I have been trying now is to skip the QToolButton and create my own QWidget with a QLabel below, because then you can change the margin of the QLabel and get it sort of right, but I need to create my own Button widget that behaves the same way Mac does with the buttons, it's a lot of code to do all that sadly.

21st May 2009, 21:47
I have similar problem with Qt 4.5.

Any idea ?

26th May 2009, 07:45
No, I haven't sadly found a way to get around this problem.