Logo Questions Linux Laravel Mysql Ubuntu Git Menu
 

TVirtualStringTree - setting column cells/nodes Alignment

I have a VirtualStringTree with a Header.Column set to taLeftJustify (default).

Is there a way to set the cells/nodes of that column to taRightJustify so that the nodes will be justified to the right, but the header column text will be justified to the left?

This is my desired result (in column 1):

enter image description here

I'm using a rather old VT version 4.5.5

like image 810
zig Avatar asked Aug 10 '26 23:08

zig


1 Answers

For Column caption alignment use:

Header.Columns[x].CaptionAlignment := taLeftJustify;

and for nodes alignment:

Header.Columns[x].Alignment := taRightJustify;

x = your column

like image 141
Mike Torrettinni Avatar answered Aug 15 '26 10:08

Mike Torrettinni



Donate For Us

If you love us? You can donate to us via Paypal or buy me a coffee so we can maintain and grow! Thank you!