aboutsummaryrefslogtreecommitdiff
diff options
context:
space:
mode:
-rw-r--r--ekdosis.dtx57
-rw-r--r--ekdosis.el2
2 files changed, 48 insertions, 11 deletions
diff --git a/ekdosis.dtx b/ekdosis.dtx
index 0eb0002..cde4586 100644
--- a/ekdosis.dtx
+++ b/ekdosis.dtx
@@ -61,7 +61,7 @@ along with this program. If not, see
61%<package>\NeedsTeXFormat{LaTeX2e}[1999/12/01] 61%<package>\NeedsTeXFormat{LaTeX2e}[1999/12/01]
62%<package>\ProvidesPackage{ekdosis} 62%<package>\ProvidesPackage{ekdosis}
63%<*package> 63%<*package>
64 [2021/08/31 v1.4-dev Typesetting TEI xml-compliant critical editions] 64 [2021/09/02 v1.4-dev Typesetting TEI xml-compliant critical editions]
65%</package> 65%</package>
66%<*driver> 66%<*driver>
67\begin{filecontents}[noheader,overwrite]{bibdata.xml} 67\begin{filecontents}[noheader,overwrite]{bibdata.xml}
@@ -4168,10 +4168,11 @@ argument of the
4168% instead of |\\|. 4168% instead of |\\|.
4169% \item |\\*| does the same as |\\| except that it prohibits a page 4169% \item |\\*| does the same as |\\| except that it prohibits a page
4170% break after the line. 4170% break after the line.
4171% \item |\\>| is for line breaks within a verse line. 4171% \item |\\>| \label{ref:vlinebreak-indent}is for line breaks within a
4172% \item |\\+| \newfeature[v1.4] does the same as |\\>| but without 4172% verse line.
4173% indenting the subsequent line which further complies to any already 4173% \item |\\+| \newfeature[v1.4] \label{ref:vlinebreak-noindent}does
4174% defined indent pattern. 4174% the same as |\\>| but without indenting the subsequent line which
4175% further complies to any already defined indent pattern.
4175% \end{enumerate} 4176% \end{enumerate}
4176% 4177%
4177% All of these commands can take a dimension as optional argument, 4178% All of these commands can take a dimension as optional argument,
@@ -4800,6 +4801,16 @@ substantiall fewell,}
4800% verse printed in the margin. If used without value, this option is 4801% verse printed in the margin. If used without value, this option is
4801% equivalent to |vmodulo=5|. |vmodulo=0| prevents the 4802% equivalent to |vmodulo=5|. |vmodulo=0| prevents the
4802% numbers from being printed.\\ 4803% numbers from being printed.\\
4804% \DescribeOption{vnumbrokenlines}
4805% |vnumbrokenlines|$=$\verb+true|false+ %
4806% \hfill\tcboxverb{Initially: false}\\
4807% \newfeature[v1.4] This named argument does not need a value as it
4808% defaults to |true| if used. |vnumbrokenlines| has both parts of lines
4809% broken by |\\>| or |\\+|\footnote{See above
4810% \vrefrange{ref:vlinebreak-indent}{ref:vlinebreak-noindent} for more
4811% information.} numbered with the same number for disambiguation
4812% purposes. By default, only the second part of broken lines is
4813% numbered.\\
4803% \DescribeOption{vmargin} |vmargin|$=$\verb+right|left+ 4814% \DescribeOption{vmargin} |vmargin|$=$\verb+right|left+
4804% \hfill\tcboxverb{Default: right}\\ 4815% \hfill\tcboxverb{Default: right}\\
4805% |vmargin| sets the margin in which the verse line numbers are to be 4816% |vmargin| sets the margin in which the verse line numbers are to be
@@ -4810,13 +4821,13 @@ substantiall fewell,}
4810% numbered continuously, irrespective of whether they are lines of 4821% numbered continuously, irrespective of whether they are lines of
4811% prose or poetry text. 4822% prose or poetry text.
4812% 4823%
4813%
4814% \paragraph{Useful Lineation Commands} 4824% \paragraph{Useful Lineation Commands}
4815% As implied above, pretty much all commands that are provided by the 4825% As implied above, pretty much all commands that are provided by the
4816% \enquote{running} mode of operation of the \pkg{lineno} package will 4826% \enquote{running} mode of operation of the \pkg{lineno} package will
4817% work with \pkg{ekdosis}, notably the following:---\\ 4827% work with \pkg{ekdosis}, notably the following:---\\
4818% \DescribeMacro{\modulolinenumbers} \cs{modulolinenumbers}\oarg{n} 4828% \DescribeMacro{\modulolinenumbers} \cs{modulolinenumbers}\oarg{n}
4819% can be used to enable modulo line numbering as described above.\\ 4829% can be used to enable or modify modulo line numbering as described
4830% above.\\
4820% \DescribeMacro{\resetlinenumber} \cs{resetlinenumber}\oarg{n} resets 4831% \DescribeMacro{\resetlinenumber} \cs{resetlinenumber}\oarg{n} resets
4821% the line number to one or to \emph{n} if specified.\\ 4832% the line number to one or to \emph{n} if specified.\\
4822% \DescribeMacro{\linenumberfont} 4833% \DescribeMacro{\linenumberfont}
@@ -4834,6 +4845,9 @@ substantiall fewell,}
4834% global option |poetry=verse| as described above in 4845% global option |poetry=verse| as described above in
4835% \vref{sec:verse-package}, the commands dedicated to line numbering 4846% \vref{sec:verse-package}, the commands dedicated to line numbering
4836% that are provided by the \pkg{verse} package can be used.\\ 4847% that are provided by the \pkg{verse} package can be used.\\
4848% \DescribeMacro{\vmodulolinenumbers} \newfeature[v1.4]
4849% \cs{vmodulolinenumbers}\oarg{n} can be used to enable or modify
4850% verse modulo line numbering as described above.\\
4837% \DescribeMacro{\resetvlinenumber} \cs{resetvlinenumber}\oarg{n} has 4851% \DescribeMacro{\resetvlinenumber} \cs{resetvlinenumber}\oarg{n} has
4838% for lines of verse the same effect as \cs{resetlinenumber} for 4852% for lines of verse the same effect as \cs{resetlinenumber} for
4839% lines of prose text.\\ 4853% lines of prose text.\\
@@ -8322,7 +8336,7 @@ Sample text with a \textcolor{red}{word} in red.
8322% \end{macrocode} 8336% \end{macrocode}
8323% \end{macro} 8337% \end{macro}
8324% \begin{macro}{\SetSubseparator} 8338% \begin{macro}{\SetSubseparator}
8325% \changes{v1.4}{2021/08/31}{New command for subseparators} 8339% \changes{v1.4}{2021/09/02}{New command for subseparators}
8326% \cs{SetSubseparator}\marg{sub-separator} allows to change the 8340% \cs{SetSubseparator}\marg{sub-separator} allows to change the
8327% \enquote{subseparator} between variant readings. By default, 8341% \enquote{subseparator} between variant readings. By default,
8328% no subseparator is set:--- 8342% no subseparator is set:---
@@ -8620,6 +8634,7 @@ Sample text with a \textcolor{red}{word} in red.
8620 \else\if@pkg@poetry@verse\poemlines{#1}\fi\fi, 8634 \else\if@pkg@poetry@verse\poemlines{#1}\fi\fi,
8621 initial vmodulo = 1, 8635 initial vmodulo = 1,
8622 default vmodulo = 5, 8636 default vmodulo = 5,
8637 bool vnumbrokenlines = \ifnum@brokenline,
8623 bool continuousvnum = \if@continuous@vnum, 8638 bool continuousvnum = \if@continuous@vnum,
8624 choice numbers = {elided = \ekd@elidednumberstrue, 8639 choice numbers = {elided = \ekd@elidednumberstrue,
8625 full = \ekd@elidednumbersfalse}, 8640 full = \ekd@elidednumbersfalse},
@@ -8651,6 +8666,22 @@ Sample text with a \textcolor{red}{word} in red.
8651} 8666}
8652% \end{macrocode} 8667% \end{macrocode}
8653% \end{macro} 8668% \end{macro}
8669% \begin{macro}{\vmodulolinenumbers}
8670% \changes{v1.4}{2021/09/02}{New command to adjust modulo verse line
8671% numbering}
8672% \begin{macrocode}
8673\NewDocumentCommand{\vmodulolinenumbers}{O{5}}{%
8674 \ifekd@memoir@loaded
8675 \linenumberfrequency{#1}%
8676 \else
8677 \if@pkg@poetry@verse
8678 \poemlines{#1}%
8679 \fi
8680 \fi
8681 \ignorespaces
8682}
8683% \end{macrocode}
8684% \end{macro}
8654% Use |\normalfont| for line numbers:--- 8685% Use |\normalfont| for line numbers:---
8655% \begin{macrocode} 8686% \begin{macrocode}
8656\renewcommand\linenumberfont{\normalfont\footnotesize} 8687\renewcommand\linenumberfont{\normalfont\footnotesize}
@@ -9897,7 +9928,7 @@ Sample text with a \textcolor{red}{word} in red.
9897% \end{macrocode} 9928% \end{macrocode}
9898% \end{macro} 9929% \end{macro}
9899% \begin{macro}{\\+} 9930% \begin{macro}{\\+}
9900% \changes{v1.4}{2021/08/31}{New macro for poetry} 9931% \changes{v1.4}{2021/09/02}{New macro for poetry}
9901% |\\+| comes in addition to the verse commands that are provided by 9932% |\\+| comes in addition to the verse commands that are provided by
9902% the \pkg{verse} package. |\\+| causes a linebreak within a verse 9933% the \pkg{verse} package. |\\+| causes a linebreak within a verse
9903% line. In contrast to |\\>|, the subsequent line is not indented and 9934% line. In contrast to |\\>|, the subsequent line is not indented and
@@ -9908,8 +9939,8 @@ Sample text with a \textcolor{red}{word} in red.
9908 {\newcommand{\@vsifplus}[1]{\@ifnextchar +{\@firstoftwo{#1}}} 9939 {\newcommand{\@vsifplus}[1]{\@ifnextchar +{\@firstoftwo{#1}}}
9909 \renewcommand{\@vscentercr}{% 9940 \renewcommand{\@vscentercr}{%
9910 \ifhmode \unskip\else \@nolnerr\fi 9941 \ifhmode \unskip\else \@nolnerr\fi
9911 \@vsifgt{\verselinebreak}{% 9942 \@vsifgt{\ifnum@brokenline\@vstypelinenum\fi\verselinebreak}{%
9912 \@vsifplus{\stepcounter{vslineno}% 9943 \@vsifplus{\ifnum@brokenline\@vstypelinenum\fi\stepcounter{vslineno}%
9913 \par\@ifstar{\nobreak\@vsxcentercr}{% 9944 \par\@ifstar{\nobreak\@vsxcentercr}{%
9914 \@vsifbang{\@ifnextchar[ {\@vsicentercr}{}}{\@vsxcentercr}% 9945 \@vsifbang{\@ifnextchar[ {\@vsicentercr}{}}{\@vsxcentercr}%
9915 }% 9946 }%
@@ -10463,6 +10494,10 @@ local cmdtotags = {
10463local texpatttotags = { 10494local texpatttotags = {
10464 {a="\\addentries%s+%[(.-)%]{(.-)}", b=""}, 10495 {a="\\addentries%s+%[(.-)%]{(.-)}", b=""},
10465 {a="\\addentries%s+{(.-)}", b=""}, 10496 {a="\\addentries%s+{(.-)}", b=""},
10497 {a="\\vmodulolinenumbers%s+%[(.-)%]", b=""},
10498 {a="\\vmodulolinenumbers%s+", b=""},
10499 {a="\\modulolinenumbers%s+%[(.-)%]", b=""},
10500 {a="\\modulolinenumbers%s+", b=""},
10466 {a="\\setverselinenums%s+{(.-)}{(.-)}", b=""}, 10501 {a="\\setverselinenums%s+{(.-)}{(.-)}", b=""},
10467 {a="\\resetvlinenumber%s+%[(.-)%]", b=""}, 10502 {a="\\resetvlinenumber%s+%[(.-)%]", b=""},
10468 {a="\\resetvlinenumber%s+", b=""}, 10503 {a="\\resetvlinenumber%s+", b=""},
diff --git a/ekdosis.el b/ekdosis.el
index 00037b2..69c14d1 100644
--- a/ekdosis.el
+++ b/ekdosis.el
@@ -202,6 +202,7 @@
202 ("numbers" ("elided" "full")) 202 ("numbers" ("elided" "full"))
203 ("vlineation" ("page" "document")) 203 ("vlineation" ("page" "document"))
204 ("vmodulo") 204 ("vmodulo")
205 ("vnumbrokenlines" ("true" "false"))
205 ("vmargin" ("right" "left")) 206 ("vmargin" ("right" "left"))
206 ("continuousvnum")) 207 ("continuousvnum"))
207 "List of local options for setlineation macro.") 208 "List of local options for setlineation macro.")
@@ -357,6 +358,7 @@
357 '("innerlinenumbers" 0) 358 '("innerlinenumbers" 0)
358 '("outerlinenumbers" 0) 359 '("outerlinenumbers" 0)
359 '("modulolinenumbers" [ "number" ] ) 360 '("modulolinenumbers" [ "number" ] )
361 '("vmodulolinenumbers" [ "number" ] )
360 '("resetlinenumber" [ "number" ] ) 362 '("resetlinenumber" [ "number" ] )
361 '("resetvlinenumber" [ "number" ] ) 363 '("resetvlinenumber" [ "number" ] )
362 '("verselinenumfont" "commands" 0) 364 '("verselinenumfont" "commands" 0)