On 19-Mar-01 Hall Stevenson wrote:
> Ultimately, if you want to edit anything, you need the original. I
> don't think you can even create a PDF "from scratch" or from nothing.
> You have to start with another file.
Well, in fact you can, if you understand the PDF format (which is
far from easy), since a valid PDF file can be written as ASCII text
-- even one which includes graphics and fancy fonts.
A PDF document in ASCII looks a bit like XML, only with different
words. An example is attached (base64-encoded to avois line breaks).
Admittedly I created it by converting the PostScript source for an
example in the Blue Book, for which the source is:
%!PS-Adobe-3.0
/inch {72 mul} def
/wedge { newpath
%% rgbR rgbG rgbB setrgbcolor
0 0 moveto 1 0 translate 15 rotate 0 15 sin translate
0 0 15 sin -90 90 arc closepath} def
gsave
%%0 inch 0 inch translate 3 inch 4 inch translate
0.5 inch 0.5 inch scale 0.02 setlinewidth
1 1 12 { 12 div setgray
gsave wedge gsave fill grestore 0 setgray stroke grestore
30 rotate } for
grestore
showpage
but, as you can see from the PDF file, I could in principle
have simply typed it once I had worked out what to type.
Ted.
--------------------------------------------------------------------
E-Mail: (Ted Harding) <Ted.Harding@nessie.mcc.ac.uk>
Fax-to-email: +44 (0)870 284 7749
Date: 20-Mar-01 Time: 00:04:11
------------------------------ XFMail ------------------------------
Attachment:
rose.pdf
Description: Binary data