diff options
author | Hans Hagen <pragma@wxs.nl> | 2005-12-19 00:00:00 +0100 |
---|---|---|
committer | Hans Hagen <pragma@wxs.nl> | 2005-12-19 00:00:00 +0100 |
commit | 28b6768726b1fc30e1bae370cfa04632b52542c3 (patch) | |
tree | 445dfd14254cb6caedad514e4e55da8bf2475b5d /tex/context/base/supp-mps.tex | |
parent | 64393514fca3f8f070dcc0f95955d846780d82e0 (diff) | |
download | context-28b6768726b1fc30e1bae370cfa04632b52542c3.tar.gz |
stable 2005.12.19
Diffstat (limited to 'tex/context/base/supp-mps.tex')
-rw-r--r-- | tex/context/base/supp-mps.tex | 22 |
1 files changed, 21 insertions, 1 deletions
diff --git a/tex/context/base/supp-mps.tex b/tex/context/base/supp-mps.tex index 97bd09a89..6fc7796c8 100644 --- a/tex/context/base/supp-mps.tex +++ b/tex/context/base/supp-mps.tex @@ -852,6 +852,18 @@ \newcount\MPobjectcounter +% \def\douseMPbox#1% +% {\global\advance\MPobjectcounter\plusone +% \setobject{MP}{\number\MPobjectcounter}\vbox +% {\forgetall +% \loadMPgraphic{\MPgraphicfile.\the\currentMPgraphic}{}% +% \deallocateMPslot\currentMPgraphic +% \placeMPgraphic}% +% \setxvalue{#1}{\noexpand\getobject{MP}{\number\MPobjectcounter}}} +% +% The next one saves the boundingbox. This helps positioning reused +% graphics in layers. + \def\douseMPbox#1% {\global\advance\MPobjectcounter\plusone \setobject{MP}{\number\MPobjectcounter}\vbox @@ -859,7 +871,15 @@ \loadMPgraphic{\MPgraphicfile.\the\currentMPgraphic}{}% \deallocateMPslot\currentMPgraphic \placeMPgraphic}% - \setxvalue{#1}{\noexpand\getobject{MP}{\number\MPobjectcounter}}} + \setxvalue{#1}% + {\noexpand\dodouseMPbox{\number\MPobjectcounter}{\MPllx}{\MPlly}{\MPurx}{\MPury}}} + +\def\dodouseMPbox#1#2#3#4#5% space delimiting would save some tokens + {\xdef\MPllx{#2}% but it's not worth the effort and looks + \xdef\MPlly{#3}% ugly as well + \xdef\MPurx{#4}% + \xdef\MPury{#5}% + \getobject{MP}{#1}} \def\nouseMPbox#1% {\setxvalue{#1}% |