-
-
Notifications
You must be signed in to change notification settings - Fork 678
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
Dealing with long images? #1160
Comments
Hello!
Unfortunately no. It’s another duplicate of #36, and we’ll need to implement CSS Fragmentation to have this kind of cases working. One solution would be to use named pages to get a very high page height when you meet these images. |
Is there maybe a way to make images clickable? I.e. shrink long images to the thumbnail size and click on them to get full image? |
You can add |
We can think about that when solving #36. |
@liZe I am using WeasyPrint, and facing the same problem as above so wanted to know if this issue is fixed ? |
Now that we follow most of CSS fragmentation, we have a better idea about what to do. Unfortunately, splitting images is explicitly not supported by the specification:
So, unless there’s a new specification to handle this kind of cases, there’s nothing we can do 😒. But there are other solutions: you can for example use page names to change the size of pages that have long images. |
@liZe Is there any other way which exists that I can make use of to manually perform this function of Splitting big size images across multiple pages in the PDF? |
I don’t think that there’s a magic CSS property for that. The easiest way is probably to set the image as background of a multiple divs, and change the position of the background to cover different parts. |
Hi. I have this html:
It links to a long long loong image and has no CSS. It produces a 3-page PDF. First page is mostly empty (Header, "text above" and a lot of empty space), second one consist of a part of the long image, and the third one is "text below".
So the default behaviour is to cut image fo fit the page length. With some CSS I can shrink the image, but that will make the image unreadable.
Is there a way to split long image into multiple pages? Or maybe some other way of dealing with them, without losing most of the image?
The text was updated successfully, but these errors were encountered: