Thank you very much Hans !
One of my first thoughts today was using layers (did not think about
it earlier, because I was too focused on plain TeX boxes), but I am
quite new to this topic.
Thanks to your code, I will have time to learn how to use them.

Greetings,


Damien Thiriet

On Mon, Oct 15, 2018 at 11:15:00PM +0200, Hans Hagen wrote:
 
> \definecolor[canaux][h=81b3e0]
> 
> \startreusableMPgraphic{voies}
>     drawarrow
>         (0,0) -- (20,0)
>         withcolor black ;
> \stopreusableMPgraphic
> 
> \startreusableMPgraphic{canaux}
>     drawarrow
>         (0,0) -- (20,0)
>         withcolor \MPcolor{canaux} withpen pencircle scaled 2pt;
> \stopreusableMPgraphic
> 
> \startbuffer[legend]
>     \bTABLE[frame=off]
>         \bTR
>            \bTH 1) \eTH \bTH Le milieu \eTH \bTH 2) \eTH \bTH Les
> activités \eTH
>         \eTR
>         \bTR
>             \bTD
>                 \externalfigure[t:/sources/mill.png][height=12bp]
>             \eTD
>             \bTD
>                 zones urbaines
>             \eTD
>         \eTR
>         \bTR
>             \bTD
>                 \inframed[frame=off,offset=0pt]{\reuseMPgraphic{voies}}
>             \eTD
>             \bTD
>                 infrastructures~: voies ferrées
>             \eTD
>         \eTR
>         \bTR
>            \bTD
>                 \inframed[frame=off,offset=0pt]{\reuseMPgraphic{canaux}}
>             \eTD
>             \bTD
>                 infrastructures~: canaux
>             \eTD
>         \eTR
>     \eTABLE
> \stopbuffer
> 
> \definelayer
>   [legend]
>   [width=\overlaywidth,
>    height=\overlayheight]
> 
> \starttext
> 
> %     \setlayer
> %       [legend]
> %       {\getbuffer[legend]}
> 
>     \setlayerframed
>       [legend]
>       [background=color,
>        backgroundoffset=2pt,
>        backgroundcolor=red,
>        strut=no,
>        frame=off]
>       {\getbuffer[legend]}
> 
>     \externalfigure
>       [t:/sources/cow.pdf]
>       [background={foreground,legend},
>        width=0.9\textwidth]
> 
> \stoptext
> 
___________________________________________________________________________________
If your question is of interest to others as well, please add an entry to the 
Wiki!

maillist : ntg-context@ntg.nl / http://www.ntg.nl/mailman/listinfo/ntg-context
webpage  : http://www.pragma-ade.nl / http://context.aanhet.net
archive  : https://bitbucket.org/phg/context-mirror/commits/
wiki     : http://contextgarden.net
___________________________________________________________________________________

Reply via email to