aboutsummaryrefslogtreecommitdiff
diff options
context:
space:
mode:
-rw-r--r--ekdosis.dtx42
1 files changed, 29 insertions, 13 deletions
diff --git a/ekdosis.dtx b/ekdosis.dtx
index fb405b1..d17774b 100644
--- a/ekdosis.dtx
+++ b/ekdosis.dtx
@@ -369,6 +369,17 @@ Running "make install" installs the files in the local TeX tree.
369 \luadirect{ekdosis.closestream()} 369 \luadirect{ekdosis.closestream()}
370} 370}
371% \end{macrocode} 371% \end{macrocode}
372% Hooks
373% \begin{macrocode}
374\def\ekd@postrefnum{\nobreak\space}
375\options{
376 /hooks/.new family,
377 /hooks/postrefnum/.new cmd = \def\ekd@postrefnum{#1}
378}
379\NewDocumentCommand{\SetEkdosisHooks}{m}{
380 \options{/hooks,#1}
381}
382% \end{macrocode}
372% Build and process the list of witnesses and hands. 383% Build and process the list of witnesses and hands.
373% \begin{macrocode} 384% \begin{macrocode}
374\options{ 385\options{
@@ -656,10 +667,10 @@ Running "make install" installs the files in the local TeX tree.
656 = 667 =
657 \getrefnumber{\luadirect{tex.sprint(ekdosis.getprevnotelab())}} 668 \getrefnumber{\luadirect{tex.sprint(ekdosis.getprevnotelab())}}
658 \else 669 \else
659 \getrefnumber{#1}% 670 \getrefnumber{#1}\unexpanded\expandafter{\ekd@postrefnum}%
660 \fi% 671 \fi%
661 }% 672 }%
662 {\getrefnumber{#1}}% 673 {\getrefnumber{#1}\unexpanded\expandafter{\ekd@postrefnum}}%
663 \else 674 \else
664 \ifsubsq@unit% 675 \ifsubsq@unit%
665 % 676 %
@@ -668,22 +679,22 @@ Running "make install" installs the files in the local TeX tree.
668 = 679 =
669 \getrefnumber{\luadirect{tex.sprint(ekdosis.getprevnotelab())}} 680 \getrefnumber{\luadirect{tex.sprint(ekdosis.getprevnotelab())}}
670 \else 681 \else
671 \getrefnumber{#1}% 682 \getrefnumber{#1}\unexpanded\expandafter{\ekd@postrefnum}%
672 \fi 683 \fi
673 % 684 %
674 \else 685 \else
675 \getrefnumber{#1}% 686 \getrefnumber{#1}\unexpanded\expandafter{\ekd@postrefnum}%
676 \fi 687 \fi
677 \fi 688 \fi
678 % 689 %
679 \else 690 \else
680 \getrefnumber{#1}--% 691 \getrefnumber{#1}--%
681 \getrefnumber{#2}% 692 \getrefnumber{#2}\unexpanded\expandafter{\ekd@postrefnum}%
682 \fi% 693 \fi%
683 \else 694 \else
684 \getrefnumber{#1}--% 695 \getrefnumber{#1}--%
685 \getpagerefnumber{#2}.% 696 \getpagerefnumber{#2}.%
686 \getrefnumber{#2}% 697 \getrefnumber{#2}\unexpanded\expandafter{\ekd@postrefnum}%
687 \fi% 698 \fi%
688 }% 699 }%
689 }% 700 }%
@@ -705,8 +716,10 @@ Running "make install" installs the files in the local TeX tree.
705 \getrefnumber{\luadirect{tex.sprint(ekdosis.getprevlnlab())}-b} 716 \getrefnumber{\luadirect{tex.sprint(ekdosis.getprevlnlab())}-b}
706 \else 717 \else
707 \getrefnumber{\luadirect{tex.sprint(ekdosis.getlnlab())}-b}% 718 \getrefnumber{\luadirect{tex.sprint(ekdosis.getlnlab())}-b}%
719 \unexpanded\expandafter{\ekd@postrefnum}%
708 \fi% 720 \fi%
709 }{\getrefnumber{\luadirect{tex.sprint(ekdosis.getlnlab())}-b}}% 721 }{\getrefnumber{\luadirect{tex.sprint(ekdosis.getlnlab())}-b}%
722 \unexpanded\expandafter{\ekd@postrefnum}}%
710 \else 723 \else
711 \ifsubsq@unit% 724 \ifsubsq@unit%
712 % 725 %
@@ -716,25 +729,28 @@ Running "make install" installs the files in the local TeX tree.
716 \getrefnumber{\luadirect{tex.sprint(ekdosis.getprevlnlab())}-b} 729 \getrefnumber{\luadirect{tex.sprint(ekdosis.getprevlnlab())}-b}
717 \else 730 \else
718 \getrefnumber{\luadirect{tex.sprint(ekdosis.getlnlab())}-b}% 731 \getrefnumber{\luadirect{tex.sprint(ekdosis.getlnlab())}-b}%
732 \unexpanded\expandafter{\ekd@postrefnum}%
719 \fi 733 \fi
720 % 734 %
721 \else 735 \else
722 \getrefnumber{\luadirect{tex.sprint(ekdosis.getlnlab())}-b}% 736 \getrefnumber{\luadirect{tex.sprint(ekdosis.getlnlab())}-b}%
737 \unexpanded\expandafter{\ekd@postrefnum}%
723 \fi 738 \fi
724 \fi 739 \fi
725 % 740 %
726 \else 741 \else
727 \getrefnumber{\luadirect{tex.sprint(ekdosis.getlnlab())}-b}--% 742 \getrefnumber{\luadirect{tex.sprint(ekdosis.getlnlab())}-b}--%
728 \getrefnumber{\luadirect{tex.sprint(ekdosis.getlnlab())}-e}% 743 \getrefnumber{\luadirect{tex.sprint(ekdosis.getlnlab())}-e}%
744 \unexpanded\expandafter{\ekd@postrefnum}%
729 \fi% 745 \fi%
730 \else 746 \else
731 \getrefnumber{\luadirect{tex.sprint(ekdosis.getlnlab())}-b}--% 747 \getrefnumber{\luadirect{tex.sprint(ekdosis.getlnlab())}-b}--%
732 \getpagerefnumber{\luadirect{tex.sprint(ekdosis.getlnlab())}-e}.% 748 \getpagerefnumber{\luadirect{tex.sprint(ekdosis.getlnlab())}-e}.%
733 \getrefnumber{\luadirect{tex.sprint(ekdosis.getlnlab())}-e}% 749 \getrefnumber{\luadirect{tex.sprint(ekdosis.getlnlab())}-e}%
750 \unexpanded\expandafter{\ekd@postrefnum}%
734 \fi% 751 \fi%
735 }% 752 }%
736 }% 753 }%
737\protected\def\nbsp{\nobreak\space}
738\define@cmdkeys[ekd]{lemrdg}[ekdlr@]{wit, alt, pre, post, prewit, 754\define@cmdkeys[ekd]{lemrdg}[ekdlr@]{wit, alt, pre, post, prewit,
739 postwit} 755 postwit}
740\define@cmdkey[ekd]{lem}[ekdl@]{sep}{} 756\define@cmdkey[ekd]{lem}[ekdl@]{sep}{}
@@ -764,7 +780,7 @@ Running "make install" installs the files in the local TeX tree.
764 \else% 780 \else%
765 \ifsubsq@unit\unexpanded\expandafter{\ekd@unit@delim}\fi% 781 \ifsubsq@unit\unexpanded\expandafter{\ekd@unit@delim}\fi%
766 \fi% 782 \fi%
767 \current@ref\nbsp}%\hskip .25em}% 783 \current@ref}%\hskip .25em}%
768 \else% 784 \else%
769 \ifbool{al@rlmode}{% 785 \ifbool{al@rlmode}{%
770 \edef\lem@app{% 786 \edef\lem@app{%
@@ -775,7 +791,7 @@ Running "make install" installs the files in the local TeX tree.
775 \else% 791 \else%
776 \ifsubsq@unit\unexpanded\expandafter{\ekd@unit@delim}\fi% 792 \ifsubsq@unit\unexpanded\expandafter{\ekd@unit@delim}\fi%
777 \fi% 793 \fi%
778 \current@ref\nbsp%\hskip .25em 794 \current@ref%\hskip .25em
779 \ifdefined\ekdlr@alt% 795 \ifdefined\ekdlr@alt%
780 \ifdefined\ekdlr@post% 796 \ifdefined\ekdlr@post%
781 \space\unexpanded\expandafter{\ekdlr@post}\space\else\fi 797 \space\unexpanded\expandafter{\ekdlr@post}\space\else\fi
@@ -806,7 +822,7 @@ Running "make install" installs the files in the local TeX tree.
806 \else% 822 \else%
807 \ifsubsq@unit\unexpanded\expandafter{\ekd@unit@delim}\fi% 823 \ifsubsq@unit\unexpanded\expandafter{\ekd@unit@delim}\fi%
808 \fi% 824 \fi%
809 \current@ref\nbsp%\hskip .25em 825 \current@ref%\hskip .25em
810 \ifdefined\ekdlr@alt% 826 \ifdefined\ekdlr@alt%
811 \ifdefined\ekdlr@pre% 827 \ifdefined\ekdlr@pre%
812 \space\unexpanded\expandafter{\ekdlr@pre}\space\else\fi 828 \space\unexpanded\expandafter{\ekdlr@pre}\space\else\fi
@@ -952,7 +968,7 @@ Running "make install" installs the files in the local TeX tree.
952 \else% 968 \else%
953 \ifsubsq@unit\unexpanded\expandafter{\ekd@unit@delim}\fi% 969 \ifsubsq@unit\unexpanded\expandafter{\ekd@unit@delim}\fi%
954 \fi% 970 \fi%
955 \current@ref@arg{\ekdn@labelb}{\ekdn@labele}\nbsp%\hskip .25em 971 \current@ref@arg{\ekdn@labelb}{\ekdn@labele}%\hskip .25em
956 \ifdefined\ekdn@lem% 972 \ifdefined\ekdn@lem%
957 {\textdir TRT\unexpanded\expandafter{\ekdn@lem}}% 973 {\textdir TRT\unexpanded\expandafter{\ekdn@lem}}%
958 \unexpanded\expandafter{\ekdn@sep}\else\fi% 974 \unexpanded\expandafter{\ekdn@sep}\else\fi%
@@ -965,7 +981,7 @@ Running "make install" installs the files in the local TeX tree.
965 \else% 981 \else%
966 \ifsubsq@unit\unexpanded\expandafter{\ekd@unit@delim}\fi% 982 \ifsubsq@unit\unexpanded\expandafter{\ekd@unit@delim}\fi%
967 \fi% 983 \fi%
968 \current@ref@arg{\ekdn@labelb}{\ekdn@labele}\nbsp%\hskip .25em 984 \current@ref@arg{\ekdn@labelb}{\ekdn@labele}%\hskip .25em
969 \ifdefined\ekdn@lem 985 \ifdefined\ekdn@lem
970 \ltx@ifpackageloaded{babel}% 986 \ltx@ifpackageloaded{babel}%
971 {\noexpand\selectlanguage{\languagename}% 987 {\noexpand\selectlanguage{\languagename}%