Details
-
Bug
-
Resolution: Done
-
P2: Important
-
5.13.0
-
None
-
Windows 10, 5.13 Qt Creator
-
-
da04b1d716617fbe4a2d93dc5a51f38dbd03a5b8 (qt/qtdeclarative/5.13)
Description
TableView 2 allows users the ability to set both sizes and visibility within a TableView using ColumnWidthProviders and RowHeightProviders. Returning 0 from a rowHeightProvider will hide the row from view. Returning -1 from a rowHeightProvider should display a row and fall back to calculating the width of the item column.
In practise this does not happen if a columnWidthProvider is set as well as a rowHeightProvider. Displaying a previously hidden element with a provider will work following a forceLayout(), however columns will not be sized correctly. A second call to forceLayout() correctly sizes the contents.
It appears if you unset columnWidthProvider it functions as expected (Perhaps a function ordering error?)
See attached example. Switch visible rows first, then force a layout. The new rows will be visible but not sized correctly. Then force a layout a second time, the new columns will be sized correctly.
Attachments
For Gerrit Dashboard: QTBUG-77074 | ||||||
---|---|---|---|---|---|---|
# | Subject | Branch | Project | Status | CR | V |
271525,4 | QQuickTableView: always relayout after a rebuild | 5.13 | qt/qtdeclarative | Status: MERGED | +2 | 0 |