Browser
Terence Heaford
theaford at btinternet.com
Mon Jun 22 02:58:29 EDT 2020
That’s the solution I was thinking about.
It’s probably necessary to capture the screen image at a larger size for printing as I suspect otherwise the
printed output will be rather blurred.
Thanks
Terry
> On 21 Jun 2020, at 13:46, Andrew at MidWest Coast Media <andrew at midwestcoastmedia.com> wrote:
>
>
>> I am again looking at implementing Javascript charts within a LC browser.
>> Looking at amCharts.
>> Got a chart displaying easily within the browser widget.
>> Tries to print the card but the widget does not print.
>
>
> I’m using amCharts in another project and ran into the same problem: everything looked right in Live view but would disappear when I tried to print a PDF. The only way I could get them to appear right was by taking a picture of the browser and using that image instead of the live JavaScript in the browser (widget). I think hh keyed me into this with his epic knowledge of this tool
>
> set the width of templateImage to the width of widget "Browser"
> set the height of templateImage to the height of widget "Browser"
> export snapshot from rect globalRect(the rect of widget "Browser") to tSnapshot as JPEG
> create image “renderedBrowser"
> set the visible of widget “Browser” to FALSE
> put tSnapshot into image tSnapshotName
> set the name of image tSnapshotName to tSnapshotName
> set the loc of image tSnapshotName to the loc of widget “Browser"
>
> —Andrew Bell
More information about the use-livecode
mailing list