Re: Can Acrobat PDF's be saved as single pages via Applescript
Re: Can Acrobat PDF's be saved as single pages via Applescript
- Subject: Re: Can Acrobat PDF's be saved as single pages via Applescript
- From: Robert Poland <email@hidden>
- Date: Sun, 08 Jan 2017 16:37:49 -0700
- Z-usanet-msgid: XID389VaHXlz1008X33
> On Jan 8, 2017, at 1:33:PM, Brian Christmas <email@hidden> wrote:
>
> G’day Shane & Yvan
>
> Seems that I’ve stirred up a hornets nest concerning my need to really ‘crop’ PDF’s.
>
> It’s critical that I do so with the utmost accuracy, and any failure to ‘crop’ or ‘trim' to the crop is costing my Clients a LOT of money. They’ve only let me know about this recently, after years of putting up with no trimming, and wearing the extra cost, without telling me.
>
> I’m in a bind. My present GUI method is slow, yet I’m under a directive to keep the speed of processing to a maximum. My GUI method has greatly slowed down PDF processing.
>
> I’m not absolutely sure that either of your methods will be acceptable, despite the amount of work you’ve kindly put in.
>
> I must MUST maintain quality, and I MUST trim. The saving as TIFFS seems, at least with my tests, to have maintained the original quality (hadn’t checked file sizes, thanks for that tip, Shane, 1,143,674 bytes). The TIFFS are trashed after use.
>
> Saving as JPEG does not always trim, and I don’t know why, but I’m resorting to it if the resultant TIFFS are too large. I’m also presuming if the TIFFS are too large, then they are full page, with no crop box.
>
> I’ve been investigating Java, which can save PDF’s as pages, but I don’t know if it trims to the crop box when doing so.
>
> Shane, the extra four text boxes, two with Barcodes, are being added via JavaScript.
>
> Regards, and many, many thanks,
>
> Santa
>
>
>
>> On 8 Jan 2017, at 10:37 pm, Shane Stanley <email@hidden> wrote:
>>
>> On 8 Jan 2017, at 9:29 pm, Yvan KOENIG <email@hidden> wrote:
>>>
>>> There is a huge difference.
>>> Although they are twice big than files given by the "old" one they display VERY LESS crisp characters.
>>
>> That's right.
>>
>> Here's Brian's original summary:
>>
>>> Sometimes our clients send large images, with a crop box, and images outside the crop box.
>>>
>>> We only want to print what's in the crop box, but to fit the extra 4 text boxes on the image, I have to enlarge its boundaries.
>>>
>>> This sometimes reveals (and prints) the extra image components that the sender has not cropped.
>>
>> In other words, he wants to completely remove any items outside the PDF crop boxes -- and there's no way to do that (with the tools at hand).
>>
>> The compromise he is using is to make bitmaps of the PDF pages, which *can* be cropped to the crop box. These bitmaps can then be saved in PDFs, to which he can add the other material.
>>
>> The result is much bigger files and potentially lower quality, as you have seen. (The quality can be increased by making the files even bigger.)
>>
>> But there's not much choice -- if he just exports the pages as your code does, the unwanted components will still remain on the page, and will (re)appear when he resets the crop bounds to add the other images. The same thing will happen if he exports them using Acrobat or Smile.
>>
>> It may be that another workaround would be to first add white boxes to mask the extra area before adding the other items -- that would retain the quality. But I don't know how Brian's adding them, so I don't know how feasible it would be.
>>
>> (Another workaround would be to place the PDF on a page in InDesign, cropped to the crop box, add the other items, and then export the page as a PDF.)
>>
>> --
>> Shane Stanley <email@hidden>
>> <www.macosxautomation.com/applescript/apps/>, <latenightsw.com>
I've been using GraphicConverter (without scripting) for years to edit the graphic content of PDFs.
Robert Poland
Fort Collins, CO
_______________________________________________
Do not post admin requests to the list. They will be ignored.
AppleScript-Users mailing list (email@hidden)
Help/Unsubscribe/Update your Subscription:
Archives: http://lists.apple.com/archives/applescript-users
This email sent to email@hidden