-
Notifications
You must be signed in to change notification settings - Fork 4.8k
New issue
Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.
By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.
Already on GitHub? Sign in to your account
Objects larger than screen are only rendered to the max screen size #461
Comments
A number of cropping issues were fixed with 7e13231 |
Which node are you rendering with html2canvas (i.e. what is the first argument when you call the html2canvas function). What options do you use with it? If you are rendering some other element than There might be a bug here, I'm just trying to narrow down the case. |
I literally just use:-
The 'div' name passed as the element is a easyUI TreeView in a easyUI Dialog, which looks something like this:-
The Dialog is 1012 x 538 (internal dimensions) The #amTreeInner is 949 x 1764 (tree view) |
Good luck! |
I'm using 5.0, just using the deprecated method that's all ;-) Kindest Regards, Paul Please excuse my brevity - I'm sending you this from my mobile phone. On 20 Oct 2014 16:32, "Guilherme Nascimento" [email protected]
|
I've attached a screenshot below to help, the treeview #amTreeInner is contained within that scrolling div in the dialog box. That is the issue I believe, hence my use of If anyone is interested, this web-app displays the complete configuration of a telephone system (an Avaya CM in this case) |
Please fix this! It is an important issue! |
Ok. I applied Lennyman's workaround without touching the html2canvas code: var h = $(element)[0].ownerDocument.defaultView.innerHeight;
$(element)[0].ownerDocument.defaultView.innerHeight = $(element).height();
html2canvas($(element)).then(function(canvas) {
$(element)[0].ownerDocument.defaultView.innerHeight = h;
//Do whatever you want with your canvas
} |
I've something very similiar to the code above - I have a fixed sized div I am capturing, so I set a static value - and I set BOTH height and width. |
Man, that is a bad solution. After calling |
you have to do it in an iframe with |
cenap's workaround without touching the source code works for me. My html2canvas.js version is 0.5.0 alpha. |
@cenap Thanks! Your solutions seems to be working. Kudos! |
For my works just changing the height value In the html2canvas.min.js (v0.5.0-beta4) change the |
@cenap : Ur logic... rocked!!! thank a lot |
Hi,
I discovered that objects (e.g. a DIV) larger than the screen (e.g. Shown with scroll-bars) would only render to the max dimensions of the screen.
Changing this line:-
to this:-
resolves the issue.
The text was updated successfully, but these errors were encountered: