diff options
Diffstat (limited to 'Master/texmf-dist/tex/latex')
-rw-r--r-- | Master/texmf-dist/tex/latex/reledmac/reledmac.sty | 35 |
1 files changed, 27 insertions, 8 deletions
diff --git a/Master/texmf-dist/tex/latex/reledmac/reledmac.sty b/Master/texmf-dist/tex/latex/reledmac/reledmac.sty index bcbc5f2f06f..b2765feb369 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}[2017/05/04 v2.20.0 typesetting critical editions]% +\ProvidesPackage{reledmac}[2017/06/04 v2.21.0 typesetting critical editions]% \RequirePackage{xkeyval} \newif\ifparledgroup \DeclareOptionX{series}[A,B,C,D,E]{\xdef\default@series{#1}} @@ -1402,6 +1402,7 @@ \let\setline=\@gobble \let\advanceline=\@gobble \let\sameword\sameword@inedtext% \let\edtext=\dummy@edtext + \let\edindex\dummy@edindex% \l@dtabnoexpands \morenoexpands} \let\morenoexpands=\relax @@ -1533,11 +1534,14 @@ \newcommand{\l@d@add}[1]{\xdef\l@d@nums{\l@d@nums#1}} \newcommand{\get@sw@txt}[1]{% - \ifxetex% - \xdef\sw@txt{#1}% - \else% - \expandafter\xdef\expandafter\sw@txt\expandafter{\detokenize{#1}}% - \fi% + \begingroup% + \let\sameword\@firstofone%Allow to have nested \sameword + \ifxetex% + \xdef\sw@txt{#1}% + \else% + \expandafter\xdef\expandafter\sw@txt\expandafter{\detokenize{#1}}% + \fi% + \endgroup% }% \newcommandx{\sameword}[2][1,usedefault]{% \leavevmode% @@ -6400,9 +6404,23 @@ \newcommand{\ledinnotehyperpage}[2]{\csuse{#1}{\ledinnotemark{\hyperpage{#2}}}}% \newcommand{\ledinnotemark}[1]{#1\emph{n}}% \newcommandx{\@wredindex}[2][1=\expandonce\jobname,usedefault]{%#1 = the index name, #2 = the text + \begingroup% + \let\emph\@firstofone% + \let\textbf\@firstofone% + \let\textit\@firstofone% + \let\textmd\@firstofone% + \let\textnormal\@firstofone% + \let\textrm\@firstofone% + \let\textsc\@firstofone% + \let\textsf\@firstofone% + \let\textsl\@firstofone% + \let\texttt\@firstofone% + \let\textup\@firstofone% + \xdef\@tmp{#2}%To be used in IfSubStr instead of #2 directly. Avoid some expansion bugs (for example with \edindex{textsc{something}}) + \endgroup% \ifl@imakeidx% \ifnum\@edindex@fornote@>\z@% - \IfSubStr[1]{#2}{|}{\get@index@command#2+}{\get@index@command#2|+}% + \IfSubStr[1]{\@tmp}{|}{\get@index@command#2+}{\get@index@command#2|+}% \get@edindex@ledinnote@command% \expandafter\imki@wrindexentry{#1}{\@index@txt|(\@ledinnote@command}{\thestartpageline}% \expandafter\imki@wrindexentry{#1}{\@index@txt|)\@ledinnote@command}{\theendpageline}% @@ -6412,7 +6430,7 @@ \fi% \else% \ifnum\@edindex@fornote@>\z@% - \IfSubStr[1]{#2}{|}{\get@index@command#2+}{\get@index@command#2|+}% + \IfSubStr[1]{\@tmp}{|}{\get@index@command#2+}{\get@index@command#2|+}% \get@edindex@ledinnote@command% \expandafter\protected@write\@indexfile{}% {\string\indexentry{\@index@txt|(\@ledinnote@command}{\thestartpageline} @@ -6447,6 +6465,7 @@ {}% {\led@error@fail@patch@makeindex}% \newcommand{\edindex}[1]{\@bsphack\@esphack} +\newcommandx{\dummy@edindex}[2][1=\expandonce\jobname,usedefault]{}% \newcommand{\hyperlinkformat}[3]{% \ifstrempty{#1}% {\hyperlink{#2}{#3}}% |