Daniel Bundzik schrieb: > Hi! > > How do you position/move a MPgraphic? > > Let us us say that you have the MPgraphics "somebackground" and > "somecolorcircle" (See example below). These MPgraphics are both > framed and used as a background, upon which "sometext" is written on. > How can you freely move or position "somecolorcircle"? ( I want to > move "somecolorcircle" below "sometext") Naturally, I have read > Metafun and tried "shifted (x,y)", \definelayer, \setlayer, register, > \setMPlayer, \getMPlayer... > > In general, if you have defined two or more MPgraphics how do you > position them (In my case "somebackground" is fixed while > "somecolorcircle" could be anywhere on "somebackground")? > Hi Daniel, I attached a working example which uses layers. You should take a look at the 'details.pdf' manual; link and more information can be found on http://wiki.contextgarden.net/Layers Just play around with the layer parameters and see what happens. 'height/width' (for layer definition), 'corner/location' (important to understand!) and 'x/y' should be sufficient for most needs. 'hoffset/voffset' can be handy too, if you want relative positioning. [pack-lyr.mkii] \def\dodefinelayer[#1][#2]% \zeropoint ipv \!!zeropoint {\setuplayer [#1] [\c!doublesided=,\c!preset=, \c!state=\v!start,\c!direction=\v!normal,\c!option=, \c!x=\zeropoint,\c!y=\zeropoint,\c!position=\v!no, \c!line=0,\c!column=0, \c!width=\nextboxwd,\c!height=\nextboxht, \c!offset=\zeropoint,\c!rotation=, % geen 0 ! \c!hoffset=\zeropoint,\c!voffset=\zeropoint, \c!dx=\zeropoint,\c!dy=\zeropoint, \c!location=rb,\c!position=\v!no,\c!page=, \c!method=\v!overlay, \c!sx=1,\c!sy=1,\c!corner=,#2]% \doifvalue{\??ll#1\c!doublesided}\v!yes {\dopresetlayerbox{\v!left #1}% \dopresetlayerbox{\v!right#1}}% \dopresetlayerbox{#1}% \defineoverlay[#1][\composedlayer{#1}]} Best wishes, Peter > How would you solve this? > > Regards, > Daniel >