Your Privacy Matters: We use our own and third-party cookies to improve your experience on our website. By continuing to use the website we understand that you accept their use. Cookie Policy
875
AutoFixed Row Height Problem
posted

I just upgraded the version of the controls I was using from version 7.2.something to 8.2 to fix an issue with the Tree control, and now I'm seeing a new problem in the appearance of a WinGrid.

I need the WinGrid to (a) wrap the contents of its cells and (b) autosize the height of its rows to fit the wrapped text. This was working beautifully before, but with the new version it appears that every row now has a minimum height that corresponds to two rows of text, even when none of the cells in the row wrap to a second line. Of course this looks fine when the text does wrap to a second (or even third) line. It's like it won't autosize down to fit the height of a single line of text.

And it's not a factor of all rows being fixed at the height of two lines of text. I can get one of the cells to wrap to a third line and its row height increases to accommodate this, while all other rows stay at the two-line height.

I have:

DisplayLayout.Override.CellMultiLine = true
DisplayLayout.Override.RowSizing = AutoFixed

I've spent the morning trying all kinds of permutations on other properties that I previously hadn't messed with, like DisplayLayout.Override.DefaultRowHeight (which is now back to its default of -1), DisplayLayout.Override.MinRowHeight (which is now back to its default of -1), and RowSizingAutoMaxLines (which is now back to its default of -1). DefaultRowHeight and MinRowHeight can increase the min height of the row, but won't get it down to the height of a single non-wrapped line of text.

So it seems that something has changed in the calculation of minimum row heights between 7.2 and 8.2.20082.1000, but I can't seem to find out how to fix it experimentally. Can you please help me with this?

Thanks!
Jim Honeycutt