Qpushbutton get size code example
Example: set width qpushbutton
//Use this:
QPushButton* const button = new QPushButton(QString("<"), this);
const QSize BUTTON_SIZE = QSize(22, 22);
button->setMinimumSize(BUTTON_SIZE);
//or:
button->setSize(BUTTON_SIZE);
//or:
button->setMinimumSize(BUTTON_SIZE);