Re: [NTG-context] simple usage of \hpos

2010-02-07 Thread Wolfgang Schuster
Am 06.02.10 23:17, schrieb Peter Münster: Hello, How can I place an element as background at a previously defined position? Here a test-file to show what I'm looking for: \definelayer[graphics][position=yes] \setupbackgrounds[page][background=graphics] \starttext Here is some text. I would

Re: [NTG-context] simple usage of \hpos

2010-02-07 Thread Peter Münster
On Sun, Feb 07 2010, Wolfgang Schuster wrote: \newcounter\BackgroundPictures \definelayer[BackgroundPicture][width=\paperwidth,height=\paperheight] \def\FixedPicture {\dodoubleempty\doFixedPicture} \def\doFixedPicture[#1][#2]% {\doglobal\increment\BackgroundPictures

Re: [NTG-context] simple usage of \hpos

2010-02-07 Thread Wolfgang Schuster
Am 07.02.10 13:22, schrieb Peter Münster: The main idea, to position the layer with x=\MPx{} and y=\MPy{} seems to be broken. Smaller test-file: \definelayer[graphics][position=yes] \setupbackgrounds[page][background=graphics] \starttext I would like to appear a graphics exactly 2cm left from

Re: [NTG-context] simple usage of \hpos

2010-02-07 Thread Peter Münster
On Sun, Feb 07 2010, Wolfgang Schuster wrote: Remove the 'position=yes' setup and correct the coordinates, layers use the top left corner as origin but positions are measures from the left bottom corner. Ah, now I see, why the graphics was at the bottom before. Thank you very much! Here

Re: [NTG-context] simple usage of \hpos

2010-02-07 Thread Wolfgang Schuster
Am 07.02.10 15:26, schrieb Peter Münster: \def\doPlaceAtPos[#1]#2#3{% \getparameters[PAA][dx=0pt, dy=0pt, #1]% \setbox\scratchbox\hbox{#3}% \setlayer[myBG][% x=\the\dimexpr\MPx{#2} - 0.5\wd\scratchbox\relax, y=\the\dimexpr\paperheight-\MPy{#2}-\ht\scratchbox\relax,

Re: [NTG-context] simple usage of \hpos

2010-02-07 Thread Peter Münster
On Sun, Feb 07 2010, Wolfgang Schuster wrote: \def\doPlaceAtPos[#1]#2#3{% \getparameters[PAA][dx=0pt, dy=0pt, #1]% \setbox\scratchbox\hbox{#3}% \setlayer[myBG][% x=\the\dimexpr\MPx{#2} - 0.5\wd\scratchbox\relax, y=\the\dimexpr\paperheight-\MPy{#2}-\ht\scratchbox\relax,

[NTG-context] simple usage of \hpos

2010-02-06 Thread Peter Münster
Hello, How can I place an element as background at a previously defined position? Here a test-file to show what I'm looking for: \definelayer[graphics][position=yes] \setupbackgrounds[page][background=graphics] \starttext Here is some text. I would like to appear a graphics exactly behind