-
Notifications
You must be signed in to change notification settings - Fork 1
New issue
Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.
By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.
Already on GitHub? Sign in to your account
it can't run under pyqt5? #1
Comments
Hi @dragondjf. I wrote this wrapper to allow the use of WebEngineView inside QML at a time where pyqt5 just didn't support it. I saw something related to it recently on their changelog, but had no time to check. Will try to check it later, probably they are supporting it right now. When I wrote this, I was using PyQt 5.4-snapshot-837edec02d98 and Qt 5.4 beta, it worked at the time (I was doing some tests with maps on QML). You can take a look on the example on this repository too. What is your specific problem? It just doesn't work? Do you have any error message? Can you provide a small piece of code with the problem, and describe what you've done to build it? Hope to get it solved for you, see ya ;) |
it work well, we must run initialize() before we can use WebEngineView, to fix this, I wrote DQuickView like this, so it work nice. or you can use Loader to cotroll WebEngineWrapper initialize fininshed before use WebEngineView. #!/usr/bin/python import sys class DQuickView(QtQuick.QQuickView):
|
Oh, I see. Pretty cool man! As I just needed WebEngineView on the QML side, I had no worries on trying to initialize it direct on python. But your way works, nice! |
I need to use WebEngine rendering to an OpenGL surface, tried compiling this, and it doesn't seem to work (Pyhton 3.x Qt 5.7) @dragondjf - can you provide a more complete example of how you get WebEngineView to work under pyqt5 with qml/QuickView? I can't seem to suss out how to do it from your sample - apologies, I am very new to python! |
Actually, I think I have everything sorted, but any time I try to run the example, I get: Though, 100% the file IS there. QML2_IMPORT_PATH is set properly (changing it causes other issues so I know its being read) any ideas on why it might not be able to see the wrapper code? This is, obviously, on Windows |
Hi, I can't test it with Qt 5.7 right now, but it's working on 5.6.2 (python 2.7 and 3.5, on OSX), and PyQt5.6. Seems there is some problem with PyQt 5.7: https://www.riverbankcomputing.com/pipermail/pyqt/2016-October/038231.html |
Got some info from the PyQt guys that say WebEngine should be sorted out in the next release of PyQt that's due in a few weeks. I suppose I'll just wait it out and see if that really does correct things. Thanks for the response! |
Hello! |
this wrapper work under Qt not for PyQt5, because PyQt5 don't support QtWebEngine , PyQt only support QtWebEngineWidgets. How to fix this?
The text was updated successfully, but these errors were encountered: