-----BEGIN PGP SIGNED MESSAGE-----
Hash: SHA1
The Monday 2007-04-23 at 14:20 +0200, Johannes Meixner wrote:
> > Let's generalize, then. How to add arbitrary strings? File name, page
> > number, date of printing...
>
> For fixed strings (i.e. no page numbers) you can use the "page-label"
> option which will show a fixed string (without spaces) at the very
> top and bottom all of all pages, for example to get the idea try:
>
> echo -en "One\fTwo" | lp -d <queue> -o page-label="$(date +%F,%T)"
Curious! An undocumented feature! It is not in the man page of 'lp'. Are
there more options?
Ok. I tried this:
psnup -2 -m1cm file.ps file-2-tremis.ps & gv file-2-tremis.ps &
This converts to double page with a 1 cm margin (if I don't add the
margin, the label will overwrite the print area later), and check with gv.
Then:
psselect -p9 file-2-tremis.ps pagina.ps && gv pagina.ps &
This selects page 9 and output it to file "pagina.ps". Now, print:
lp pagina.ps -o page-label="page 9"
This printed a rough "page" in a box both at the top and bottom of the
page - but the number "9" went missing. Then I tried:
lp pagina.ps -o page-label="9"
and this, finally, worked.
I can manage to write a little script printing a range of pages, using
psselect on each page. So, I have a working automated solution, although
the output isn't nice.
Curiously, the command "psnup" can print a nice border around the pages; I
wonder why there isn't a program that can automate manipulation of the
pages to add page numbers or any other text.
- --
Cheers,
Carlos E. R.
-----BEGIN PGP SIGNATURE-----
Version: GnuPG v1.4.5 (GNU/Linux)
Comment: Made with pgp4pine 1.76
iD8DBQFGLRJVtTMYHG2NR9URAnwdAJ9HM9HHveB2pCOYRCc6cpm5OpHAdgCffj5u
ceDXKVmO0hf0AMYazroZlbM=
=RUE1
-----END PGP SIGNATURE-----
--
To unsubscribe, e-mail: [EMAIL PROTECTED]
For additional commands, e-mail: [EMAIL PROTECTED]