How to update PyQt progressbar from an independent function with arguments?

I want to use multiple imported function with arguments that takes some while to run. I want a ‘working’ progress bar that track the processes of that function. I have followed 2 questions already …

How to filter executables using QFileDialog? (Cross-platform solution)

The documentation for QFileDialog.getOpenFileName does not provide any clue on how to filter only executables using a const QString &filter = QString(). Here’s the code for my action using PyQt5: …

PYQT QTimer does not start

I am using PyQt 5 for a GUI app, and I am having a threading issue. There is a close button and once it is clidked, a QTimer starts and then it waits in a while loop that is conditioned on a value of …

In PyQT why somes widgets needs the “self” parameter before calling them, while others don’t

I’m a little bit confused about the use of the “self” parameter with some widgets like (QLineEdit), indeed when learning to use the QLabel widget, I used to call the class without the self …

how to suppress console output from QWebEngineView errors?

I get the following error if I create a QWebEngineView instance from Python instances in different working directories: [2452:9872:1108/] Unable to move the cache:…

PyQt5 – Show virtual keyboard

I’m trying to figure out how to use a virtual keyboard for a touchscreen, using python 3.8 and PyQt5 on Windows. I saw that Qt had his own plugin QtVirtualKeyboard. I pretty much followed what has …

QGridlLayout with non-stretchable-height rows

I’m trying to build a QGridLayout with stretchable-width columns but non-stretchable-height rows. The grid in inside a QScrollArea, and with the exception of the height, it’s almost working. You can see it in the following images: As you can see, the rows are being vertically stretched. I would like all the rows to be equal and to not fit all the parent’s height if there are too few rows (first image). Should I touch the grid or the actual widgets? Edit: reproducible example Answer void QGridLayout::setRowStretch(int row, int stretch) Sets the stretch factor of row row to stretch. The first

Open Window when Clicked on Push Button in Main Window PyQt5 Python

I have gone through the various post similar post which are having similar problems, tried out the answers also but it didn’t worked for me. So here is my problem – I have two windows – TestBox and MailBox, when i click on the TestBox Pushbutton along with Input Path argument, it has to open the MailBox Window, This new window MailBox will send the ModifiedPath to the TestBox again when i closes the MailBox window I have created both windows in PyQt5 Tool and created ui file and then converted to the Python file using – python -m PyQt5.uic.pyuic

Creating a non-overlapping QVideoPlayer and PlotWidget in PyQt5

I am trying to create an app in PyQt5 that has a media (video) player, a graph, and a few buttons. Currently, whenever I try to add the video and graph widgets, they compete for space (lay on top of one another), even when using QGridLayout. Here is the entire file so far. The important parts are under ‘Create video object’, ‘Create plot’, and ‘Create GUI Layout’. Any suggestions for getting the video player to occupy the top portion of the window and the graph to occupy a region underneath? Answer The problem is that the QVideoWidget at startup does

Move pyqt button out of list of buttons

I have a list of pyqt4 push button and want to move the position. Since it is troublesome it make lots of buttons variable I create them through a list. The code below import sys from PyQt5….