The answer is: don't subclass but use style sheets.![]()
The answer is: don't subclass but use style sheets.![]()
J-P Nurmi
Ok, but I want to do it hard way!!!!!
Qt 5.3 Opensource & Creator 3.1.2
Well, good luck. Take a look at QScrollBar::paintEvent() implementation. It's all done with styles. You might be able to change the background brush with palettes but for custom arrow controls you'll need a custom style. At least if you want to do it the right way (tm).
J-P Nurmi
I used style sheet, but it does not look very good, and also examples in qt documentation don't seem enough. http://doc.trolltech.com/4.4/stylesh...ing-qscrollbar
Do you have any good examples of style sheet applied on QScroolBar?
Thanks.
Do it using a QStyle, it is hard enough.
It's nice to be important but it's more important to be nice.
Reimplement drawComplexControl and watch out for CC_ScrollBar
It's nice to be important but it's more important to be nice.
Bookmarks