Is there a text wrap option for key items?


« 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 Smiffy on 8th November 2017
Is there a way to manipulate the size of the box surrounding the key?
My key items may be long - up to 25 characters so I would like to wrap the text onto a new line. I've tried with \n in the text which does wrap the text but the key box doesn't expand so the text overlaps adjacent items. Is it possible to set the box to automatically adjust to the expanded size?

sjswebworks.co.uk/RGraphkey.php

Thanks in advance

Smiffy :-)
Posted by Richard on 8th November 2017
Hi there,

The HTML key supports the use of <br> tags so that you can wrap the text - but not the regular key.

Richard
Posted by Smiffy on 8th November 2017
Thanks for the reply Richard.

I'd thought about using that but as I understand it it is separate to the canvas so I assumed it would not be included when I save to png using toDataUrl?

Smiffy :-)
Posted by Richard on 8th November 2017
Hi,

That's correct - and if you want to get PNGs you'll also need to turn off the textAccessible option otherwise you'll not see any text.

Other than that the key doesn't really handle multi-line text very well.

Richard

Add a reply




« Back to message list