PDA

View Full Version : QToolbox change height of item headers



sedi
30th January 2012, 22:38
Hi,
is it possible to increase the height of the item headers of the QToolBox? I need it for a touch application. The headers to open/collapse the vertical tabs are too small for finger use. I think it might be possible with style sheets but I've read they are deprecated, so I never looked into that concept in Qt.
Any idea?
Thank you very much for your work here.
Sebastian

sedi
31st January 2012, 13:10
No ideas anyone? I am happy to learn Styles if this is what's needed - or to keep on trying to build that functionality from widgets - which is still a bit beyond me, I suppose. But I thought there must be a better way to do it. I am quite new to all this stuff and don't yet know which direction to take, though old enough to know that such a decision (using something that is deprecated as well as trying to re-invent the wheel) might turn against me further down the road.
Perhaps, I've posted this into the wrong section of the forum, is it possible to shift it into a more appropriate section?

KillGabio
31st January 2012, 15:25
Hi, have you tried changing the tab spacing? i ve never used a toolbox but if you cant find the solution try stylesheets, i found this example in the documentation:


QToolBox::tab {
background: qlineargradient(x1: 0, y1: 0, x2: 0, y2: 1,
stop: 0 #E1E1E1, stop: 0.4 #DDDDDD,
stop: 0.5 #D8D8D8, stop: 1.0 #D3D3D3);
border-radius: 5px;
color: darkgray;
}

QToolBox::tab:selected { /* italicize selected tabs */
font: italic;
color: white;
}


anyways i think here is your answer, lol: http://developer.qt.nokia.com/forums/viewthread/2496

greetings

and here if you dont want that the tab`s get smaller when you add more and more: http://developer.qt.nokia.com/forums/viewthread/2305

sedi
1st February 2012, 14:40
Hey, thanks for the answer! I have not yet succeded, but I have some good directions now. Thank you so much!

KillGabio
1st February 2012, 15:39
Always my pleasure ;)