From d1094c61b213e9897b6191965d07a5c250f0be9b Mon Sep 17 00:00:00 2001 From: Hans Hagen Date: Tue, 24 Jul 2007 14:36:00 +0200 Subject: stable 2007.07.24 14:36 --- metapost/context/base/mp-figs.mp | 2 +- metapost/context/base/mp-spec.mp | 21 +++++++++++++++++++++ 2 files changed, 22 insertions(+), 1 deletion(-) (limited to 'metapost') diff --git a/metapost/context/base/mp-figs.mp b/metapost/context/base/mp-figs.mp index aa6bc0399..da5fa0d16 100644 --- a/metapost/context/base/mp-figs.mp +++ b/metapost/context/base/mp-figs.mp @@ -22,7 +22,7 @@ def registerfigure(expr name,width,height) = begingroup ; save s ; string s ; s := cleanstring(name) ; scantokens( s & "_width := " & decimal(width)) ; - scantokens( s & "_height := " & decimal(width)) ; + scantokens( s & "_height := " & decimal(height)) ; endgroup ; enddef ; diff --git a/metapost/context/base/mp-spec.mp b/metapost/context/base/mp-spec.mp index 6c5a557b4..d6f68665b 100644 --- a/metapost/context/base/mp-spec.mp +++ b/metapost/context/base/mp-spec.mp @@ -13,6 +13,27 @@ % Spot colors are not handled by mptopdf ! +% let graycolor = numeric ; +% let greycolor = numeric ; +% let withanycolor = withcolor ; + +% rgbcolor red ; red := (1,0,0) ; +% rgbcolor green ; green := (0,1,0) ; +% rgbcolor blue ; blue := (0,0,1) ; +% cmykcolor cyan ; cyan := (1,0,0,0) ; +% cmykcolor magenta ; magenta := (0,1,0,0) ; +% cmykcolor yellow ; yellow := (0,0,1,0) ; +% graycolor black ; black := 0 ; % (0) ; +% graycolor white ; white := 1 ; % (1) ; + +% primarydef p withcolor c = +% p withanycolor (c) +% enddef ; + +% fill fullcircle scaled 10cm withcolor cyan ; +% fill fullcircle scaled 7cm withcolor red ; +% fill fullcircle scaled 4cm withcolor white ; + % (r,g,b) => cmyk : r=123 g= 1 b=hash % => spot : r=123 g= 2 b=hash % => transparent rgb : r=123 g= 3 b=hash -- cgit v1.2.3