Welcome Guest (Log in)

HTMLtoIMAGE_v100

StarStarStarStarStar
LC 8+9 (35) | Browser widget (19) | Image (17) | JavaScript (4) | Screenshot (4)
General
Expander triangle
  • Author
  • Rating
  • Type
  • Revision
  • Downloaded
  • Updated
  • Hermann Hoch
  • StarStarStarStarStar
  • Stack
  • 2
  • 120 Times
  • 17 December 2018
HTMLtoIMAGE-sample
### v1.0.0 Dec 17, 2018 ... first version on "Sample Stacks"

HTMLtoIMAGE
makes an image of the *whole* HTML content of a browser widget
(while waiting for printToPdf from the browser widget in 9.x).
The image may have a height of several thousands pixels.

The stack is based on the library from
https://html2canvas.hertzen.com (MIT licensed).

This javaScript library takes "screenshots" of webpages based on the DOM, and as such may not be 100% accurate to the real representation as it does not make an actual screenshot, but builds the screenshot based on the information available on the page.
Then it saves the data to a canvas. ["Overlayed" pages as livecode.com are only partially saved, just try.]

We don't display this HTML5-canvas in a browser but catch the imagedata from it and save it to an image.
You can set options:
the image format: JPEG with quality level or PNG,
an image scale (percentage)

The javaScript library is included in the stack (please watch the license).
Ajax Loader
Tags
Expander triangle
User Comments
Expander triangle