View previous topic :: View next topic |
Author |
Message |
MHB
Joined: 04 Apr 2005 Posts: 69
|
Posted: Tue Apr 12, 2005 3:18 pm Post subject: Auto-adjust row height |
|
|
I'll try again - not sure whether this behaviour is already achievable?
When wordwrap is enabled (and autosizepolicy on the columns is manual), it would be nice if the rows automatically and individually adjusted their height according to content, so that entire multiline items could be shown.
AutoSize on the column works most of the time, but not with very long text nodes.
The manual row height adjustment is not very useful right now, because an adjustment always affects all rows. Or am I missing something? |
|
Back to top |
|
|
Infralution
Joined: 28 Feb 2005 Posts: 5027
|
Posted: Tue Apr 12, 2005 11:25 pm Post subject: |
|
|
Allowing for different height cells is rather difficult because of the data driven nature of VirtualTree. The visual representations of each row are created on the fly rather than upfront (hence the great performance with large datasources). The drawback is that there is no way to know upfront the total height of all rows and so handle things like scrollbars appropriately.
Having said that I can see why you'd like this and we will definitely consider it for the next major release. _________________ Infralution Support |
|
Back to top |
|
|
Infralution
Joined: 28 Feb 2005 Posts: 5027
|
Posted: Fri Aug 12, 2005 4:00 am Post subject: |
|
|
Version 2.0.0 has now been released and includes support for setting the height of individual rows. You can still set the default row height (affecting all rows) by holding down the control key when resizing rows.
Version 2.0.0 also includes the ability have the height of rows automatically calculated to fit the contents (by setting the AutoFitHeight property of the RowBinding). _________________ Infralution Support |
|
Back to top |
|
|
MHB
Joined: 04 Apr 2005 Posts: 69
|
Posted: Fri Aug 12, 2005 10:32 am Post subject: |
|
|
You have no idea how good your timing is! I planned on following up on this issue today, because I really need it now. But, seeing the nice and usable new features of v2, I will stick to a satisfied thank you |
|
Back to top |
|
|
MHB
Joined: 04 Apr 2005 Posts: 69
|
Posted: Tue Aug 16, 2005 11:16 am Post subject: |
|
|
After working a bit with the automatic row height adjustment, it looks like it isn't invoked quite often enough. Actually, it looks like the row height is only adjusted when expanding an item, and then only for all the existing rows (not the new child rows). The result is that when an item is expanded, the row heights of all the new subitems are not updated before some item is expanded.
This can be verified on the very first display of the tree, where the root row is already expanded, but none of the row heights are auto-adjusted (not even the root row, if shown).
Is this a general problem, or a result of my overriding some protected method? |
|
Back to top |
|
|
Infralution
Joined: 28 Feb 2005 Posts: 5027
|
Posted: Tue Aug 16, 2005 10:21 pm Post subject: |
|
|
You are right there does seem to be an issue when you expand child rows that have AutoFitHeight set. Forcing a layout (by moving the vertical scroll or resizing the control) does get the heights right. We will get a fix out for this ASAP. _________________ Infralution Support |
|
Back to top |
|
|
Infralution
Joined: 28 Feb 2005 Posts: 5027
|
Posted: Thu Aug 18, 2005 3:48 am Post subject: |
|
|
This issue has now been fixed in Version 2.0.1 _________________ Infralution Support |
|
Back to top |
|
|
MHB
Joined: 04 Apr 2005 Posts: 69
|
Posted: Mon Aug 22, 2005 2:55 pm Post subject: |
|
|
That helped, but now it looks like AutoFitHeight for rows is invoked before the procedures that resize the columns if needed! This should be the other way around, I think... The result may be that rows are higher than needed, because column widths may be increased afterwards.
The interaction between column and row resizing is a bit complex, but it would seem to me that it would work if columns are resized first, then rows. |
|
Back to top |
|
|
Infralution
Joined: 28 Feb 2005 Posts: 5027
|
Posted: Mon Aug 22, 2005 10:45 pm Post subject: |
|
|
Are you using an SizePolicy of AutoIncrease or AutoSize for the column and combining that with auto height rows? This probably was not a scenario that was envisioned. Let us know if this is what you want and we will have a look at that. _________________ Infralution Support |
|
Back to top |
|
|
MHB
Joined: 04 Apr 2005 Posts: 69
|
Posted: Tue Aug 23, 2005 9:47 am Post subject: |
|
|
That's exactly it. AutoSize, if it matters. |
|
Back to top |
|
|
Infralution
Joined: 28 Feb 2005 Posts: 5027
|
Posted: Wed Aug 31, 2005 3:31 am Post subject: |
|
|
Version 2-0-2 has now been released. It should solve your problems with AutoSize columns interacting with AutoFitHeight rows. _________________ Infralution Support |
|
Back to top |
|
|
MHB
Joined: 04 Apr 2005 Posts: 69
|
Posted: Mon Sep 05, 2005 4:47 pm Post subject: |
|
|
Nice - indeed it works! |
|
Back to top |
|
|
|