I'm interested in being able to perform simple edits on PDF files.
For example, I might want to be able to change the colors of some
characters and output the changed version.
If I had the ability to import and export PDF files as Perl data
structures (and a reference to what I'd be encountering :-), I'm
pretty sure I could do the rest. Looking at the CPAN, I see a
number of modules that _might_ be useful for this, but I'm hoping
that someone here will know which ones are the most relevant.
Help? Clues? Sugestions?
-r

Signature
email: rdm@cfcl.com; phone: +1 650-873-7841
http://www.cfcl.com - Canta Forda Computer Laboratory
http://www.cfcl.com/Meta - The FreeBSD Browser, Meta Project, etc.
> I'm interested in being able to perform simple edits on PDF files.
> For example, I might want to be able to change the colors of some
> characters and output the changed version.
I looked ad Apple's PDFKit, thinking there might be a solution, but
no. Lots of stuff for searching, annotating, and rearranging pages -
but no low-level editing functions like you describe. Which makes
sense - PDF is really more of a delivery format than an editing format.
Do you have control over the source of these PDF documents? If so,
you could make your changes there, and maybe use Automator to build
up a workflow to create and manage the PDFs.
sherm--
Cocoa programming in Perl: http://camelbones.sourceforge.net
Hire me! My resume: http://www.dot-app.org
Rich Morin - 22 Aug 2005 05:42 GMT
>PDF is really more of a delivery format than an editing format.
Yeah, but Acrobat now supports mark-up, etc. I have also edited
PostScript files in the past, which is the same basic idea. I
COULD convert the files to PS in order to edit them, then convert
back to PDF. But that's pretty ugly...
>Do you have control over the source of these PDF documents?
No; I need to deal with random PDFs that I find on the web, etc.
-r

Signature
email: rdm@cfcl.com; phone: +1 650-873-7841
http://www.cfcl.com - Canta Forda Computer Laboratory
http://www.cfcl.com/Meta - The FreeBSD Browser, Meta Project, etc.
Alan Fry - 22 Aug 2005 09:33 GMT
You may well find PDF::API2 will do what you want. The downside is the
module is huge, complex and sparsely documented. There are however
helpful folk to be found at <perl-text-pdf-modules@groups.yahoo.com>
and a Twiki at <http://pdfapi2.sourceforge.net/twiki/>. Some scripts
there might give you an overview of the capabilities of the module.
Alan Fry
>> I'm interested in being able to perform simple edits on PDF files.
>> For example, I might want to be able to change the colors of some
[quoted text clipped - 14 lines]
> Cocoa programming in Perl: http://camelbones.sourceforge.net
> Hire me! My resume: http://www.dot-app.org
Joseph Alotta - 22 Aug 2005 16:59 GMT
I think someone needs to build an editor for PDF files. Maybe macros
for emacs or vim.
>> I'm interested in being able to perform simple edits on PDF files.
>> For example, I might want to be able to change the colors of some
[quoted text clipped - 14 lines]
> Cocoa programming in Perl: http://camelbones.sourceforge.net
> Hire me! My resume: http://www.dot-app.org
Torkjell Arntzen - 22 Aug 2005 18:30 GMT
Hello..
This have been a problem as long as PDF has existed. The PDF format was
initially created as a simpler and smaller format than PostScript. It's like
PS not a format that was intended to be editable
There are some applicarions thought that you might like to try out.
The commersial "Solvere" from the german company One Vision
You may also try to parse a PDF into Illustrator, but then the structure
will be lost
Both are pretty expensive solutions and are not very good soulutions but
still.....
So I could not agree more: Build a simple, small, inexpensive editor...
Regards
Torkjell Arnzten
> I think someone needs to build an editor for PDF files. Maybe macros
> for emacs or vim.
[quoted text clipped - 17 lines]
>> Cocoa programming in Perl: http://camelbones.sourceforge.net
>> Hire me! My resume: http://www.dot-app.org