How do I use TVirtualStringTree to display multi-line items and an "expanded" select item?
I'm trying to create a view similar to the image below (which I know was done using TVirtualStringTree), but I haven't found any code examples on how to achieve this.
Does anyone know how I can have multi-line elements like in the example below and "expand" the select element to show more lines?
a source to share
I think you have an answer, but I'll give you a couple of tips to put it into practice, because it was a little awkward for me. (At least in Delphi 7)
-
If you do # 13 # 10 for a newline, make sure you have a space after # 10, otherwise you won't get a line break.
-
VirtualTree.MultiLine [node]: = true will allow a multiline line, but not necessarily make it multiline.
-
Make VirtualTree.InvalidateNode (Node) then VirtualTree.Refresh tree to get new size for node after caption change.
a source to share
