Important: Please read the Qt Code of Conduct -

Replacing NetworkAccessManager features

  • I'm porting my (Python/PyQt) QtWebKit application to QtWebEngine. I used to do some things using the QNetworkAccessManager, but now that this is gone I can't find equivalents in QWebView or QWebPage.


    • How do I set the proxy server and port?

    • How do I handle certificate errors?

    • How do I handle unsupported content (file downloads, e.g.)?

    Any help with these questions would be very appreciated.

  • Well, for posterity, I'll answer my own questions as best I can:

    • Proxy server any port can be set in the OS environment ("http_proxy") and the widget seems to respect this setting.

    • override QtWebEnginePage.certificateError, which should return true if we're ignoring the error. Unfortunately the widget doesn't actually call this function for a lot of certificate errors, so it's not working right now.

    • File downloads aren't supported, maybe in 5.5

    tl;dr - QtWebEngine is very young, wait for future versions for it to be usable.

Log in to reply