QT设置按钮控件透明:
代码:
//设置按钮 背景 前景
this->ui->ShowCvRGB->setStyleSheet(QString("color:rgba(255,255,255,255);background-color:rgba(100,100,100,100)"));
// 第一个 为前景色;第二个 为北京色; 透明度 为a
this->ui->ShowPcdFile->setStyleSheet(QString("color:rgba(255,255,255,255);background-color:rgba(100,100,100,100)"));
this->ui->QwtPlotDraw->setStyleSheet(QString("color:rgba(255,255,255,255);background-color:rgba(0,0,0,0)"));
this->ui->Train->setStyleSheet(QString("color:rgba(255,255,255,255);background-color:rgba(100,100,100,100)"));
this->ui->Classify->setStyleSheet(QString("color:rgba(255,255,255,255);background-color:rgba(100,100,100,100)"));
this->ui->Abnormal->setStyleSheet(QString("color:rgba(255,255,255,255);background-color:rgba(100,100,100,100)"));