Welcome Guest Search | Active Topics | Sign In | Register

Image Scaling to fit page Options
Silviu
Posted: Thursday, August 9, 2012 5:11:45 AM
Rank: Newbie
Groups: Member

Joined: 8/9/2012
Posts: 6
I am inserting a single image into a PDF page. I need to ensure that the images are scaled down to fit the page without clipping. What is the best option for accomplishing this task?
eo_support
Posted: Thursday, August 9, 2012 10:16:02 AM
Rank: Administration
Groups: Administration

Joined: 5/27/2007
Posts: 24,195
Hi,

The most straight forward way to do this is to use PdfImageContent. See here for more details and sample code about this feature:

http://www.essentialobjects.com/doc/4/acm/pdf%20content%20api/image.aspx

Thanks!
Silviu
Posted: Thursday, August 9, 2012 10:19:59 AM
Rank: Newbie
Groups: Member

Joined: 8/9/2012
Posts: 6
What Unit Of Measure are the params of the Scale method in? Inches?
eo_support
Posted: Thursday, August 9, 2012 10:36:52 AM
Rank: Administration
Groups: Administration

Joined: 5/27/2007
Posts: 24,195
Hi,

It's 1/72 inches. So if you call Scale(72, 72) you will have a 1 inch by 1 inch image.

Thanks!


You cannot post new topics in this forum.
You cannot reply to topics in this forum.
You cannot delete your posts in this forum.
You cannot edit your posts in this forum.
You cannot create polls in this forum.
You cannot vote in polls in this forum.