Closed mire22 closed 3 years ago
@mire22 When executing your code in Linux with PyQt5 5.15 I get:
So I will review because some cells are not shown, the style seems strange to me but try putting: app.setStyle("fusion")
, in addition to that tell me what you get when you run: print(app.style().metaObject().className())
With app.setStyle("fusion")
the lines and the cyan background appear:
Command
print(app.style().metaObject().className())
returns:
QWindowsVistaStyle
without app.setStyle("fusion")
QFusionStyle
with app.setStyle("fusion")
Hi, I just tried with Qt version 5.9.6 and it is the same. I can't see how to solve this issue. Thank you for your help. Rémi
I found the bug! Christmas magic! It was one tabulation too many... For who may be interested: MultipleLevelHeaderViewPython.zip
Hi!
I would like to make a multiple level header view for a QTableView. The example that you made in C++ https://github.com/eyllanesc/stackoverflow/tree/master/questions/46469720 is exactly what I want but in Python. So I translated all the code from C++ to Python with PyQt5 library. The results are that the vertical header works well but not the horizontal header: only the first line is displayed. I compared again and again the full code to find the error but I can't fix it.
You will find the full Python code attached and screenshots: MultipleLevelHeaderView_python.zip In GridTableHeaderView > PaintSection, I printed the cells data and the horizontal header cells are well created and painted... But at the end, they don't show.
Thank you for your help! Rémi
Images
Environment: