<div dir="ltr">Thank you Florian!<div><br></div><div>- <span style="color:rgb(0,0,0);font-family:arial,sans-serif;font-size:13px">qWebKitVersion is what I need! :)</span></div><div><span style="color:rgb(0,0,0);font-family:arial,sans-serif;font-size:13px">- I was not aware of the Blink switch for Qt 5.4 but I am forced to use what I have now.</span></div><div><span style="color:rgb(0,0,0);font-family:arial,sans-serif;font-size:13px">- I am already using </span><span style="color:rgb(0,0,0);font-family:arial,sans-serif;font-size:13px">QtWebKitWidgets in such a way. I didn't find out the difference between QtWebkit and </span><span style="color:rgb(0,0,0);font-family:arial,sans-serif;font-size:13px">QtWebKitWidgets in the webkit version (the docs talks about webkit1 and webkit2).</span></div><div><span style="color:rgb(0,0,0);font-family:arial,sans-serif;font-size:13px">- well... I didn't know your project. Good to find it! I am currently coding just a little inline browser for a Html5 embedded app. So this is not exactly the case of Qutebrowser.</span></div><div><span style="color:rgb(0,0,0);font-family:arial,sans-serif;font-size:13px"><br></span></div><div><span style="color:rgb(0,0,0);font-family:arial,sans-serif;font-size:13px">Thank you again!</span></div><div><span style="color:rgb(0,0,0);font-family:arial,sans-serif;font-size:13px">Best regards, </span></div></div><div class="gmail_extra"><br clear="all"><div><div dir="ltr">------------------------------------------------------<br> Gianluca Romanin (aka J_Zar)<br>------------------------------------------------------</div></div>
<br><div class="gmail_quote">On Mon, Sep 15, 2014 at 11:03 AM, Florian Bruhin <span dir="ltr"><<a href="mailto:me@the-compiler.org" target="_blank">me@the-compiler.org</a>></span> wrote:<br><blockquote class="gmail_quote" style="margin:0 0 0 .8ex;border-left:1px #ccc solid;padding-left:1ex">* Gianluca Romanin <<a href="mailto:romaninz@gmail.com">romaninz@gmail.com</a>> [2014-09-15 10:36:50 +0200]:<br>
<span class="">> I'm using the Qt widget style to build a little Webkit browser.<br>
> I need some Html5 features and I would like to know what version of Webkit<br>
> I'm currently using.<br>
> How I can do it? I can't find lot of infos about the Webkit version used by<br>
> Qt.<br>
<br>
</span>You can do this:<br>
<br>
    from PyQt5.QtWebKit import qWebKitVersion<br>
    print(qWebKitVersion())<br>
<br>
For me it's 538.1 with Qt 5.3.1.<br>
<br>
Also note QtWebKit will be deprecated eventually:<br>
<br>
<a href="http://blog.qt.digia.com/blog/2014/09/08/qt-5-4-alpha-available/" target="_blank">http://blog.qt.digia.com/blog/2014/09/08/qt-5-4-alpha-available/</a><br>
<br>
Maybe it would make more sense for you to wait some more weeks for<br>
Qt5.4 and (hopefully) PyQt bindings for QtWebEngine, and then use<br>
that?<br>
<br>
Though I think it'll be some more months or even years before QtWebKit<br>
is fully deprecated, but that's only a guess.<br>
<span class=""><br>
> It is not clear to me what are the differences between QtWebKit and<br>
> QtWebKitWidgets.<br>
<br>
</span>In QtWebKit there are some WebKit related modules which aren't widgets.<br>
Basically the same thing like QtCore and QtWidgets.<br>
<br>
    >>> for e in dir(QtWebKit):<br>
    ...     if not e.startswith('__'):<br>
    ...         print(e)<br>
    ...<br>
    QWebDatabase<br>
    QWebElement<br>
    QWebElementCollection<br>
    QWebHistory<br>
    QWebHistoryInterface<br>
    QWebHistoryItem<br>
    QWebPluginFactory<br>
    QWebSecurityOrigin<br>
    QWebSettings<br>
    qWebKitMajorVersion<br>
    qWebKitMinorVersion<br>
    qWebKitVersion<br>
<span class=""><br>
> It seems that QtWebKit is used mainly for QML and that wraps a more recent<br>
> version of Webkit: QtWebKit dll is about 18 MB while QtWebKitWidgets dll is<br>
> not even 1MB. If so, how can I use QtWebKit in a QWidget style application<br>
> without QML? Is it possible?<br>
<br>
</span>Yes, by importing QtWebKitWidgets instead ;)<br>
<br>
A minimal example showing a webpage:<br>
<br>
    import sys<br>
<br>
    from PyQt5.QtCore import QUrl<br>
    from PyQt5.QtWidgets import QApplication<br>
    from PyQt5.QtWebKitWidgets import QWebView<br>
<br>
    app = QApplication(sys.argv)<br>
    wv = QWebView()<br>
    wv.load(QUrl(sys.argv[1]))<br>
    wv.show()<br>
    app.exec_()<br>
<br>
By the way: Depending on what you're building exactly, it might make<br>
more sense to join an existing project:<br>
<br>
- I'm building a vim-like browser using PyQt and QtWebKit, see<br>
  <a href="https://github.com/The-Compiler/qutebrowser" target="_blank">https://github.com/The-Compiler/qutebrowser</a><br>
<br>
  I'd love some contributors, and I'm happy to mentor and help people<br>
  along the way.<br>
<br>
- Detlev Offenbach is working on the eric IDE[1] which has an<br>
  integrated very feature-complete browser, and he told me he's<br>
  interested in people helping out with it, and also with turning it<br>
  into a standalone application. I think he's reading here as well.<br>
<br>
[1] <a href="http://eric-ide.python-projects.org/" target="_blank">http://eric-ide.python-projects.org/</a><br>
<span class="HOEnZb"><font color="#888888"><br>
Florian<br>
<br>
--<br>
<a href="http://www.the-compiler.org" target="_blank">http://www.the-compiler.org</a> | <a href="mailto:me@the-compiler.org">me@the-compiler.org</a> (Mail/XMPP)<br>
             GPG 0xFD55A072 | <a href="http://the-compiler.org/pubkey.asc" target="_blank">http://the-compiler.org/pubkey.asc</a><br>
         I love long mails! | <a href="http://email.is-not-s.ms/" target="_blank">http://email.is-not-s.ms/</a><br>
</font></span><br>_______________________________________________<br>
PyQt mailing list    <a href="mailto:PyQt@riverbankcomputing.com">PyQt@riverbankcomputing.com</a><br>
<a href="http://www.riverbankcomputing.com/mailman/listinfo/pyqt" target="_blank">http://www.riverbankcomputing.com/mailman/listinfo/pyqt</a><br></blockquote></div><br></div>