Skip to content

(PDF) Page.get_pixmap(). How to render mediabox? #1224

Answered by JorjMcKie
openandclose asked this question in Q&A
Discussion options

You must be logged in to vote

It seems Page.get_pixmap() renders Page.rect.

It does. This is intended, because that is what a PDF viewer would show, too.
If you however do need the mediabox, then your way is certainly possible. There are no stability concerns. If you afterwards intend to do other work with the page based on the previous CropBox / rotation values, simply restore both.

I will try to include this comment in the documentation.
Thank you for bringing this up.

Replies: 1 comment 2 replies

Comment options

You must be logged in to vote
2 replies
@openandclose
Comment options

@openandclose
Comment options

Answer selected by JorjMcKie
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Category
Q&A
Labels
None yet
2 participants