Save a chart with overlay to PNG (chartWithOverlay)

82 views
Skip to first unread message

Torstein Viddal

unread,
Dec 16, 2015, 4:58:16 AM12/16/15
to Google Visualization API
Using Google Charts, I want to have the overlay saved to the same PNG as the chart itself. I know how to save just the chart to PNG, problem is the chartWithOverlay doesn't make it to the PNG (it is saved without overlay).

I have no strong feelings pro/con the chartWithOverlay method (https://developers.google.com/chart/interactive/docs/overlays), so alternative solutions to the problem are welcome.

Preferably, a way to make a text–box / overlay within the Chart API should be developed, or if a text–box can be displayed already as is within the API, so that it joins the rest of the chart to the PNG when saving, then tips about how to do this today are much appreciated.

Torstein Viddal

unread,
Dec 16, 2015, 2:41:45 PM12/16/15
to Google Visualization API
Won't save to PNG with the plot: Overlay.


Daniel LaLiberte

unread,
Dec 16, 2015, 4:38:35 PM12/16/15
to Google Visualization API
Hi Torstein,

Since your overlay is implemented with your own image that happens to be drawn in the same area of the page as the chart, the feature which saves the chart to an image doesn't know about your image.  I don't know of any way to work around that, such as merging two images into one.   But there might be some other way to get your browser to capture the generated display.

On Wed, Dec 16, 2015 at 2:41 PM, Torstein Viddal <tvi...@gmail.com> wrote:
Won't save to PNG with the plot: Overlay.


--
You received this message because you are subscribed to the Google Groups "Google Visualization API" group.
To unsubscribe from this group and stop receiving emails from it, send an email to google-visualizati...@googlegroups.com.
To post to this group, send email to google-visua...@googlegroups.com.
Visit this group at https://groups.google.com/group/google-visualization-api.
To view this discussion on the web visit https://groups.google.com/d/msgid/google-visualization-api/1223984a-7102-41ab-babe-b8e919008de8%40googlegroups.com.

For more options, visit https://groups.google.com/d/optout.



--

George Risvas

unread,
Dec 16, 2015, 7:57:47 PM12/16/15
to Google Visualization API
Hi Torstein,
 
There is a 3rd party javascript library named grChartImg (http://www.chartstoimage.eu), which it supports the merging of images or the combination of overlays to a single image.Also the library has much more features.The specific feature called combined-overlaid and it supported in the pro version.
Reply all
Reply to author
Forward
0 new messages