Solved QLabel and QStatusBar. Problems with Lines
-
I have some Lines i cant explain where they come from. I added 2 QLabels to a QStatusBar and got something like this
The Lines to the left and right of the Text are Seperators, right? i dont know. How can i remove them?
-
Hi,
How are you setting up that status bar ?
-
i have 2 QLabels in my MainWindow and a StatusBar. This is the relevant Code.
QPixmap pixmap(":/icons/img/info.png"); mStatusBarLabel->setPixmap(pixmap); mStatusBarLabel->show(); mStatusBarText->show(); ui->sbStatus->addWidget(mStatusBarLabel); ui->sbStatus->addWidget(mStatusBarText); mStatusBarText->setText(text); ui->sbStatus->setStyleSheet( "QStatusBar {" "background-color: green;" "}");
-
Hi
Its a right side border style that each item in statusbar has.
You can doQStatusBar::item { border: 0px solid red; }
to remove it.
-
@mrjj it worked thanks