문제

After a bit of research I wasn't really able to understand why this happens.

In a nutshell, I'm calling QWebView and feeding a .swf into it and it works. However it goes out of its frame/layout, and I'm not sure why.

For a representation, see: enter image description here

As you may see, the dark greyish rectangle is where QWebView was placed, however the .swf going into it is represented out of it in the top left corner.

How to recreate this problem:

I literally just placed a QWebView using the designer, added all the includes needed etc. and added 3 lines of code to mainwindow.cpp :

    QWebSettings *settings = ui->webView->settings();
    settings->setAttribute(QWebSettings::PluginsEnabled, true);
    ui->webView->load(QUrl("http://www.w3schools.com/html/bookmark.swf"));

I also tried opening an html file with the .swf wrapped in it, but the same problem occurs.

Am I doing something wrong? Is it a known bug? Thanks in advance.

도움이 되었습니까?

해결책

Apparently this is a known bug with Qt, will be fixed next release.

Source: https://bugreports.qt-project.org/browse/QTBUG-33053

What I did to fix was basically compile QT again with the fix included.

라이센스 : CC-BY-SA ~와 함께 속성
제휴하지 않습니다 StackOverflow
scroll top