Per this thread http://forums.adobe.com/message/1162092#1162092 You need to use PDPageGetCropBox() to get the user space coordinates of the page, and then you have to convert it to device space coordinates (or something). I'm not exactly sure what the conversion method or calculation is, however. Here's a snippet of my code, and the rectangle values appear to be insane, at first glance. ASFixedRect rect; PDPage pg = PDDocAcquirePage(pdDoc, 0); PDPageGetCropBox(pg, &rect); char str2[512]; sprintf(str2, "Right = %i - Left = %i -- Top = %i - Bottom = %i\n", rect.right, rect.left, rect.top, rect.bottom); AVAlertNote(str2); PDPageRelease(pg); For some standard 8.5x11 inch docs, I'm getting a right value of 40108032 and top value of 51904512. Divide right by 8.5, and top by 11 and you get 4718592. 65536 * 72 = 4718592. For all of the documents I've tested this on (dividing page width/height by user units for height/width), I'm getting this same value. Do these rectangle values I'm getting back look normal? Why is 65536 in there? Does it have something to do with the number of colors (256^2)? In my program, I will be iterating through all the pdf's in a directory, and I need to check the page size before attempting OCR, in order to prevent that alert box from popping up warning about the 45x45 inch page size. I don't fully understand how user space coordinates relate to actual page size in inches, and would like to know if I can simply reliably divide my user space coordinates for each page in each document by 4718592 in order to get the actual page size in inches. Thanks.
... View more