diff options
Diffstat (limited to 'Master/texmf-dist/tex')
-rw-r--r-- | Master/texmf-dist/tex/latex/reledmac/reledmac.sty | 208 | ||||
-rw-r--r-- | Master/texmf-dist/tex/latex/reledmac/reledpar.sty | 21 |
2 files changed, 144 insertions, 85 deletions
diff --git a/Master/texmf-dist/tex/latex/reledmac/reledmac.sty b/Master/texmf-dist/tex/latex/reledmac/reledmac.sty index aa032a8b273..e9f22a65574 100644 --- a/Master/texmf-dist/tex/latex/reledmac/reledmac.sty +++ b/Master/texmf-dist/tex/latex/reledmac/reledmac.sty @@ -35,7 +35,7 @@ %% \NeedsTeXFormat{LaTeX2e} -\ProvidesPackage{reledmac}[2016/05/02 v2.9.3 typeset critical edition]% +\ProvidesPackage{reledmac}[2016/05/08 v2.10.0 typeset critical editions]% \RequirePackage{xkeyval} \newif\ifparledgroup \DeclareOptionX{series}[A,B,C,D,E]{\xdef\default@series{#1}} @@ -176,7 +176,8 @@ \reledmac@warning{Bad \string\setlinenum\space argument}} \newcommand*{\led@err@PstartNotNumbered}{% \reledmac@error{\string\pstart\space must be used within a - numbered section}{\@ehc}} + numbered section % + (\string\beginnumbering…\string\endnumbering)}{\@ehc}}% \newcommand*{\led@err@PstartInPstart}{% \reledmac@error{\string\pstart\space encountered while another \string\pstart\space was in effect}{\@ehc}} @@ -2093,6 +2094,7 @@ } \notbool{parapparatus@}{\newcommand*}{\newcommand}{\normalvfootnote}[2]{% + \csuse{Xbeforeinserting@#1}% \insert\csname #1footins\endcsname\bgroup \hsize=\expandafter\dimexpr\csuse{Xwidth@#1}\relax% \noindent\csuse{Xbhooknote@#1}% @@ -2120,20 +2122,9 @@ \hangindent=\csuse{Xhangindent@#4} \everypar{\hangindent=\csuse{Xhangindent@#4}}% \strut{\printlinefootnote{#1}{#4}}% - {\nottoggle{Xlemmadisablefontselection@#4}% - {\select@lemmafont#1|{\csuse{Xlemmafont@#4}#2}}% - {{\csuse{Xlemmafont@#4}#2}}% - }% - \iftoggle{nosep@}{% - \hskip\csuse{Xinplaceoflemmaseparator@#4}% - \relax% - }% - {\ifcsempty{Xlemmaseparator@#4}% - {\hskip\csuse{Xinplaceoflemmaseparator@#4}\relax}% - {\nobreak\hskip\csuse{Xbeforelemmaseparator@#4}\csuse{Xlemmaseparator@#4}\hskip\csuse{Xafterlemmaseparator@#4}% - \relax% - }}% - #3\strut\par} + \print@lemma{#1}{#2}{#4}% + \csuse{Xwrapcontent@#4}{#3}% + \strut\par} \newcommand*{\normalfootstart}[1]{% \ifdimequal{0pt}{\preXnotes@}{}% {% @@ -2238,6 +2229,7 @@ \let\bidi@RTL@everypar\@empty% \noindent\leavevmode} \newcommand*{\paravfootnote}[2]{% + \csuse{Xbeforeinserting@#1}% \insert\csname #1footins\endcsname \bgroup \csuse{Xnotefontsize@#1} @@ -2283,21 +2275,9 @@ \Xinsertparafootsep{#4}% \ledsetnormalparstuff@common% \printlinefootnote{#1}{#4}% - {\nottoggle{Xlemmadisablefontselection@#4}% - {\select@lemmafont#1|{\csuse{Xlemmafont@#4}#2}}% - {{\csuse{Xlemmafont@#4}#2}}% - }% - \iftoggle{nosep@}{% - \hskip\csuse{Xinplaceoflemmaseparator@#4}\relax% - }% - {\ifcsempty{Xlemmaseparator@#4}% - {% - \hskip\csuse{Xinplaceoflemmaseparator@#4}\relax% - }% - {\nobreak\hskip\csuse{Xbeforelemmaseparator@#4}\csuse{Xlemmaseparator@#4}\hskip\csuse{Xafterlemmaseparator@#4}% - \relax% - }}% - #3\penalty-10 } + \print@lemma{#1}{#2}{#4}% + \csuse{Xwrapcontent@#4}{#3}% + \penalty-10 } \newcommand*{\parafootgroup}[1]{% \hsize=\expandafter\dimexpr\csuse{Xwidth@#1}\relax% \unvbox\csname #1footins\endcsname @@ -2415,6 +2395,7 @@ \multiply\dimen\csname mp#1footins\endcsname \thr@@} \notbool{parapparatus@}{\newcommand*}{\newcommand}{\threecolvfootnote}[2]{% + \csuse{Xbeforeinserting@#1}% \insert\csname #1footins\endcsname\bgroup% \hsize=\expandafter\dimexpr\csuse{Xwidth@#1}\relax% \noindent\csuse{Xbhooknote@#1}% @@ -2434,20 +2415,10 @@ \strut{% \hspace{\parindent}% \printlinefootnote{#1}{#4}% - }% - {\nottoggle{Xlemmadisablefontselection@#4}% - {\select@lemmafont#1|{\csuse{Xlemmafont@#4}#2}}% - {{\csuse{Xlemmafont@#4}#2}}% }% - \iftoggle{nosep@}{% - \hskip\csuse{Xinplaceoflemmaseparator@#4}\relax% - }{% - \ifcsempty{Xlemmaseparator@#4}% - {\hskip\csuse{Xinplaceoflemmaseparator@#4}\relax}% - {\nobreak\hskip\csuse{Xbeforelemmaseparator@#4}\csuse{Xlemmaseparator@#4}\hskip\csuse{Xafterlemmaseparator@#4}% - \relax% - }}% - #3\strut\par\allowbreak} + \print@lemma{#1}{#2}{#4}% + \csuse{Xwrapcontent@#4}{#3}% + \strut\par\allowbreak} \newcommand*{\threecolfootgroup}[1]{{\csuse{Xnotefontsize@#1}% \noindent\csuse{Xtxtbeforenotes@#1}}% \csuse{Xbhookgroup@#1}\par% @@ -2502,6 +2473,7 @@ \csxdef{default@#1footins}{500}% \multiply\dimen\csname #1footins\endcsname \tw@} \notbool{parapparatus@}{\newcommand*}{\newcommand}{\twocolvfootnote}[2]{% + \csuse{Xbeforeinserting@#1}% \insert\csname #1footins\endcsname\bgroup% \hsize=\expandafter\dimexpr\csuse{Xwidth@#1}\relax% \noindent\csuse{Xbhooknote@#1}% @@ -2522,19 +2494,9 @@ \hspace{\parindent}% \printlinefootnote{#1}{#4}% }% - {\nottoggle{Xlemmadisablefontselection@#4}% - {\select@lemmafont#1|{\csuse{Xlemmafont@#4}#2}}% - {{\csuse{Xlemmafont@#4}#2}}% - }% - \iftoggle{nosep@}{% - \hskip\csuse{Xinplaceoflemmaseparator@#4}% - \relax% - }{\ifcsempty{Xlemmaseparator@#4}% - {\hskip\csuse{Xinplaceoflemmaseparator@#4}\relax}% - {\nobreak\hskip\csuse{Xbeforelemmaseparator@#4}\csuse{Xlemmaseparator@#4}\hskip\csuse{Xafterlemmaseparator@#4}% - \relax% - }}% - #3\strut\par\allowbreak} + \print@lemma{#1}{#2}{#4}% + \csuse{Xwrapcontent@#4}{#3}% + \strut\par\allowbreak} \newcommand*{\twocolfootgroup}[1]{{\csuse{Xnotefontsize@#1} \noindent\csuse{Xtxtbeforenotes@#1}}% \csuse{Xbhookgroup@#1}\par% @@ -2597,6 +2559,34 @@ \thepstart% }% } +\newcommand{\print@lemma}[3]{% + \bgroup% + \nottoggle{Xlemmadisablefontselection@#3}% + {\select@lemmafont#1|}% + {}% + \bgroup% + \csuse{Xlemmafont@#3}%Deprecated + \csuse{Xwraplemma@#3}{#2}% + \egroup% + \egroup% + \iftoggle{nosep@}{% + \hskip\csuse{Xinplaceoflemmaseparator@#3}% + \relax% + }% + {\ifcsempty{Xlemmaseparator@#3}% + {% + \hskip\csuse{Xinplaceoflemmaseparator@#3}% + \relax% + }% + {% + \nobreak% + \hskip\csuse{Xbeforelemmaseparator@#3}% + \csuse{Xlemmaseparator@#3}% + \hskip\csuse{Xafterlemmaseparator@#3}% + \relax% + }% + }% +}% \newcommand{\printlinefootnote}[2]{% \l@dp@rsefootspec#1|% \iftoggle{Xnumberonlyfirstintwolines@#2}{% @@ -3000,6 +2990,7 @@ \newcommand*{\normalbodyfootmarkX}[1]{% \hbox{\textsuperscript{\normalfont\@nameuse{@thefnmark#1}}}} \notbool{parapparatus@}{\newcommand*}{\newcommand}{\normalvfootnoteX}[2]{% + \csuse{beforeinsertingX@#1}% \insert\@nameuse{footins#1}\bgroup \hsize=\expandafter\dimexpr\csuse{widthX@#1}\relax% \noindent\csuse{bhooknoteX@#1}% @@ -3038,7 +3029,8 @@ \hangindent=\csuse{hangindentX@#1}% \everypar{\hangindent=\csuse{hangindentX@#1}}% {{\csuse{notenumfontX@#1}\wrapped@footfootmarkX{#1}}\strut% - #2\strut\par}} + \csuse{wrapcontentX@#1}{#2}% + \strut\par}} \newcommand*{\normalfootfootmarkX}[1]{% \textsuperscript{\@nameuse{@thefnmark#1}}} @@ -3218,6 +3210,7 @@ \multiply\dimen\csname mpfootins#1\endcsname by \tw@} \notbool{parapparatus@}{\newcommand*}{\newcommand}{\twocolvfootnoteX}[2]{% + \csuse{beforeinsertingX@#1}% \insert\csname footins#1\endcsname\bgroup% \hsize=\expandafter\dimexpr\csuse{widthX@#1}\relax% \noindent\csuse{bhooknoteX@#1}% @@ -3242,7 +3235,8 @@ \parindent=\@tempdima% {\hspace{\parindent}% \csuse{notenumfontX@#1}\wrapped@footfootmarkX{#1}\strut% - #2\strut\par}% + \csuse{wrapcontentX@#1}{#2}% + \strut\par}% \allowbreak% }% @@ -3302,6 +3296,7 @@ \multiply\dimen\csname mpfootins#1\endcsname by \thr@@} \notbool{parapparatus@}{\newcommand*}{\newcommand}{\threecolvfootnoteX}[2]{% + \csuse{beforeinsertingX@#1}% \insert\csname footins#1\endcsname\bgroup% \hsize=\expandafter\dimexpr\csuse{widthX@#1}\relax% \noindent\csuse{bhooknoteX@#1}% @@ -3324,7 +3319,8 @@ \parindent=\@tempdima% {\hspace{\parindent}% \csuse{notenumfontX@#1}\wrapped@footfootmarkX{#1}\strut% - #2\strut\par}\allowbreak} + \csuse{wrapcontentX@#1}{#2}% + \strut\par}\allowbreak} \newcommand*{\threecolfootgroupX}[1]{{\csuse{bhookgroupX@#1}\csuse{notefontsizeX@#1} \splittopskip=\ht\strutbox @@ -3411,6 +3407,7 @@ } \newcommand*{\para@vfootnoteX}[2]{% + \csuse{beforeinsertingX@#1}% \insert\csname footins#1\endcsname% \bgroup \csuse{notefontsizeX@#1} @@ -3464,7 +3461,8 @@ \csuse{notenumfontX@#1}% \wrapped@footfootmarkX{#1}% \strut% - #2\penalty-10}} + \csuse{wrapcontentX@#1}{#2}% + \penalty-10}} \newcommand*{\para@footgroupX}[1]{% \hsize=\expandafter\dimexpr\csuse{widthX@#1}\relax% @@ -3721,8 +3719,12 @@ \undef\@this@crossref@start% \undef\@this@crossref@end% \nottoggle{Xendlemmadisablefontselection@#4}% - {\select@lemmafont#1|{\csuse{Xendlemmafont@#4}#2}}% - {{\csuse{Xendlemmafont@#4}#2}}% + {\select@lemmafont#1|}% + {}% + \bgroup% + \csuse{Xendlemmafont@#4}% + \csuse{Xendwraplemma@#4}{#2}% + \egroup% \ifboolexpr{% togl {nosep@}% or test{\ifcsempty{Xendlemmaseparator@#4}}% @@ -3734,7 +3736,7 @@ \hskip\csuse{Xendafterlemmaseparator@#4}% \relax% }% - #3% + \csuse{Xendwrapcontent@#4}{#3}% \nottoggle{Xendparagraph@#4}{\par}{}% \def\do##1{% \setkeys[mac]{falsefootnoteoption}{##1}% @@ -3966,6 +3968,8 @@ \newtoggle{Xlineflag@#1} \newtoggle{Xparindent@#1} \newtoggle{Xlemmadisablefontselection@#1} + \csgdef{Xwrapcontent@#1}{}% + \csgdef{Xbeforeinserting@#1}{}% \csgdef{Xhangindent@#1}{0pt}% \csgdef{Xragged@#1}{}% \csgdef{Xhsizetwocol@#1}{0.45 \hsize}% @@ -4018,6 +4022,7 @@ \csgdef{Xlinerangeseparator@#1}{\endashchar}% \csgdef{Xlemmafont@#1}{}% + \csgdef{Xwraplemma@#1}{} \csgdef{Xwidth@#1}{\hsize}% \expandafter\newinsert\csname #1footins\endcsname% \unless\ifnoledgroup@% @@ -4118,7 +4123,9 @@ \fi \unless\ifnofamiliar@ \newtoggle{parindentX@#1} + \csgdef{wrapcontentX@#1}{}% \csgdef{hangindentX@#1}{0pt}% + \csgdef{beforeinsertingX@#1}{}% \csgdef{raggedX@#1}{}% \csgdef{hsizetwocolX@#1}{0.45 \hsize}% \csgdef{hsizethreecolX@#1}{.3 \hsize}% @@ -4203,6 +4210,8 @@ \global\cslet{#1end}{\@gobblefive} \global\expandafter\newcount\csname #1end@bysection\endcsname% + \csgdef{Xendwraplemma@#1}{} + \csgdef{Xendwrapcontent@#1}{}% \csgdef{Xendtwolines@#1}{}% \csgdef{Xendmorethantwolines@#1}{}% \newtoggle{Xendtwolinesbutnotmore@#1}{}% @@ -4365,7 +4374,10 @@ }% } \unless\ifnocritical@ + \newhookcommand@series{Xwrapcontent}% + \newhookcommand@series{Xbeforeinserting}% \newhookcommand@series{Xlemmafont}% + \newhookcommand@series{Xwraplemma}% \newhooktoggle@series{Xparindent} \newhookcommand@series{Xhangindent} \newhookcommand@series{Xragged} @@ -4434,6 +4446,8 @@ \newhooktoggle@series{Xtwolinesonlyinsamepage}[appref,SEref] \newhookcommand@series{Xlinerangeseparator}[appref,SEref] \unless\ifnofamiliar@ + \newhookcommand@series{wrapcontentX}% + \newhookcommand@series{beforeinsertingX}% \newhooktoggle@series{parindentX} \newhookcommand@series{hangindentX} \newhookcommand@series{raggedX} @@ -4461,6 +4475,8 @@ {}% \fi \unless\ifnoend@ + \newhookcommand@series{Xendwraplemma} + \newhookcommand@series{Xendwrapcontent} \newhookcommand@series{Xendnotenumfont} \newhookcommand@series{Xendlemmafont}% \newhookcommand@series{Xendbhooknote} @@ -5279,21 +5295,30 @@ \newcommand*{\vl@dcsnote}[1]{\listgadd{\l@dcsnotetext}{#1}} \newcommand*{\setl@dlp@rbox}[1]{% - {\parindent\z@\hsize=\ledlsnotewidth\ledlsnotefontsetup - \global\setbox\l@dlp@rbox - \ifleftnoteup - =\vbox to\z@{\vss #1}% - \else - =\vbox to 0.70\baselineskip{\strut#1\vss}% - \fi}} + \begingroup% + \parindent\z@\hsize=\ledlsnotewidth% + \ledlsnotefontsetup%We kept it outside of the vbox, because can affect the ragging + \global\setbox\l@dlp@rbox% + \ifleftnoteup% + =\vbox to\z@{{\ledlsnotefontsetup\vss #1}}%We put \ledlsnotefontsetup inside footnote because required for color command. Note the {} to kept setting local. + \else% + =\vbox to 0.70\baselineskip{{\ledlsnotefontsetup\strut#1\vss}}% + \fi% + \endgroup% +} + \newcommand*{\setl@drp@rbox}[1]{% - {\parindent\z@\hsize=\ledrsnotewidth\ledrsnotefontsetup - \global\setbox\l@drp@rbox - \ifrightnoteup - =\vbox to\z@{\vss#1}% - \else - =\vbox to0.7\baselineskip{\strut#1\vss}% - \fi}} + \begingroup% + \parindent\z@\hsize=\ledrsnotewidth% + \ledrsnotefontsetup%We kept it outside of the vbox, because can affect the ragging + \global\setbox\l@drp@rbox% + \ifrightnoteup% + =\vbox to\z@{{\ledrsnotefontsetup\vss#1}}%We put \ledrsnotefontsetup inside footnote because required for color command. Note the {} to kept setting local. + \else% + =\vbox to0.7\baselineskip{{\ledrsnotefontsetup\strut#1\vss}}% + \fi% + \endgroup% +}% \newif\ifleftnoteup \leftnoteuptrue \newcommand{\setsidenotesep}[1]{\gdef\@sidenotesep{#1}} @@ -5928,20 +5953,41 @@ \noexpand\newverse[][]}% \def\noexpand\&{\noexpand\@stopstanza}% \noexpand\@advancestanzanumber% - \noexpand\stanza@line[#1]\noexpand\@insertstanzanumber% + \noexpand\stanza@line[#1]% + \noexpand\@insertstanzanumber% \let\par\relax\ignorespaces%No paragraph in verses } -\newcommandx{\stanza}[1][1,usedefault]{\@startstanza[#1]} +\newcommandx{\stanza}[1][1,usedefault]{% + \ifboolexpr{not test{\ifdefvoid{\at@every@stanza}} and test{\ifstrempty{#1}}}% + {\@startstanza[\at@every@stanza]}% + {\@startstanza[#1]}% +}% \newcommandx{\@stopstanza}[1][1,usedefault]{% \unskip% \endlock% - \pend[#1]% + \ifboolexpr{not test{\ifdefvoid{\at@every@stop@stanza}} and test{\ifstrempty{#1}}}% + {\pend[\at@every@stop@stanza]}% + {\pend[#1]}% \endgroup% \instanzafalse% } +\newcommand{\AtEveryStopStanza}[1]{% + \ifstrempty{#1}% + {\xdef\at@every@stop@stanza{}}% + {\gdef\at@every@stop@stanza{#1}}% +}% +\def\at@every@stop@stanza{}% + +\newcommand{\AtEveryStanza}[1]{% + \ifstrempty{#1}% + {\xdef\at@every@stanza{}}% + {\gdef\at@every@stanza{#1}}% +}% +\def\at@every@stanza{}% + \newcommandx*{\newverse}[2][1,2,usedefault]{% \unskip% \endlock\pend[#1]\sza@penalty\global% diff --git a/Master/texmf-dist/tex/latex/reledmac/reledpar.sty b/Master/texmf-dist/tex/latex/reledmac/reledpar.sty index 438858dee0c..15719b6d6d2 100644 --- a/Master/texmf-dist/tex/latex/reledmac/reledpar.sty +++ b/Master/texmf-dist/tex/latex/reledmac/reledpar.sty @@ -29,7 +29,7 @@ \NeedsTeXFormat{LaTeX2e} -\ProvidesPackage{reledpar}[2016/03/23 v2.8.0 reledmac extension for parallel texts]% +\ProvidesPackage{reledpar}[2016/05/08 v2.9.0 reledmac extension for parallel texts]% \RequirePackage{xspace}% \RequirePackage{xkeyval} @@ -122,6 +122,9 @@ Such behavior is deprecated.\MessageBreak% Use instead #1R or #1* in your preamble.}% } +\newcommand{\led@error@missing@numbering}[1]{% + \reledpar@error{Missing \string\pstart…\string\pend\space inside `#1` environment}{\@ehc}% +}% \newcount\section@numR \section@numR=\z@ \pst@rtedLfalse @@ -758,6 +761,9 @@ \let\old@startstanza\@startstanza \def\@startstanza[##1]{\global\instanzaLtrue\old@startstanza[##1]} }{ + \expandafter\ifvoid\csname l@dLcolrawbox1\endcsname% + \led@error@missing@numbering{Leftside}% + \fi% \Leftsidehookend} \newcommand*{\Leftsidehook}{} \newcommand*{\Leftsidehookend}{} @@ -785,6 +791,9 @@ \def\@startstanza[##1]{\global\instanzaRtrue\old@startstanza[##1]} }{% \ledRcolfalse + \expandafter\ifvoid\csname l@dRcolrawbox1\endcsname% + \led@error@missing@numbering{Rightside}% + \fi% \Rightsidehookend } @@ -1687,14 +1696,18 @@ \global\advance\stanza@count\@ne \@astanza@line}% \def\&{\@stopastanza}% - \pstart[#1]% + \ifboolexpr{not test{\ifdefvoid{\at@every@stanza}} and test{\ifstrempty{#1}}}% + {\pstart[\at@every@stanza]}% + {\pstart[#1]}% \@astanza@line \let\par\relax\ignorespaces%No paragraph in verses }{} \newcommandx{\@stopastanza}[1][1,usedefault]{% - \endlock\mbox{}% - \pend[#1]% + \endlock\mbox{}% + \ifboolexpr{not test{\ifdefvoid{\at@every@stop@stanza}} and test{\ifstrempty{#1}}}% + {\pend[\at@every@stop@stanza]}% + {\pend[#1]}% }% \newcommand*{\@astanza@line}{% \ifnum\value{stanzaindentsrepetition}=0 |