Print Page | Close Window

PDF Width/Height are wrong

Printed From: Debenu Quick PDF Library - PDF SDK Community Forum
Category: For Users of the Library
Forum Name: I need help - I can help
Forum Description: Problems and solutions while programming with the Debenu Quick PDF Library and Debenu PDF Viewer SDK
URL: http://www.quickpdf.org/forum/forum_posts.asp?TID=992
Printed Date: 08 Jan 26 at 7:20AM
Software Version: Web Wiz Forums 11.01 - http://www.webwizforums.com


Topic: PDF Width/Height are wrong
Posted By: FKirch
Subject: PDF Width/Height are wrong
Date Posted: 11 Dec 08 at 12:35PM
Hi to all,
 
can anybody tell me why quickpdf returns pagewidth/pageheight different to the values returned by acrobat reader?
 
This is my sourcecode:
 

procedure TForm1.Button3Click(Sender: TObject);
var
  Q    : TisedQuickPDF;
begin
  Q    := TisedQuickPDF.Create;
  Q.UnlockKey('...');
  Q.LoadFromFile('567153.PDF');
  Q.SetMeasurementUnits(1);
  ShowMessage(Format('Width: %-3.2fmm',[Q.PageWidth])+' '+
              Format('Height: %-3.2fmm',[Q.PageHeight]));
end;
 
Thankx for your help...
 
By the way: How can I upload my file?
 
 



Replies:
Posted By: Ingo
Date Posted: 11 Dec 08 at 2:46PM
Hi Fritz,
 
you can't upload a file here. Perhaps you have anywhere own online-place for the file?
Normally (what's that?) the dimensions should be the same. Perhaps you set it in QuickPDF to unit millimeters and in acrobat there are pixels? Perhaps there are different pages?
What are the dimensions from acrobat and what are the dimensions from QuickPDF? Perhaps seeing both can give an answer already?
 
Cheers, Ingo
 


Posted By: FKirch
Date Posted: 12 Dec 08 at 1:37AM
Hallo Ingo,
 
ich sehe hier nirgends einen UPLOAD-Button. Wie soll ich das PDF hochladen? Ich habe leider keinen WebSpace.
 
Hi Ingo,
I see no UPLOAD-Button. How to do uploading a file in this forum?


Posted By: Ingo
Date Posted: 12 Dec 08 at 1:56AM
Hi Fritz!

We don't have an upload-button here. Sorry.
But you can send the file to me and if i won't find an explanation by myself i would upload it in my webspace.

Cheers, Ingo



Posted By: ukobsa
Date Posted: 12 Dec 08 at 3:14AM
Hi,

most probably it is a problem with the combinations of Media, Crop, Trim etc. Box. Can you use GetPageBox and post all dimensions for the different box types?

best regards,
Uli


Posted By: FKirch
Date Posted: 12 Dec 08 at 11:00AM
Hi,
 
at the moment the problem is fixed by:
 

procedure TForm1.Button3Click(Sender: TObject);
var
  Q    : TisedQuickPDF;
begin
  Q    := TisedQuickPDF.Create;
  Q.UnlockKey('...');
  Q.LoadFromFile('567153.PDF');
  Q.SetMeasurementUnits(1);
 
if Q.HasPageBox(2) then
  ShowMessage(Format('Width: %-3.2fmm',[Q.GetPageBox(2,2)])+' '+
              Format('Height: %-3.2fmm',[Q.GetPageBox(2,3)]))
else
  ShowMessage(Format('Width: %-3.2fmm',[Q.PageWidth])+' '+
              Format('Height: %-3.2fmm',[Q.PageHeight]));
end;
 
Is this the correct way to retrieve the page dimensions?



Print Page | Close Window

Forum Software by Web Wiz Forums® version 11.01 - http://www.webwizforums.com
Copyright ©2001-2014 Web Wiz Ltd. - http://www.webwiz.co.uk