QT不規則なラベル、プッシュボタン

//QPixmap pixmap(":/new/prefix_image/LDH_R.png");
//ui->label_LDH_B->setPixmap(pixmap);
//ui->label_LDH_B->setMask(pixmap.mask());

// QPixmapのpixmapLeft( ":/新/ direction16 /画像/ LUH_B.png");
// UI-> pushButton_LUH-> setStyleSheet(「ボーダー-画像:URL(:/新/ direction16 /画像/ LUH_B.png);」);
// UI-> pushButton_LUH-> setMask(pixmapLeft.mask());

注意:画像の背景を透明にする必要があります

公開された42元の記事 ウォンの賞賛148 ビュー410 000 +

おすすめ

転載: blog.csdn.net/baidu_37503452/article/details/104387151