Reputation: 9106
I've searched on Google and StackOverflow but am having trouble finding the answer, even though it seems like it should be easy to do.
How can I use Python to load a URL into its own window, rather than in a browser? I imagine this should be trivial in Tkinter or some other GUI package.
Upvotes: 3
Views: 9304
Reputation: 4766
A new option would be: pywebview
pywebview is a lightweight cross-platform wrapper around a webview component that allows to display HTML content in its own native GUI window. It gives you power of web technologies in your desktop application, hiding the fact that GUI is browser based.
See here: https://github.com/r0x0r/pywebview
Upvotes: 4
Reputation: 9634
Yeah. that's very easy with QWebView in PyQt/PySide
You basically instantiate a new QWebView and pass the url to it
QWebView.load(QUrl('http://www.www.pythoncentral.io'))
you can read more here
http://pythoncentral.io/pyside-pyqt-tutorial-qwebview/
and also in the pyQt docs
http://pyqt.sourceforge.net/Docs/PyQt4/qwebview.html
Upvotes: 4