Quantcast
Channel: QtWebEngine
Viewing all articles
Browse latest Browse all 13965

QCheckBox, box at the right text at the left, how?

$
0
0
I want instead of qcheckbox: box text qcheckbox: text box. I try this:             auto cb = new QCheckBox(text, this);             cb->setStyleSheet(QStringLiteral(" QCheckBox { text-align: left top; } QCheckBox::indicator { subcontrol-origin: padding; subcontrol-position: right top; }")); Yes, “box” at now placed at the right, but “text” is disappear, Looks like it paint at the right of the box, and becase of box placed at the right of widget, it is not visible. So question, how can I place text at the left of the box, may be without stylesheet usage, if stylesheet is buggy.

Viewing all articles
Browse latest Browse all 13965

Latest Images

Trending Articles



Latest Images