Relative Content

Tag Archive for pythonpyqt5

How do you make a PyQt5 Child Window with QWidget as a parent modal to the window that called it?

I’m learning PyQt5 and would like to know how to prevent the user from interacting with a parent window when a child window is called. I would like to create the QMainWindow display as a menu, perhaps showing several games the user can play. When the user clicks on the game, a new window opens and the menu is inaccessible. Is there a command for the QtWidgets.QWidget object that will make the window display modal to the calling window whether called by a QMainWindow or nested within another QWidget object?

Tables are not shown correctly on laptop monitor

What you see is the MRE of one of my projects.
Three tables in a container.
The problem is that if I launch it using the 4:3 monitor at home the three tables are displayed correctly. If I launch it from the laptop the last table is not displayed.
I thought about using a scrollArea, but to no avail.