aboutsummaryrefslogtreecommitdiff
diff options
context:
space:
mode:
authorRobert Alessi <alessi@robertalessi.net>2020-02-17 23:36:50 +0100
committerRobert Alessi <alessi@robertalessi.net>2020-02-17 23:36:50 +0100
commitbd04fcc37940e954de06c50ed6d23de186662891 (patch)
tree109656b8674daaa5421e70b1c1bcb4729fe3ac04
parenta38513f75709b63dcff4c5e6da36a0eba7eaa691 (diff)
downloadekdosis-bd04fcc37940e954de06c50ed6d23de186662891.tar.gz
replacing 'keycommand' with 'options' (2/3)
-rw-r--r--ekdosis.dtx37
1 files changed, 22 insertions, 15 deletions
diff --git a/ekdosis.dtx b/ekdosis.dtx
index fcb66bd..f377803 100644
--- a/ekdosis.dtx
+++ b/ekdosis.dtx
@@ -468,24 +468,31 @@ Running "make install" installs the files in the local TeX tree.
468% Multi-layer apparatuses 468% Multi-layer apparatuses
469% \begin{macrocode} 469% \begin{macrocode}
470\newif\ifekd@mapps 470\newif\ifekd@mapps
471\newkeycommand+[\|]{\declare@apparatus}[enum direction={LR,RL}, rule={}, 471\options{
472 delim={}, sep={}, bhook={}, 472 /newapp/.new family,
473 ehook={\csname ekd@end@apparatus\endcsname}][1]{% 473 /newapp/direction/.new choice = {LR,RL},
474 |\luadirect|{% 474 /newapp/rule/.new value = {},
475 ekdosis.newapparatus( 475 /newapp/delim/.new value = {},
476 |\luastringN|{#1}, 476 /newapp/sep/.new value = {},
477 |\luastringN|{\commandkey{direction}}, 477 /newapp/bhook/.new value = {},
478 |\luastringN|{\commandkey{rule}}, 478 /newapp/ehook/.new value = {\csname ekd@end@apparatus\endcsname}
479 |\luastringN|{\commandkey{delim}},
480 |\luastringN|{\commandkey{sep}},
481 |\luastringN|{\commandkey{bhook}},
482 |\luastringN|{\commandkey{ehook}})}
483} 479}
484\NewDocumentCommand{\DeclareApparatus}{m O{}}{ 480\NewDocumentCommand{\DeclareApparatus}{m O{}}{
485 \newbool{subsq@unit@#1} 481 \newbool{subsq@unit@#1}
486 \booltrue{subsq@unit@#1} 482 \booltrue{subsq@unit@#1}
487 \unless\ifekd@mapps\global\ekd@mappstrue\fi 483 \unless\ifekd@mapps\global\ekd@mappstrue\fi
488 \declare@apparatus[#2]{#1} 484 \bgroup
485 \options{/newapp,#2}
486 \luadirect{ekdosis.newapparatus(
487 \luastringN{#1},
488 \luastring{\option{/newapp/direction}},
489 \luastring{\option{/newapp/rule}},
490 \luastring{\option{/newapp/delim}},
491 \luastring{\option{/newapp/sep}},
492 \luastring{\option{/newapp/bhook}},
493 \luastring{\option{/newapp/ehook}}
494 )}
495 \egroup
489} 496}
490\@onlypreamble\DeclareApparatus 497\@onlypreamble\DeclareApparatus
491% \end{macrocode} 498% \end{macrocode}
@@ -578,7 +585,7 @@ Running "make install" installs the files in the local TeX tree.
578 \if@pkg@parnotes\parnotes\else\fi% 585 \if@pkg@parnotes\parnotes\else\fi%
579 \if@pkg@footins% 586 \if@pkg@footins%
580 \bgroup% 587 \bgroup%
581 \ifrtl@app\setRL\fi% 588 \ifrtl@app\setRL\else\setLR\fi%
582 \blfootnote{% 589 \blfootnote{%
583 \if@pkg@parnotes% 590 \if@pkg@parnotes%
584 \if@parnotesroman% 591 \if@parnotesroman%
@@ -590,7 +597,7 @@ Running "make install" installs the files in the local TeX tree.
590 \egroup% 597 \egroup%
591 \fi% 598 \fi%
592 \if@pkg@float% 599 \if@pkg@float%
593 \keyparbox[!b]{}{\ifrtl@app\setRL\fi% 600 \keyparbox[!b]{}{\ifrtl@app\setRL\else\setLR\fi%
594 \if@pkg@parnotes% 601 \if@pkg@parnotes%
595 \if@parnotesroman% 602 \if@parnotesroman%
596 \renewcommand*{\theparnotemark}{\roman{parnotemark}}\else\fi% 603 \renewcommand*{\theparnotemark}{\roman{parnotemark}}\else\fi%