pdfbox-users mailing list archives

Site index · List index
Message view « Date » · « Thread »
Top « Date » · « Thread »
From Leonard Teo <leon...@ballistiq.com>
Subject Get visible page dimensions/PDRectangle instead of Media Box?
Date Mon, 09 Dec 2013 16:14:10 GMT
Hi guys,

I have an interesting issue where a client has combined PDF files but one
particular PDF is cropped so that half of the page is missing.

When I get the page width using findMediaBox(), it is getting the width of
the Media Box of the page, instead of what is actually visible.

PDRectangle pageSize = page.findMediaBox();
float pageWidth = pageSize.getWidth();

Do you guys know what would be a way of getting the actual visible page
dimensions?

The culprit PDF file is below. If you open this in Acrobat, it appears to
be a single page. If you open it in Adobe Illustrator, you'll see that it's
actually a double page spread.

https://www.dropbox.com/s/3h041kh6eac002m/livre_Gestion_Fraude_2-COVER.pdf

Thanks!

Leonard

--
Leonard Teo
CEO, Partner
Ballistiq Digital Inc.
http://www.ballistiq.com

Mime
  • Unnamed multipart/alternative (inline, None, 0 bytes)
View raw message