Details
Description
Description is based on example (files attached):
1) main_wnd.ui - UI file created with Qt Designer 6.2.2. It is very basic and contains only QTableView. Important: editTriggers are changed from default value to nothing (it appears problem isn't present if default set of edit triggers is used and present if something is configured).
2) main_wnd.py - python class compiled from main_wnd.ui with help of command /usr/lib/qt6/uic -g python -o ./main_wnd.py ./main_wnd.ui. Here the problem is already visible - it uses reference to QAbstractItemView but it isn't imported from PySide6.QtWidgets.
3) main.py - simple script to show the window but it will fail with NameError: name 'QAbstractItemView' is not defined error
Exactly the same problem happens for QTreeView
Attachments
Issue Links
- is duplicated by
-
PYSIDE-1816 pyside6-uic not properly creating imports QAbstractItemView when NoEditTriggers Selected in QT Designer
-
- Closed
-
- resulted from
-
PYSIDE-1404 Incompatible import of "Object" in compiled UI
-
- Closed
-
For Gerrit Dashboard: PYSIDE-1773 | ||||||
---|---|---|---|---|---|---|
# | Subject | Branch | Project | Status | CR | V |
389635,4 | Add a tool to regenerate the ui files of the PySide examples | dev | pyside/pyside-setup | Status: MERGED | +2 | 0 |
389639,2 | uic/Python: Import base class for flag values | dev | qt/qtbase | Status: MERGED | +2 | 0 |
389640,2 | Regenerate the example ui files | dev | pyside/pyside-setup | Status: MERGED | +2 | 0 |
389914,1 | uic/Python: Import base class for flag values | 6.2.3 | qt/qtbase | Status: ABANDONED | +2 | 0 |
389915,2 | uic/Python: Import base class for flag values | 6.3 | qt/qtbase | Status: MERGED | +2 | 0 |
389916,2 | uic/Python: Import base class for flag values | 6.2 | qt/qtbase | Status: MERGED | +2 | 0 |
390193,2 | Regenerate the example ui files | 6.2 | pyside/pyside-setup | Status: MERGED | +2 | 0 |
390194,2 | Add a tool to regenerate the ui files of the PySide examples | 6.2 | pyside/pyside-setup | Status: MERGED | +2 | 0 |