Python GUI FAQ

Common Python GUI Questions, Answered

Answers to our users most frequently answered questions, from licensing, packaging and libraries, to PyQt tips and tricks.

Showing articles for All (286) PyQt6 (128) PySide6 (17) PyQt5 (49) Streamlit (0) Tkinter (1) PySide2 (6) Kivy (0)

Why treeView.selectedIndexes() Returns Duplicate Items in PyQt6

Understanding multi-column selections in QTreeView and how to handle them

Overriding acceptNavigationRequest in QWebEnginePage

Intercept link clicks in QWebEngineView and handle navigation yourself

QTableWidget for List of Dict

Display Python dictionaries in a Qt table using QAbstractTableModel

What happens after defining `app`, but before executing it?

Understanding the relationship between QApplication, widgets, and the event loop in PyQt6

Opening New Windows from Qt Designer Files in PyQt6

How to properly use Qt Designer generated UI files and open new windows with button clicks

CSS Selector for widget Class

How to use Qt property selectors in stylesheets to target widgets by custom class

When will there be a new version of Creating GUI Applications for PyQt6 and PySide6?

Key migration changes from PyQt5/PySide2 to PyQt6/PySide6 and the updated book editions

Transparent TextBrowser

Creating a fading text effect in a QListView using custom model formatting

How to Populate a QComboBox from a CSV File in Python

Load data from CSV files and use it to fill QComboBox dropdown lists in your PyQt or PySide applications

How to Create a Filter/Search Bar for a QTableWidget in PyQt5

Use QSortFilterProxyModel to add live filtering to your tables

Running Custom Functions in Background Threads with QThreadPool and QRunnable in PyQt6

How to run user-defined functions with arguments using QThreadPool and QRunnable in PyQt6

How to Add Widgets After Loading a Qt Designer .ui File

Access layouts and add widgets programmatically to your Qt Designer interfaces

How to get/set the position of the scroll area?

Preserve scroll position and cursor location when updating text in QTextEdit

PyQt Windows Won't Reopen in Spyder — How to Fix It

Why your PyQt app only runs once in Spyder, and what you can do about it

HTML, CSS and JS in a Desktop App... Qt WebEngine vs. Electron vs.?

Comparing approaches to building desktop apps with web technologies and Python

Using Qt Resource Files (.qrc) with PyInstaller and PyQt

How to include pyrcc5-compiled resources when packaging your PyQt application

Segmentation Fault With QProcess Manager

How to fix TypeError and segmentation faults when using QProcess in PyQt6

QSystemTrayIcon — Adding Menu Items in a Loop

Why dynamically created QActions disappear and how to fix it

Fixing DLL Loading Errors When Packaging PyQt Apps with PyInstaller

How to solve "Could not find module .dll" errors when running your packaged app on other computers

Understanding QTimer Timing and Delays in PyQt6

Why your QTimer might not fire on time, and what you can do about it

Changing Ticks in PyQtGraph Objects to Strings

How to replace numeric axis ticks with custom labels like month names or dates in PyQtGraph

QTreeView with QAbstractItemModel in PyQt6

Build hierarchical tree displays using custom models

QTabWidget selected tab text blank

Fixing invisible tab labels on macOS with PyQt6

How to Change the Decimal Separator in QDoubleValidator

Use QLocale to control the decimal point format in PyQt6 QLineEdit validation

Launching PyQt apps in macOS at login

How to configure your PyQt application to start automatically when a user logs in on macOS
1 2 3 4 5 6 7 8 9 10 11 12