Hi
I see, but now I can not set row height based on cell height because I don’t know cell height. Here is my delegate for a second cell of a TableView
Component
{
id: ruslistDelegate
Column
{
id: column2
Repeater
{
model: roleValue
Text {text: "∙ " + modelData}
}
}
}
There is no any indication of height in this code so I don’t know what height to set in rowDelegate. And I don’t want put here explicit height (because that way I’m more constrained moving to another platform or changing something) or try to calculate height in rowDelegate (because it duplicates code for height calculation and if I change cell delegate I have to remember to change rowDelegate as well).
Moreover if I replace rowDelegate and calculate height there I’ll loose ability to select items (highlighting), alternative background and so on, if I need to save them I’ll need to copy from TableView the content of rowDelegate, but it is a copy-paste and if some day style is changed my table will look inconsistent
Unless I’m overlooking some simple way to do what I need I think this change in TableView is a regression of flexibility. If there is a simple way please tell me
It’s always good when in case you need to change only one parameter – all you have to do is actually change this parameter preserving all other functionality and appearence
↧