도와 주셔서 감사합니다 ~ 일부 qlabel 영역에서 directx (d3d)를 사용하여 비디오를 재생해야하기 때문에 winid() 메서드를 호출하여 레이블 winId를 가져와야합니다. 하지만 난이 작업을 수행 할 때 다른 문제는 ~ 나타나는func set 호출시 qt paintEvent가 트리거되지 않습니다. setWindowFlags (Qt :: FramelessWindowHint); and func winid
전화 updata() 후 실행할 수 없습니다 사용자 정의 버튼의 paintEvent 난() 내가 FramelessWindowHint와 윈도우 flage 설정할 때 anly winid를 호출 할 때 :
등이 그 :
MainWindow::MainWindow(QWidget *parent) :
QMainWindow(parent),
ui(new Ui::MainWindow)
{
ui->setupUi(this);
HWND hwnd = (HWND)(ui->label->winId());// here
setWindowFlags(Qt::FramelessWindowHint);// and here
QString playBackPre = "_playBack";
//do my custom button init; the button will draw an pic when press ?enter or leave
ui->pushButton->setImages(playBackPre, 1);
ui->pushButton_2->setImages("_quanJin", 1);
}
감사합니다, 대단히 감사합니다!
죄송합니다. 나는 분명히 말하지 않습니다. –