summaryrefslogtreecommitdiff
path: root/metapost
diff options
context:
space:
mode:
authorHans Hagen <pragma@wxs.nl>2021-06-01 17:45:33 +0200
committerContext Git Mirror Bot <phg@phi-gamma.net>2021-06-01 17:45:33 +0200
commit268cc2e9f10c887b29ac2136e9a0cdf40e464796 (patch)
treea91fa89364a765592fd6602308dc875c812da5a3 /metapost
parent316fec3fcb4b5e6f352a3a58db1656e08659202c (diff)
downloadcontext-268cc2e9f10c887b29ac2136e9a0cdf40e464796.tar.gz
2021-06-01 17:02:00
Diffstat (limited to 'metapost')
-rw-r--r--metapost/context/base/mpxl/mp-luas.mpxl26
1 files changed, 21 insertions, 5 deletions
diff --git a/metapost/context/base/mpxl/mp-luas.mpxl b/metapost/context/base/mpxl/mp-luas.mpxl
index 2313fbe09..4b92bb423 100644
--- a/metapost/context/base/mpxl/mp-luas.mpxl
+++ b/metapost/context/base/mpxl/mp-luas.mpxl
@@ -310,7 +310,7 @@ permanent showproperty, showhashentry ;
newscriptindex mfid_textextanchor ; mfid_textextanchor := scriptindex("textextanchor") ;
-def textextanchor = runscript mfid_textextanchor enddef ;
+% def textextanchor = runscript mfid_textextanchor enddef ;
vardef textextanchor(expr p) =
runscript mfid_textextanchor (prescriptpart p)
@@ -318,8 +318,24 @@ enddef ;
permanent textextanchor ;
-newscriptindex mfid_anchorxy ; mfid_anchorxy := scriptindex "anchorxy" ; def anchorxy(expr name, x, y) = runscript mfid_anchorxy name x y enddef ;
-newscriptindex mfid_anchorx ; mfid_anchorx := scriptindex "anchorx" ; def anchorx (expr name, x, y) = runscript mfid_anchorx name x y enddef ;
-newscriptindex mfid_anchory ; mfid_anchory := scriptindex "anchory" ; def anchory (expr name, x, y) = runscript mfid_anchory name x y enddef ;
+newscriptindex mfid_anchorxy ; mfid_anchorxy := scriptindex "anchorxy" ; def anchorxy (expr name, x, y) = runscript mfid_anchorxy name x y enddef ;
+newscriptindex mfid_anchorx ; mfid_anchorx := scriptindex "anchorx" ; def anchorx (expr name, x, y) = runscript mfid_anchorx name x y enddef ;
+newscriptindex mfid_anchory ; mfid_anchory := scriptindex "anchory" ; def anchory (expr name, x, y) = runscript mfid_anchory name x y enddef ;
+newscriptindex mfid_anchorht ; mfid_anchorht := scriptindex "anchorht" ; def anchorht (expr name, x, y) = runscript mfid_anchorht name x y enddef ;
+newscriptindex mfid_anchordp ; mfid_anchordp := scriptindex "anchordp" ; def anchordp (expr name, x, y) = runscript mfid_anchordp name x y enddef ;
+newscriptindex mfid_anchorll ; mfid_anchorll := scriptindex "anchorll" ; def anchorll (expr name, x, y) = runscript mfid_anchorll name x y enddef ;
+newscriptindex mfid_anchorur ; mfid_anchorur := scriptindex "anchorur" ; def anchorur (expr name, x, y) = runscript mfid_anchorur name x y enddef ;
+newscriptindex mfid_anchorbox ; mfid_anchorbox := scriptindex "anchorbox" ;
+
+vardef anchorbox(expr lname, lx, ly, rname, rx, ry) =
+ (runscript mfid_anchorbox lname lx ly rname rx ry)
+enddef ;
+
+vardef matrixbox (expr fx, fy, tx, ty) =
+ anchorbox ("matrix", fx, fy) ("matrix", tx + 1, ty)
+enddef ;
-permanent anchorxy, anchorx, anchory ;
+permanent
+ anchorxy, anchorx, anchory,
+ anchorht, anchordp,
+ anchorll, anchorur, anchorbox ;