1

I've utilised the google timeline visualisation and I'm wondering how I might be able to expand the content shown in the row label - the first column.

I've defined a jsfiddle that shows the first row with data fed from json being interpreted as text. The second row I modify after chart.draw that shows text that has been marked up using the same set of tspans.

enter image description here

The jQuery I apply to the second row is:

$('#example1 div  div svg g:first text:eq(1)').html("<tspan dx='0' dy='-8' font-weight='bold' fill='red'>This is red</tspan><tspan x='5' dy='17' >This is extra info</tspan>");

I'd like to be able to send this all as json data where the visualisation would interpret it as supplied.

Is this beyond the current capability of the google visualisation? A workaround I've considered is to post-process the visualisation to replace IDs with my tspan content - but that sounds hackish.

Scott
  • 4,857
  • 3
  • 22
  • 33
  • I'm sorry, but I've read your post 3 times over and still can't figure out exactly what you're describing as your goal. Perhaps if you posted something on plnkr.co, codepen, jsfiddle, a github gist or something like that so we can see what you're actually working with you might get a response faster. I could take a shot in the dark but without your code I would have to build your project from what you've described to be able to test anything. – nbering Nov 03 '14 at 15:34
  • For the image part, check http://stackoverflow.com/questions/10859257/how-can-i-add-an-image-element-to-the-svg-dom – juvian Nov 03 '14 at 17:37
  • Third attempt at writing the question should be clear now, and jsfiddle working nicely. – Scott Nov 05 '14 at 05:30

0 Answers0