I need to customize the drawing for the QSpinBox. I implemented the paintEvent method in my subclass but the base class QSpinBox insists on drawing a small borderless rectangle over part of my drawing. How do I stop this?
I need to customize the drawing for the QSpinBox. I implemented the paintEvent method in my subclass but the base class QSpinBox insists on drawing a small borderless rectangle over part of my drawing. How do I stop this?
Try spinbox>setFrame(false);
Thanks. Tried that but it didn't help. I don't understand why this is happening. The QSpinBox must be creating a child widget that is doing the drawing. Is there some way to intercept paint events going to the children of a widget?
AHA! It was the QSpinBox's QLineEdit object. I just moved the QLineEdit over to the proper location for my custom SpinBox and all is well.
Bookmarks