TeX - LaTeX Asked by Bilal Yilmaz on February 2, 2021
1. Test.tex
Running Test.tex (see below) saves the coordinates (as pt, not mm or sp) of
eins{title 1}{some text }
in the file Test.pos, which is:
% this is Test.tex
documentclass{article}
usepackage[paperwidth=210 mm,paperheight=297 mm,textheight=0mm,left=30mm,right=0mm,top=40mm,bottom=0mm]{geometry}
topskip=0pt
setlength{parindent}{0pt}
usepackage{zref-abspos}
%%%%%%%%%%%%%%%%%%%%%% Producing .pos file %%%%%%%%%%%%%%%%%%%%%%%%%
newwritemywrite
immediateopenoutmywrite=jobname.posrelax
newcommand{eins}[2]%
{zsavepos{#1}
{#2}% Output the text provided as mandatory argumentm
immediatewritemywrite{withoutpt{thedimexpr zposx{#1}sp relax},withoutpt{thedimexpr zposy{#1}sp relax}}%
}
%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%
%%%%%%%%%%%%%%% makes the output in .pos without pt %%%%%%%%%%%%%%%%%
makeatletter
newcommandwithoutpt[1]{%
strip@ptdimexpr dimexpr#1relaxrelax
}
makeatother
%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%
begin{document}
eins{title 1}{some text }
end{document}
2. Testtt.tex
Testtt.tex takes the pdf "blabla.pdf" and puts "some new text…" to the coordinates (10,20) (in pt)
% this is Testtt.tex
documentclass{article}
usepackage[paperwidth=210 mm,paperheight=297 mm,textheight=0mm,left=30mm,right=0mm,top=40mm,bottom=0mm]{geometry}
topskip=0pt
setlength{parindent}{0pt}
begin{document}
includepdf[
picturecommand*={
put(10,20){some new text for the coordinates in Test.pos}%
}]{blabla.pdf}
end{document}
However if I change
put(10,20)
to
put(input{Test.pos})
It doesnt work. So it doesnt take the coordinates in Test.pos.
Doe someone have an idea? Thanks for helping!
Get help from others!
Recent Answers
Recent Questions
© 2024 TransWikia.com. All rights reserved. Sites we Love: PCI Database, UKBizDB, Menu Kuliner, Sharing RPP