PDA

View Full Version : Adding some padding to a button



scarleton
12th June 2010, 16:15
The layout:

QHBoxLayout
QLabel
Spacer
QPushButton

The text in the QPushButton is three words and right now there is no padding between the word and the edge of the button. How do I add some padding? I though it was the sizeIncrement, but set to either 10 or 40, it has no effect. Any suggestions?

Sam

Lykurg
12th June 2010, 16:18
Have a look at QWidget::setContentsMargins().