[pdftex] define pdf variable and then reference it?

ivo welch ivowel at gmail.com
Thu Jun 1 04:41:13 CEST 2006


I have a strange question.  I would like to customize a large pdftex
generated document for everyone who downloads it.  For example, I
would like to write in the headings of each page "hello, george".
alas, I do not want to have to re-latex for every downloader.

One solution would be to turn off all pdftex compression, and then
look for a very unusual string that I would put into the heading, and
which would be replaced.  (I know that the typesetting of this string
may be off.)  Is this the best solution?

I do not know much about pdf, but if it were to allow me to set a
variable and pdftex were to allow me to use this variable later, it
would solve this very elegantly.  something like
   \pdfdefinevariable{\someheading}{VERYUNUSUALSTRING}
   \pagestyle{myheadings}
   \markboth{\someheading \hfill}
the resolution would occur at display time, not at
latex-typesetting-compile time.  a simple sed program could replace
VERYUNUSUALSTRING with "hello, george", and every page heading would
have "hello, george" on it.

Is the latter possible?  advice appreciated.

/ivo welch


More information about the pdftex mailing list