The QWebEngineView class provides a widget that is used to view and edit web documents
Questions tagged [qwebengineview]
322 questions
3
votes
1 answer
How do I create a print preview of QWebEngineView in PyQt5?
I'm trying to create a print preview of a QWebEngineView but I can't get it to work.
Here's my code:
...
self.view = QWebEngineView()
...
def handle_preview(self):
dialog = QPrintPreviewDialog()
…

Nuh Yamin
- 55
- 6
3
votes
1 answer
What is the alternative to QWebInspector in Qt WebEngine?
The example of the code snippet is here:
from PySide2 import QtCore, QtGui, QtWidgets, QtWebChannel
from PySide2.QtWebEngineWidgets import QWebEngineView, QWebEngineSettings
class AppWindow(QtWidgets.QMainWindow):
def __init__(self, *args,…

YoungMaster
- 395
- 3
- 17
3
votes
1 answer
How to specify user agent in QWebEngineView
I am working on automating functionality on a web page using PyQt5. The page that is displayed in PyQt5 is substantially different from what is displayed in Chrome. If I was to change the User Agent, could I mimic Chromes functionality? And if so,…

VilleLipponen
- 636
- 1
- 13
- 22
3
votes
1 answer
How to get html of a page loaded in QWebEngineView
I am trying to get HTML of a page loaded in PyQT5 QWebEngineView. Here is a simple example:
import sys
from PyQt5.QtCore import *
from PyQt5.QtWebEngineWidgets import *
from PyQt5.QtWidgets import *
def callback_function(html):
…

VilleLipponen
- 636
- 1
- 13
- 22
3
votes
1 answer
I get "Release of profile requested but WebEnginePage still not deleted. Expect troubles !" when PyQt5 application exits
When my Python 3.x apps exists, I get a message on the console
Release of profile requested but WebEnginePage still not deleted. Expect troubles !
and then python crashes
Windows 10 64 bit
Python 3.72 (32 bits)
PyQt5 4.19.18
Googled around an seen…

Eric Boisvert
- 135
- 3
- 9
3
votes
1 answer
How to save dynamically generated web page in QWebEngineView?
I am loading a web page onto QWebEngineView. A user creates a different kind of tables (reports) and then needs to save those tables to local computer as a web page. Here is what I have tried:
Here I use a QWebEnginePage::save() method, but nothing…

Bobur
- 545
- 1
- 6
- 21
3
votes
1 answer
Qt Designer crashes using QWebEngineView
Qt Designer (5.11.2) crashes on selecting the QWebEngineView-Widget.
I am creating a dialogform for including it in QGIS 3 as .ui file. In the form I want to display a website by using the QWebEngineView.
Sadly I am not able to drag the widget…

pascatl
- 153
- 6
3
votes
1 answer
Window does not open new window or tab on external url link click
I need to open an URL using pyQt5. The page has several links that open a new window. pyQt5 opens a windows for the URL but does not do anything after clicking on a link that should open a new window.
P.S I'm using pyQt5.6
I have tried it on Linux…

rajesh kapoor
- 41
- 4
3
votes
1 answer
PySide2 and supporting addToJavaScriptWindowObject
I am trying to port PySide application version #1 to PySide2 and struggle to find the solution for porting following code snippet:
class AppManager(QtCore.QObject):
'''
methods of AppObject will be available from javascript
'''
def…

SpanishBoy
- 2,105
- 6
- 28
- 51
3
votes
1 answer
How to open download file dialog with QWebEngineView?
I'm building a pyqt5 desktop interface where I'm using QWebEngineView to show a html file where I show a Leaflet map. This is working fine.
The next step is to export all features the user added to the map. When I click on "Export Features" on the…

Gabriel Schubert
- 165
- 4
- 12
3
votes
2 answers
Grant access to Cam & Mic using Python for PyQt WebEngine
I am building a simple web app called from Python. I am using the below code. What is the easiest way to programatically grant access to the Cam & Mic when this page is loaded? I have only found C++ examples on the web and cannot find a way to do…

Lee Melbourne
- 407
- 5
- 20
3
votes
0 answers
how to stream live content from YouTube using QWebEngineView
I'm trying to stream live content from youtube using QWebEngineView's load method.
I'm currently passing the live media's url as an argument to load(), as follows:
QWebEngineView *webEngineView = new…

feldrise
- 31
- 5
3
votes
1 answer
Opacity not working with QWebEngineView and translucent background
Perhaps this is a bug. There is a top level widget that must have a drop shadow. Inside that widget I want to display a browser (only to be able to render html). The top level widget's opacity must be adjustable.
For the dropshadow to work as expect…

user2366975
- 4,350
- 9
- 47
- 87
3
votes
1 answer
Odd behavior when trying to assign parentless widget in Qt
I have the following code:
from PyQt5 import QtWebEngineWidgets, QtWidgets
class Q(QtWebEngineWidgets.QWebEnginePage):
pass
app = QtWidgets.QApplication([])
l =…

Dariush
- 463
- 3
- 12
2
votes
0 answers
QWebEngineView and leaflet.js slow performance
I am making desktop app in Python (3.8.10) using QML frontend (Qt 6.4.1)
The principle is that I take data from a CSV file and load it into a pandas dataframe. The data contains coordinates that I want to display on a map using the folium library.…

Filip Prádler
- 21
- 1