[XeTeX] Help in Tex and PDF Positions

Ulrike Fischer news2 at nililand.de
Thu Jan 8 10:41:07 CET 2009


Am Wed, 7 Jan 2009 17:31:34 -0500 schrieb Francisco Chaves:

> Hi Pete
> 
> Thank you for your response.  Actually I need not only the dimensions but
> the position of the box in the page, in order to put the signature field in
> the pdf file. is it possible to know and print the box position in a page
> using LaTeX?

pdftex and xetex knows the primitive \pdfsavepos which you can use
to save page positions e.g. with zref (it needs two runs, and you
should be carefull to correctly set the pdf page size with geometry
or an option like pagesize):

\documentclass[pagesize]{scrartcl}
\usepackage[savepos,user]{zref}
\usepackage{eso-pic}
\begin{document}

\AddToShipoutPicture*{\unitlength1sp
 \begin{picture}(0,0)
 \put(\zposx{A},\zposy{A}){here is A}
 \end{picture}
 \begin{picture}(0,0)
 \put(\zposx{B},\zposy{B}){here is B}
 \end{picture}
 }

1.\zsavepos{A}

\vspace*{3cm}


2. abcde\zsavepos{B}
\end{document}

-- 
Ulrike Fischer 



More information about the XeTeX mailing list