How do I set the X axis text angle in an SVG Bar chart?


« Back to message list

Enter your email address to get email updates on this topic. You can stop receiving updates by clicking the link in the update email messages.

Posted by Sony on 25th October 2017
www.rgraph.net/svg/docs/bar.html#labels-and-text

How to set x axis Text Angle in svg bar graph??

xaxisTextAngle
Posted by Richard on 25th October 2017
Hi there,

The SVG charts don't support having angled text I'm afraid.

Richard
Posted by Sony on 25th October 2017
Thanks Richard,
is it possible in future?
Posted by Richard on 25th October 2017
Hi there,

Probably - though I don't know when.

One thing I remembered when I was just washing the dishes is that you can have carriage returns to allow you to have multiple line labels - like this:

xaxisLabels: ['Luke\r\nWinner!','Mary\r\nLoser']

Richard
Posted by Richard on 26th October 2017
Hi there,

I found the example that I couldn't yesterday of carriage returns:

www.rgraph.net/demos/svg-basic-bar.html

Though looking at it again this appears to be in the dev version only at the moment - not the live version.

One other thing you could do when it is available though is alternate you labels beginning with a \r\n. You do need to also prepend them with a blank unicode character though to get it to work.

When the next version is available this demo will show it:

www.rgraph.net/demos/svg-basic-bar.html

Richard

Add a reply




« Back to message list