Html2canvas: Problem with rendering offscreen div

Created on 4 Oct 2017  路  9Comments  路  Source: niklasvh/html2canvas

im making this comic like thing where i must save images transofrmed and resized inside div... but when i for example scroll down and try to render, it only renders the part which is on the screen.

here is the code https://jsfiddle.net/928x51p6/

Needs More Information

All 9 comments

Incredible coincidence. I have this exact (same) problem right now! And you posted this message 4 hours ago... Wow!

Well, is there any solution to this issue? Thanks in advance.

This is not a real solution, but... if you make zoom-out with the browser until you can fit the div into the window and call the function, it will export the canvas perfectly.

There are some issues about this subject in the repo and someone made a PR but it's not already merged. I'm using this PR in my project without any problems but it could be great to have a merge in the future.

here is the link: https://github.com/niklasvh/html2canvas/pull/1083

I've applied the changes of that PR and the canvas limits still are cut by the window view.

It's been a while I have done these modifications but now i remembered that I use the custom build of eKoopmans (the guy who made the PR) in his 0.5.0-beta4 release. https://github.com/eKoopmans/html2canvas
This custom build make my app work like I want and render offscreen elements

i copied this version but int wont work... im doing it like this
html2canvas($('#containment-wrapper'),{ letterRendering: true, logging:true, onrendered: function (canvas) { $('body').append(canvas); } });

Is this still an issue with v1.0.0? If so, could you please share an example on jsfiddle.

This issue has been automatically closed because there has been no response to our request for more information from the original author. With only the information that is currently in the issue, we don't have enough information to take action. Please reach out if you have or find the answers we need so that we can investigate further.

Was this page helpful?
0 / 5 - 0 ratings

Related issues

deepender87 picture deepender87  路  4Comments

dking3876 picture dking3876  路  4Comments

tjchambers32 picture tjchambers32  路  3Comments

rrutkows picture rrutkows  路  4Comments

anthonymejia picture anthonymejia  路  4Comments