diff options
Diffstat (limited to 'Master/texmf-dist/doc/metapost/latexmp/lmp-mfun.mp')
-rw-r--r-- | Master/texmf-dist/doc/metapost/latexmp/lmp-mfun.mp | 34 |
1 files changed, 34 insertions, 0 deletions
diff --git a/Master/texmf-dist/doc/metapost/latexmp/lmp-mfun.mp b/Master/texmf-dist/doc/metapost/latexmp/lmp-mfun.mp new file mode 100644 index 00000000000..a5b44f1b2be --- /dev/null +++ b/Master/texmf-dist/doc/metapost/latexmp/lmp-mfun.mp @@ -0,0 +1,34 @@ +input metafun ; +cmykcolors:=true ;% enable cmyk-specials in MetaFun +input latexmp ; + +% - mode is set to 'normal' since MetaFun doesn't work in rerun-mode; +% please rerun manually +% - the file has to be converted in PDF using MPtoPDF in order +% to interpret the MP-specials generated by MetaFun + +setupLaTeXMP(packages="helvet", + preamble="\renewcommand{\familydefault}{\sfdefault}", + textextlabel=enable,multicolor=enable) ; + +beginfig(1); + save p,c ; pair p ; color c ; + + for i=1 upto 100: + p:= (uniformdeviate 8cm, uniformdeviate 5cm) ; + label.urt("\bfseries\transparent{0.2}{MetaFun}",p) ; + endfor; + + for i=1 upto 20: + c:= (uniformdeviate 1, uniformdeviate 1, uniformdeviate 1) ; + p:= (-50pt+uniformdeviate 100pt, -50pt+uniformdeviate 100pt) ; + label("\bfseries\Huge\color[rgb]{" & + (decimal redpart c) & "," & (decimal greenpart c) & "," & + (decimal bluepart c) & "}" & + "\transparent{0.4}{MetaFun}",(5cm,2.5cm)+p) ; + endfor; + + label.top("two different greens: one in \textcolor[cmyk]{1,0,1,0}{cmyk} " & + "and one in \textcolor[rgb]{0,1,0}{rgb}", (5cm,2.5cm)) ; +endfig; +end |