diff options
Diffstat (limited to 'Master/texmf-dist/tex/context/base/mkiv/mlib-pps.mkiv')
-rw-r--r-- | Master/texmf-dist/tex/context/base/mkiv/mlib-pps.mkiv | 35 |
1 files changed, 34 insertions, 1 deletions
diff --git a/Master/texmf-dist/tex/context/base/mkiv/mlib-pps.mkiv b/Master/texmf-dist/tex/context/base/mkiv/mlib-pps.mkiv index c9d181bf976..05113058511 100644 --- a/Master/texmf-dist/tex/context/base/mkiv/mlib-pps.mkiv +++ b/Master/texmf-dist/tex/context/base/mkiv/mlib-pps.mkiv @@ -57,14 +57,36 @@ \let\MPLIBsettext\MPLIBsetNtext +\unexpanded\def\MPLIBsetNtextX#1% #2% box text + {\MPLIBflushenvironment + \hbox\bgroup % text + \meta_set_current_color + \let\MPLIBflushenvironment\doMPLIBflushenvironment + \let\next} + +\unexpanded\def\MPLIBsetCtextX#1#2% #3% box colorspec text + {\MPLIBflushenvironment + \hbox\bgroup % text + \directcolored[#2]% + \meta_set_current_color % so, textcolor wins ! + \let\MPLIBflushenvironment\doMPLIBflushenvironment + \let\next} + +\let\MPLIBsettextX\MPLIBsetNtextX + \unexpanded\def\MPLIBgettextscaled#1#2#3% why a copy .. can be used more often {\clf_mpgettext\MPtextbox #1% \vpack to \zeropoint{\vss\hpack to \zeropoint{\scale[\c!sx=#2,\c!sy=#3]{\raise\dp\MPtextbox\box\MPtextbox}\forcecolorhack\hss}}} +% \unexpanded\def\MPLIBfigure#1#2% +% {\setbox\scratchbox\hpack{\externalfigure[#1][\c!mask=#2]}% +% \clf_mpsetsxsy\wd\scratchbox\ht\scratchbox\zeropoint +% \vpack to \zeropoint{\vss\hpack to \zeropoint{\scale[\c!sx=\sx,\c!sy=\sy]{\box\scratchbox}\hss}}} + \unexpanded\def\MPLIBfigure#1#2% {\setbox\scratchbox\hpack{\externalfigure[#1][\c!mask=#2]}% \clf_mpsetsxsy\wd\scratchbox\ht\scratchbox\zeropoint - \vpack to \zeropoint{\vss\hpack to \zeropoint{\scale[\c!sx=\sx,\c!sy=\sy]{\box\scratchbox}\hss}}} + \vpack to \zeropoint{\vss\hpack to \zeropoint{\fastsxsy{\sx}{\sy}{\box\scratchbox}\hss}}} % horrible (we could inline scale and matrix code): @@ -185,4 +207,15 @@ \setbox\scratchbox\hpack\bgroup \unexpanded\def\MPLIBstopgroup{\doMPLIBstopgroup{#1}{#2}{#3}{#4}{#5}{#6}}} +% For now here ... will be cleaned up: + +\newtoks\mptexttoks +\newbox \mptextbox +\newtoks\mpoutlinetoks +\newtoks\mpgraphictexttoks + +\mptexttoks {\global\setbox\mptextbox\hbox{\clf_mptexttoks}} +\mpoutlinetoks {\global\setbox\mptextbox\vbox{\clf_mpoutlinetoks}} +\mpgraphictexttoks{\global\setbox\mptextbox\vbox{\clf_mpgraphictexttoks}} + \protect \endinput |