[flpsed] using flpsed with a perl program

From: Bonnie Dalzell <bdalzell_at_qis.net>
Date: Fri, 3 Dec 2010 16:18:16 -0500 (EST)

Thank you so much for flpsed.

I raise dogs and there are "official" record pages that the American
Kennel Club wants breeders to keep in hard copy format. I needed to make
50 different versions of this page.

The page is available as a PFD but is not editable.

I used flpsed and Perl to make an editable one that can also be stored
on the computer in editable form so that changes can be made without
having to retype all the information.

I do not know the PS language but what I did was to make a master
editable form with flpsed entering variable names where I wanted to fill
in the form. (such as $dog_name).

Then I saved this flpsed .ps form.

Then I opened the .ps document in gedit and made three different files out
of it.

file 1 is called prolog and contains everything prior to the line:

% PSEditWidget Begin

file 2 contains the portion between:

% PSEditWidget Begin


% PSEditWidget End

This file 2 contains my variable names.

file 3 is everything past the

PSEditWidget End


so I made the contents of file 2 a HERE document in a subroutine and I set
the values submitted from the form in %param equal to the variables in
file 2.

Subroutine opens file 1 into an array. prints that out to the new document
(which takes its name from the dog's name); prints out the HERE routine to
the new document; opens file 3 into an array and prints it out to the new

Result is a filled out postscript page with the information submitted
from from an html form.

however since file 3 contains a big binary section it does not work in
Perl for me with taint turned on so right now it is only useful for
local use on my system.

I am not sure how to contain the binary block in a variable within the
program yet.

I discovered that using the html submission form variable <textarea>
resulted in a document readable in flpsed but not printable on my system
(Ubuntu Linux) as textarea submits line feeds to the cgi program which
then are passed through to the variable values. need to get rid of the
line feeds in variables before sending the document out to the final .ps

                        Bonnie Dalzell, MA
|EMAIL:bdalzell dot at dot qis dot net
Freelance anatomist, vertebrate paleontologist, writer, illustrator, dog
breeder, computer nerd & iconoclast... Borzoi info at www.borzois.com.
HOME www.batw.net ART bdalzellart.batw.net BUSINESS www.boardingatwedge.com
Received on Fri Dec 03 2010 - 22:18:16 CET

This archive was generated by hypermail 2.2.0 : Fri Dec 03 2010 - 22:20:02 CET