Hans Hagen wrote:
Peter Rolf wrote:
Hans Hagen wrote:
Peter Rolf wrote:
Hans Hagen wrote:
Peter Rolf wrote
* 2 of 3 picture (png) are not found; both unfound file have a "_" in the name
hm, will look into it
I have found the cause of this one. If I don't use \usefigurebase the gfx are found and included.
* position of some (not all) overlay backgrounds is wrong (shifted to the left); maybe only a side effect
Sadly the overlays are still placed at the wrong location.
But one step after the other :)
P
of that you can make an example ...
....I really don't know. This is what I found out so far...
First of all all macros are placed with \setlayer in the same layer, using \framed[background=...]{..} to set the content.
For all macros with shifted overlays * the text is placed at the correct position * the overlay graphic ends exactly where the overlaybox starts ----------------------------- | overlay gfx | text | -----------------------------
The two working (non shifted) macros contain * no text or * the text is encapsulated in a \smash[d]
Mhh, weird. I *removed the text* in one shifted macro and the overlay gfx is placed correctly. Does that ring a bell?
\starttext
\definelayer[test][width=10cm,height=10cm]
\setlayer[test]{xxx} \setlayer[test][preset=rightbottom]{xxx}
\framed[background=test,width=10cm,height=10cm]{zz}
\stoptext
works ok here, so the question is: what is the width/height of your layer
No, it's a bit more complicated. I think the size of the layer has nothing to do with it. It's more like this (which works with the beta) %------------ \definecolor [bluntorange] [r=.9373, g=.6471] \setupcolors[state=start] \definelayer[Test] \setupbackgrounds[text] [background=Test] \defineoverlay[BAR][{\bgroup\color[bluntorange]\blackrule[width=\overlaywidth,height=\overlayheight]\egroup}] \def\FOO{\dosingleempty\doFOO} \def\doFOO[#1]#2{% very simplified macro structure \bgroup \setupstrut\setupinterlinespace% normally with font change \framed[width=30mm,background=BAR]% width is always given {\vbox{\normaloffinterlineskip% vbox for additional offsets \hbox{#2\strut}}}% same for the hbox \egroup} \starttext \framed[width=\textwidth,height=50mm]\bgroup \setlayer[Test][x=2cm,y=2cm]{\FOO{FOOBAR}} \egroup \stoptext % ------------- The document is a multi-layer (context, not pdf layer) mp-graphic with nested structures. So I have many boxes that are placed at specific positions (using \setlayer). Some content is collected in a buffer and then placed in a framed vbox (also by \setlayer). So this is not a simple story (at least not for me). I'll minimize the components of the xml source and then try to build the structure of the macros by hand. No fun, but still better than living without new context features. I'll start with this ASAP. Greetings, Peter