How do I show borders in a grid?
Unsolved
Qt for Python
-
Hi,
I have a window with the data set out in a QGridLayout with some cells in some rows spanning more than one cell in other rows, and I want to be able to display borders around the cells.
I understand that I there is no option in QGridLayout, it's just a layout manager and doesn't handle visible stuff, so how might I do this?
I've looked at QTableModel and QTableView, I know that they display cell border lines, but i cannot find a way of spanning table cells.
I did try using a QFrame inside the grid cells but cannot get it to actually display anything useful. Maybe this would work if I could work out how but so far nada.
This is an ASCII version of the display, if it displays OK:
|+-------------------------Vertical box 1-----------------------------------------------+| ||+------------------------- Horizontal box 1 -----------------------------------------+|| |||+----------------------- Vert Box 2 -------------------+|+-- Grid box ------------+||| |||+----------------------- Horiz Box 2 -----------------+||| |||| ||||Tickt number: 000 | User: xxxxx | User ref: ref |||Next action | person |||| |||+------------------------------------------------------+|||Service | type |||| ||||-----------------------Text box------------------------|||Product | prod |||| ||||Subject: text text text text ||| |||| |||+-------------------------------------------------------+|+------------------------+||| ||+---------------------------------------------------------++------------------------+||| |+-------------------------------------------------------------------------------------+|| |+-------------------------Desc box----------------------------------------------------+|| || Description: text ||| || Text text text ||| || Text text text ||| |+-------------------------------------------------------------------------------------+|| +----------------------------------------------------------------------------------------+
I'm out of idea, do you have any suggestions?