Recent

Author Topic: [solved] Axis Labels - rotate them!  (Read 842 times)

Nicole

  • Hero Member
  • *****
  • Posts: 972
[solved] Axis Labels - rotate them!
« on: September 14, 2022, 11:04:25 am »
I am new to TAChart and not sure, if I put the terms correctly.
my try:

The x-axes has one point in the chart-canvas and as ax-text e.g.: "10.10.2020".
Is it possible to rotate this text for 45 degrees, so that the texts to each point do not overlap?
« Last Edit: September 15, 2022, 10:09:45 am by Nicole »

wp

  • Hero Member
  • *****
  • Posts: 11923
Re: Axis Labels - rotate them!
« Reply #1 on: September 14, 2022, 11:18:56 am »
Set Chart.BottomAxis.Marks.LabelFont.Orientation to 450 (which is the rotation angle in tenths of a degree; the sign follows the mathematical convention of counter-clockwise rotation). By default the orientation is around the center of the label which looks a bit strange to me; but - I think since Laz2.0 - you can select the rotation center in the equally named property of the Axis.Marks.

Alternatively to rotation you could also write the label in two lines by inserting a line-break in the date/time formatstring before the yyyy symbol.

Nicole

  • Hero Member
  • *****
  • Posts: 972
Re: Axis Labels - rotate them!
« Reply #2 on: September 15, 2022, 10:09:24 am »
thank you, worked at sudden!

 

TinyPortal © 2005-2018