Reputation: 139
I add a QToolBox
to my ui file.
But there is no any option to change alignment!
I want change QToolBox
header text alignment from left to right to right to left.
How can I do it?
Upvotes: 1
Views: 718
Reputation: 18504
Unfortunately, there is no any magic method which change the alignment, but you can use stylesshets. For example:
ui->toolBox->setStyleSheet(" QToolBox::tab {padding-left: 10px;} ");
This code allows you move text of header to right and to left(if you reset this option), but it isn't alignment. Anyways it is better than nothing.
Upvotes: 1