diff options
author | Robert Alessi <alessi@robertalessi.net> | 2020-02-17 19:00:45 +0100 |
---|---|---|
committer | Robert Alessi <alessi@robertalessi.net> | 2020-02-17 19:00:45 +0100 |
commit | a38513f75709b63dcff4c5e6da36a0eba7eaa691 (patch) | |
tree | 6b44d7fa45e24b0c81d7d2b080ee7908d164bdf2 | |
parent | 4d20e388f22cf3b0e2174a9253692455b3ec316b (diff) | |
download | ekdosis-a38513f75709b63dcff4c5e6da36a0eba7eaa691.tar.gz |
replacing 'keycommand' with 'options'
-rw-r--r-- | ekdosis.dtx | 41 |
1 files changed, 27 insertions, 14 deletions
diff --git a/ekdosis.dtx b/ekdosis.dtx index 8aea111..fcb66bd 100644 --- a/ekdosis.dtx +++ b/ekdosis.dtx | |||
@@ -353,6 +353,7 @@ Running "make install" installs the files in the local TeX tree. | |||
353 | \RequirePackage{luacode} | 353 | \RequirePackage{luacode} |
354 | \RequirePackage{paracol} | 354 | \RequirePackage{paracol} |
355 | \RequirePackage{keycommand} | 355 | \RequirePackage{keycommand} |
356 | \RequirePackage{options} | ||
356 | \RequirePackage{xparse} | 357 | \RequirePackage{xparse} |
357 | \RequirePackage{etoolbox} | 358 | \RequirePackage{etoolbox} |
358 | \RequirePackage{lineno} | 359 | \RequirePackage{lineno} |
@@ -375,22 +376,34 @@ Running "make install" installs the files in the local TeX tree. | |||
375 | % \end{macrocode} | 376 | % \end{macrocode} |
376 | % Build and process the list of witnesses and hands. | 377 | % Build and process the list of witnesses and hands. |
377 | % \begin{macrocode} | 378 | % \begin{macrocode} |
378 | \newkeycommand+[\|]{\declare@new@witness}[settlement={}, repository={}, | 379 | \options{ |
379 | idno={}, msName={}, origDate={}][3]{% | 380 | /witness/.new family, |
380 | |\luadirect|{% | 381 | /witness/settlement/.new value = {}, |
381 | ekdosis.newwitness( | 382 | /witness/repository/.new value = {}, |
382 | |\luastringN|{#1}, | 383 | /witness/idno/.new value = {}, |
383 | |\luastringN|{#2}, | 384 | /witness/msName/.new value = {}, |
384 | |\luastringN|{#3}, | 385 | /witness/origDate/.new value = {} |
385 | |\luastringN|{\commandkey{settlement}}, | ||
386 | |\luastringN|{\commandkey{repository}}, | ||
387 | |\luastringN|{\commandkey{idno}}, | ||
388 | |\luastringN|{\commandkey{msName}}, | ||
389 | |\luastringN|{\commandkey{origDate}})} | ||
390 | } | 386 | } |
391 | \NewDocumentCommand{\DeclareNewWitness}{m m m o}{% | 387 | \NewDocumentCommand{\DeclareNewWitness}{m m m o}{% |
392 | \IfNoValueTF{#4}{\declare@new@witness{#1}{#2}{#3}} | 388 | \IfNoValueTF{#4} |
393 | {\declare@new@witness[#4]{#1}{#2}{#3}} | 389 | {\luadirect{ekdosis.newwitness( |
390 | \luastringN{#1}, | ||
391 | \luastringN{#2}, | ||
392 | \luastringN{#3} | ||
393 | )}} | ||
394 | {\bgroup | ||
395 | \options{/witness,#4} | ||
396 | \luadirect{ekdosis.newwitness( | ||
397 | \luastringN{#1}, | ||
398 | \luastringN{#2}, | ||
399 | \luastringN{#3}, | ||
400 | \luastring{\option{/witness/settlement}}, | ||
401 | \luastring{\option{/witness/repository}}, | ||
402 | \luastring{\option{/witness/idno}}, | ||
403 | \luastring{\option{/witness/msName}}, | ||
404 | \luastring{\option{/witness/origDate}} | ||
405 | )} | ||
406 | \egroup} | ||
394 | } | 407 | } |
395 | \@onlypreamble\DeclareNewWitness | 408 | \@onlypreamble\DeclareNewWitness |
396 | \NewDocumentCommand{\DeclareNewHand}{m m m +O{}}{ | 409 | \NewDocumentCommand{\DeclareNewHand}{m m m +O{}}{ |