Top "Pyqt" questions

PyQt is a set of Python v2 and v3 bindings for The Qt Company's Qt application framework and runs on all platforms supported by Qt including Windows, macOS, Linux, iOS and Android

Python: How to Resize Raster Image with PyQt

I need to find a way to re-size an input raster image (such as jpg) to a specified width/height …

python image pyqt resize aspect-ratio
how to have a directory dialog

In PyQt, how does one display a file browser that shows and selects only directories (not files)? And how does …

python pyqt pyqt4 file-browser
QListWidget adjust size to content

Is it possible to adjust QListWidget height and width to it's content? sizeHint() always returns 256, 192 no matter what its content …

qt pyqt
PyQt5: Center align a label

This should be really simple but I just can't find an answer for this. I've tried this PyQt4 code: label.…

python pyqt pyqt5
How to apply style sheet to a custom widget in PyQt

# -*- coding: utf-8 -*- import sys from PyQt4.QtGui import * from PyQt4.QtCore import * class MainWindow(QWidget): def __…

python pyqt pyqt5 pyqt4 qtstylesheets
Setting the Windows taskbar icon in PyQt

I'm working on an applcation in Python's PyQt4 and cannot find how to change the taskbar icon. I made my .…

python windows pyqt icons taskbar
How can I show a PyQt modal dialog and get data out of its controls once its closed?

For a built-in dialog like QInputDialog, I've read that I can do this: text, ok = QtGui.QInputDialog.getText(self, 'Input …

python qt dialog pyqt modal-dialog
Threading in a PyQt application: Use Qt threads or Python threads?

I'm writing a GUI application that regularly retrieves data through a web connection. Since this retrieval takes a while, this …

python multithreading pyqt
PySide / PyQt detect if user trying to close window

is there a way to detect if user trying to close window? For example, in Tkinter we can do something …

python pyqt tkinter pyqt4 pyside
QListView/QListWidget with custom items and custom item widgets

I'm writing a PyQt application and am having some trouble creating a custom list view. I'd like the list to …

qt pyqt qitemdelegate qlistview qlistwidget