Re: [NTG-context] MP figures in the background

At 09:24 15/12/2003, you wrote:
\defineoverlay[page][\useMPgraphic{dummy}] \setupbackground[page][background=page] \startstandardmakeup some text \stopstandardmakeup \setupbackground[page][background=] rest of text on next page or: \definelayer[page] \setlayer[page]{\useMPgraphic{dummy}] \startstandardmakeup some text \stopstandardmakeup rest of text on next page Hans (who right now is going to print this years christmas card -)

On Mon, 15 Dec 2003, Hans Hagen wrote:
Thanks for the replay. I can't test it know, by i'm sure it will work :-)
Hans (who right now is going to print this years christmas card -)
I think the copyright for my christmas card should be your. I have stold the idea of using one image and ramdoly distribuite and change colors for your wonderfull PRAGMA christmas cards! Zunbeltz

Hi Hans! I'm in trouble with this method. (I supose the error is mine). I can draw the MP graphic using \useMPgraphic, but when i use \defineoverlay[bihotzak][\useMPgraphic{bihotz}] \setupbackgrounds[paper][background=bihotzak] I get the following error systems : randomizer starts with 150693575 [MP to PDF] (./mpgraph.1) layout : calculating backgrounds [MP to PDF] (./mpgraph.4000 ! Dimension too large. \handleMPboundingbox ... 2 \advance \dimen 0 #4bp \dimen 0=\MPxscale \dimen ... l.2 %%BoundingBox: -6 -141 --32768 --32768 I put my file in the end
Hans (who right now is going to print this years christmas card -)
Zunbeltz (who is working hard to print a christamas card :-) \setupoutput[pdftex] \setupcolors[state=start] \setuplayout[location=middle,marking=on] \setuppagenumber[state=stop] %\setuppapersize[CD][A4] %\useexternalfigure[bihotzirudia][biho.mps][width=12cm,height=12cm] \starttext \startuseMPgraphic{bihotz} u = 0.017mm; z0 = (10,16.2)*u; z1 = (14,17.8)*u; z2 = (19.5,12.5)*u; z3 = (10,0)*u; z4 = (0.5,12.5)*u; z5 = (6,17.8)*u; z6 = (10,16.2)*u; % penwidth = 3cm; pickup pencircle scaled 0.4; randomseed := 12346; color color[],colourout,colourin; color1 = 0.9red; color2 = (red+0.4yellow); path heart; heart := z0..z1{right}..z2{down}..{dir-110}z3{dir90}..{dir 90}z4.. {right}z5..z6; pair shiftvector; picture heartpicture[]; draw heart withcolor color1; fill heart..cycle withcolor color2 ; heartpicture0 := currentpicture; currentpicture:= nullpicture; draw heart withcolor color2; fill heart..cycle withcolor color1; heartpicture1 := currentpicture; currentpicture:= nullpicture; % scalation := 0.001mm; pair shiftvector; draw heartpicture0 scaled 0.01mm; for i=1 upto 1: shiftvector := (uniformdeviate 12, uniformdeviate 12); if uniformdeviate 2 > 1: draw heartpicture0 shifted shiftvector scaled 1cm;% scaled scalation; else: draw heartpicture1 shifted shiftvector scaled 1cm;% scaled scalation; fi; endfor; setbounds currentpicture to unitsquare scaled 12cm; \stopuseMPgraphic %\definecolor[color1][r=0.9,] %\definecolor[color2][r=1,y=0.4] \useMPgraphic{bihotz} %\useMPgraphic{bihotz} \defineoverlay[bihotzak][\useMPgraphic{bihotz}] %\setlayer[page]{\externalfigure[bihotzirudia]} %\externalfigure[biho]%[width=12cm] %\defineoverlay[page] %[width=12cm] \setupbackgrounds[paper][background=bihotzak] \startstandardmakeup some text \stopstandardmakeup %\setupbackgrounds[page][background=] %\page[yes] %\leftaligned{2004 bihotz} %\leftaligned{2004 \color[color2]{urterako}} %\blank %\rightaligned{Zure Ciruelitoa} \stoptext
participants (2)
-
Hans Hagen
-
Zunbeltz Izaola