如果在代码中比较好设置,但是在QSS中设置感觉无从入手.
------解决方案--------------------
文字靠在图片的旁边很好设置
QPixmap pixmap(":/contentWidget/power");
button->setIcon(pixmap);
button->setIconSize(pixmap.size());
button->setFixedSize(180, 70);
button->setText(tr("power"));

------解决方案--------------------
我直接贴一张图片上去
ui->pushButton_start->setStyleSheet("QPushButton{border-image:url(:/img/res_img/start.png);}"
"QPushButton:hover{border-image:url(:/img/res_img/start-h.png);}"
);