Re: Maybe OT: getting general information of a pdf file
Re: Maybe OT: getting general information of a pdf file
- Subject: Re: Maybe OT: getting general information of a pdf file
- From: Jay Petronis <email@hidden>
- Date: Tue, 11 Oct 2005 18:07:34 -0600
is there maybe anybody out there knowing of how to get the general
information (esp. page size (maybe even the different 'boxes'),
count of pages) out of a pdf-file without opening it with preview
or even Acrobat?
If Mac OS X 10.4 is available, Spotlight might help identify some
general information:
/usr/bin/mdls "sample.pdf"
kMDItemNumberOfPages = 1
kMDItemPageHeight = 792
kMDItemPageWidth = 612
You can also try to search through the PDF directly using the command
line:
/usr/bin/grep -a "<</MediaBox" "sample.pdf"
resulting in a string something like "<</MediaBox[0.0 0.0 612.0
792.0]" that could be further parsed with text item delimiters.
_______________________________________________
Do not post admin requests to the list. They will be ignored.
Applescript-users mailing list (email@hidden)
Help/Unsubscribe/Update your Subscription:
This email sent to email@hidden