summaryrefslogtreecommitdiff
path: root/metapost/context/base/mp-base.mpiv
diff options
context:
space:
mode:
Diffstat (limited to 'metapost/context/base/mp-base.mpiv')
-rw-r--r--metapost/context/base/mp-base.mpiv30
1 files changed, 26 insertions, 4 deletions
diff --git a/metapost/context/base/mp-base.mpiv b/metapost/context/base/mp-base.mpiv
index d800fbb78..2887cc462 100644
--- a/metapost/context/base/mp-base.mpiv
+++ b/metapost/context/base/mp-base.mpiv
@@ -13,7 +13,7 @@
string base_name, base_version ;
base_name := "plain" ;
-base_version := "0.63" ;
+base_version := "1.004 for metafun iv" ;
message "loading metafun, including plain.mp version " & base_version ;
@@ -197,6 +197,28 @@ background := white ; % obsolete
let graypart = greypart ;
let graycolor = greycolor ;
+% color part (will be overloaded)
+
+def colorpart primary t =
+ if colormodel t=7:
+ (cyanpart t, magentapart t, yellowpart t, blackpart t)
+ elseif colormodel t = 5 :
+ (redpart t, greenpart t, bluepart t)
+ elseif colormodel t = 3 :
+ (greypart t)
+ elseif colormodel t = 1 :
+ false
+ elseif defaultcolormodel = 7 :
+ (0,0,0,1)
+ elseif defaultcolormodel = 5 :
+ black
+ elseif defaultcolormodel = 3 :
+ 0
+ else :
+ false
+ fi
+enddef ;
+
% picture constants
picture blankpicture, evenly, withdots ;
@@ -704,10 +726,10 @@ def _finarr text t =
filldraw arrowhead _apth t
enddef ;
-def _findarr text t =
+def _findarr text t = % this had fill in 0.63 (potential incompatibility)
draw _apth t ;
- fill arrowhead _apth withpen currentpen t ;
- fill arrowhead reverse _apth withpen currentpen t ; % ; added HH
+ filldraw arrowhead _apth withpen currentpen t ;
+ filldraw arrowhead reverse _apth withpen currentpen t ; % ; added HH
enddef ;
%% macros for labels