diff options
author | Marius <mariausol@gmail.com> | 2011-06-08 20:40:24 +0300 |
---|---|---|
committer | Marius <mariausol@gmail.com> | 2011-06-08 20:40:24 +0300 |
commit | e5fe861660d5cf60cfeb67f7e57f659b309e9613 (patch) | |
tree | f5bc4ea0cd61f18c096f0fd5df8cf439700ba71e /tex/context/base/mult-aux.mkiv | |
parent | b17f22aa285224dcf5b1dbccd795bc73b9a16426 (diff) | |
download | context-e5fe861660d5cf60cfeb67f7e57f659b309e9613.tar.gz |
beta 2011.06.08 19:06
Diffstat (limited to 'tex/context/base/mult-aux.mkiv')
-rw-r--r-- | tex/context/base/mult-aux.mkiv | 50 |
1 files changed, 47 insertions, 3 deletions
diff --git a/tex/context/base/mult-aux.mkiv b/tex/context/base/mult-aux.mkiv index 1dfe6fb8e..47d578ab5 100644 --- a/tex/context/base/mult-aux.mkiv +++ b/tex/context/base/mult-aux.mkiv @@ -5,7 +5,7 @@ %D subtitle=helpers, %D author=Hans Hagen, %D date=\currentdate, -%D copyright=PRAGMA] +%D copyright={PRAGMA ADE \& \CONTEXT\ Development Team}] %C %C This module is part of the \CONTEXT\ macro||package and is %C therefore copyrighted by \PRAGMA. See mreadme.pdf for @@ -113,8 +113,8 @@ \unexpanded\def\doinstallattributehandler#1#2#3% #1 not used here {\def#2##1##2% style color - {\edef\fontattributehash {#3{##1}}% - \edef\colorattributehash{#3{##2}}% + {\edef\fontattributehash {#3{##1}}% this name is public + \edef\colorattributehash{#3{##2}}% this name is public \ifx\fontattributehash \empty\else\dosetfontattribute \fontattributehash {##1}\fi \ifx\colorattributehash\empty\else\dosetcolorattribute\colorattributehash{##2}\fi}} @@ -194,6 +194,42 @@ \expandafter\noexpand\csname everysetup#2\endcsname \expandafter\noexpand\csname setupcurrent#2\endcsname}} +\unexpanded\def\doinstallswitchsetuphandler#1#2#3#4#5#6% + {\ifx#3\relax\let#3\empty\fi + \unexpanded\def#2{\dodoubleempty#4}% + \unexpanded\def#6{\getparameters[#1#3]}% + \newtoks#5% + \def#4[##1][##2]% maybe helper + {\ifsecondargument % no commalist here + \let\savedsetupwhatever#3% + \edef#3{##1}% + \getparameters[#1#3][##2]% + \the#5% + \let#3\savedsetupwhatever + \else\iffirstargument + \doifassignmentelse{##1} + {\let\savedsetupwhatever#3% + \let#3\empty + \getparameters[#1][##1]% + \the#5% + \let#3\savedsetupwhatever} + {\edef#3{##1}% this will catch reset + \the#5}% + \else + \let#3\empty + \the#5% + \fi\fi}} + +\unexpanded\def\installswitchsetuphandler#1#2% + {\normalexpanded + {\doinstallswitchsetuphandler + {\noexpand#1}% \??aa + \expandafter\noexpand\csname setup#2\endcsname + \expandafter\noexpand\csname current#2\endcsname + \expandafter\noexpand\csname d@setup#2\endcsname + \expandafter\noexpand\csname everysetup#2\endcsname + \expandafter\noexpand\csname setupcurrent#2\endcsname}} + \unexpanded\def\installcommandhandler#1#2#3% \??self name \??parent (can be \??self) {\installparameterhandler {#1}{#2}% \installparameterhashhandler{#1}{#2}% @@ -202,6 +238,14 @@ \installsetuphandler {#1}{#2}% \installattributehandler {#1}{#2}} +\unexpanded\def\installswitchcommandhandler#1#2#3% \??self name \??parent (can be \??self) + {\installparameterhandler {#1}{#2}% + \installparameterhashhandler{#1}{#2}% + \installparametersethandler {#1}{#2}% + \installdefinehandler {#1}{#2}{#3}% + \installswitchsetuphandler {#1}{#2}% + \installattributehandler {#1}{#2}} + \unexpanded\def\installnamespace#1% {\setvalue{????#1}{@@@@#1}} |