KnowledgeHub
Questions
Tags
Users
Search
Alex Rivera
|
Logout
Edit Question
Title
Body
I am attempting to render a simple bar graph with a label for each bar as axis ticks on the x-axis. Longer labels run over each other. Since svg text elements don't support word-wrapping I have been looking into alternative solutions. Changing the category text that goes into the labels to include the proper <tspan> elements doesn't work since the text isn't set as the innerHtml but rather just the element's raw text. I have also considered post-processing the labels to remove the text and replace it with tspans, but I haven't found an elegant way to do that yet. Unfortunately I can't use foreignObject since I need IE9 support, but many of the same markup replacement problems would apply to that solution, anyway. Has anyone solved this problem well in the past or have any suggestions?
Tags (comma-separated)
Save Edits
Cancel