Page 1 of 1

Offset for Axis Label text

Posted: Mon Apr 17, 2017 6:47 pm
by lokesh
Hi,
I was working with custom ticks in axis and I ended up with the below:
markerLabel.png
markerLabel.png (2.85 KiB) Viewed 9423 times
I am wondering if there is a way to apply an offset to the custom label text so it could be displayed just above the line? Or is it possible to redraw the text at a location with offset?

Thanks,
Lokesh

Re: Offset for Axis Label text

Posted: Tue Apr 18, 2017 7:54 am
by ArctionPasi
Hi Lokesh,

that approach needs using two CustomAxisTicks per tick position. One with text and one without it. Give a slightly higher value for tick with a text. You can utilize yAxis.CoordToValue and ValueToCoord method to convert between screen coordinates and axis values as necessary.

Re: Offset for Axis Label text

Posted: Tue Apr 25, 2017 2:30 pm
by lokesh
Hi Pasi,
Sorry for the late response.
Thank you for the work around. That was a pretty simple one and I feel bad it didn't cross my mind. Works great.

Thanks again.

Lokesh