summaryrefslogtreecommitdiff
diff options
context:
space:
mode:
-rw-r--r--Master/texmf-dist/doc/latex/eledmac/README2
-rw-r--r--Master/texmf-dist/doc/latex/eledmac/eledmac.pdfbin970975 -> 974720 bytes
-rw-r--r--Master/texmf-dist/doc/latex/eledmac/eledpar.pdfbin515215 -> 515288 bytes
-rw-r--r--Master/texmf-dist/doc/latex/eledmac/examples/columns-alignment.pdfbin21170 -> 21174 bytes
-rw-r--r--Master/texmf-dist/doc/latex/eledmac/examples/cross-referencing.pdfbin16310 -> 16306 bytes
-rw-r--r--Master/texmf-dist/doc/latex/eledmac/examples/indexing.pdfbin19897 -> 19900 bytes
-rw-r--r--Master/texmf-dist/doc/latex/eledmac/examples/line-numbers-in-header.pdfbin31548 -> 31550 bytes
-rw-r--r--Master/texmf-dist/doc/latex/eledmac/examples/minimal-parallels.pdfbin12221 -> 12222 bytes
-rw-r--r--Master/texmf-dist/doc/latex/eledmac/examples/minimal-verses.pdfbin17126 -> 17125 bytes
-rw-r--r--Master/texmf-dist/doc/latex/eledmac/examples/mixing-columns-and-not-columns.pdfbin18786 -> 18785 bytes
-rw-r--r--Master/texmf-dist/doc/latex/eledmac/examples/parallel-column-two-languages.pdfbin24632 -> 24634 bytes
-rw-r--r--Master/texmf-dist/doc/latex/eledmac/examples/sections-not-in-line-numbering.pdfbin17148 -> 17149 bytes
-rw-r--r--Master/texmf-dist/doc/latex/eledmac/examples/sections-parallel-not-in-line-numbering.pdfbin22223 -> 22223 bytes
-rw-r--r--Master/texmf-dist/doc/latex/eledmac/examples/sections-with-critical-notes-in-parallel-columns.pdfbin29131 -> 29130 bytes
-rw-r--r--Master/texmf-dist/doc/latex/eledmac/examples/sections-with-critical-notes-in-parallel-pages.pdfbin31727 -> 31730 bytes
-rw-r--r--Master/texmf-dist/doc/latex/eledmac/examples/sections-with-critical-notes.pdfbin22794 -> 22790 bytes
-rw-r--r--Master/texmf-dist/doc/latex/eledmac/examples/side-notes.pdfbin20230 -> 20343 bytes
-rw-r--r--Master/texmf-dist/doc/latex/eledmac/examples/spaces-around-footnote-rule.pdfbin20873 -> 20872 bytes
-rw-r--r--Master/texmf-dist/doc/latex/eledmac/examples/tabular.pdfbin20793 -> 20796 bytes
-rw-r--r--Master/texmf-dist/doc/latex/eledmac/examples/text-between-verses-in-parallel.pdfbin16240 -> 16239 bytes
-rw-r--r--Master/texmf-dist/source/latex/eledmac/eledmac.dtx273
-rw-r--r--Master/texmf-dist/tex/latex/eledmac/eledmac.sty122
22 files changed, 209 insertions, 188 deletions
diff --git a/Master/texmf-dist/doc/latex/eledmac/README b/Master/texmf-dist/doc/latex/eledmac/README
index fa8cb6f4851..500c5f11a18 100644
--- a/Master/texmf-dist/doc/latex/eledmac/README
+++ b/Master/texmf-dist/doc/latex/eledmac/README
@@ -112,9 +112,7 @@ please follow these rules:
- Go to [the project page](https://github.com/maieul/ledmac/).
- Choose the correct branch in the "branch" menu.
- Click on the cloud, in the right side.
-
- Run the `.ins` files with pdflatex, to obtain the `.sty` files.
- Put the `.sty` files with your test files (in the same folder).
- Make your report.
-
diff --git a/Master/texmf-dist/doc/latex/eledmac/eledmac.pdf b/Master/texmf-dist/doc/latex/eledmac/eledmac.pdf
index 49658b09b09..ef0178b8bdc 100644
--- a/Master/texmf-dist/doc/latex/eledmac/eledmac.pdf
+++ b/Master/texmf-dist/doc/latex/eledmac/eledmac.pdf
Binary files differ
diff --git a/Master/texmf-dist/doc/latex/eledmac/eledpar.pdf b/Master/texmf-dist/doc/latex/eledmac/eledpar.pdf
index 854d2afd094..0419d12853a 100644
--- a/Master/texmf-dist/doc/latex/eledmac/eledpar.pdf
+++ b/Master/texmf-dist/doc/latex/eledmac/eledpar.pdf
Binary files differ
diff --git a/Master/texmf-dist/doc/latex/eledmac/examples/columns-alignment.pdf b/Master/texmf-dist/doc/latex/eledmac/examples/columns-alignment.pdf
index 6411394545e..3d334b5607e 100644
--- a/Master/texmf-dist/doc/latex/eledmac/examples/columns-alignment.pdf
+++ b/Master/texmf-dist/doc/latex/eledmac/examples/columns-alignment.pdf
Binary files differ
diff --git a/Master/texmf-dist/doc/latex/eledmac/examples/cross-referencing.pdf b/Master/texmf-dist/doc/latex/eledmac/examples/cross-referencing.pdf
index 368c12d4dd9..b3fb19eb409 100644
--- a/Master/texmf-dist/doc/latex/eledmac/examples/cross-referencing.pdf
+++ b/Master/texmf-dist/doc/latex/eledmac/examples/cross-referencing.pdf
Binary files differ
diff --git a/Master/texmf-dist/doc/latex/eledmac/examples/indexing.pdf b/Master/texmf-dist/doc/latex/eledmac/examples/indexing.pdf
index cd394c227af..989311d7593 100644
--- a/Master/texmf-dist/doc/latex/eledmac/examples/indexing.pdf
+++ b/Master/texmf-dist/doc/latex/eledmac/examples/indexing.pdf
Binary files differ
diff --git a/Master/texmf-dist/doc/latex/eledmac/examples/line-numbers-in-header.pdf b/Master/texmf-dist/doc/latex/eledmac/examples/line-numbers-in-header.pdf
index 485c93a3c58..db5cec683ab 100644
--- a/Master/texmf-dist/doc/latex/eledmac/examples/line-numbers-in-header.pdf
+++ b/Master/texmf-dist/doc/latex/eledmac/examples/line-numbers-in-header.pdf
Binary files differ
diff --git a/Master/texmf-dist/doc/latex/eledmac/examples/minimal-parallels.pdf b/Master/texmf-dist/doc/latex/eledmac/examples/minimal-parallels.pdf
index a082b24cb26..f9f02c362af 100644
--- a/Master/texmf-dist/doc/latex/eledmac/examples/minimal-parallels.pdf
+++ b/Master/texmf-dist/doc/latex/eledmac/examples/minimal-parallels.pdf
Binary files differ
diff --git a/Master/texmf-dist/doc/latex/eledmac/examples/minimal-verses.pdf b/Master/texmf-dist/doc/latex/eledmac/examples/minimal-verses.pdf
index 4be905124a1..83f5d9c584b 100644
--- a/Master/texmf-dist/doc/latex/eledmac/examples/minimal-verses.pdf
+++ b/Master/texmf-dist/doc/latex/eledmac/examples/minimal-verses.pdf
Binary files differ
diff --git a/Master/texmf-dist/doc/latex/eledmac/examples/mixing-columns-and-not-columns.pdf b/Master/texmf-dist/doc/latex/eledmac/examples/mixing-columns-and-not-columns.pdf
index 9cdba1b449c..a228aec8bb1 100644
--- a/Master/texmf-dist/doc/latex/eledmac/examples/mixing-columns-and-not-columns.pdf
+++ b/Master/texmf-dist/doc/latex/eledmac/examples/mixing-columns-and-not-columns.pdf
Binary files differ
diff --git a/Master/texmf-dist/doc/latex/eledmac/examples/parallel-column-two-languages.pdf b/Master/texmf-dist/doc/latex/eledmac/examples/parallel-column-two-languages.pdf
index 4722757d461..ed6b38b2027 100644
--- a/Master/texmf-dist/doc/latex/eledmac/examples/parallel-column-two-languages.pdf
+++ b/Master/texmf-dist/doc/latex/eledmac/examples/parallel-column-two-languages.pdf
Binary files differ
diff --git a/Master/texmf-dist/doc/latex/eledmac/examples/sections-not-in-line-numbering.pdf b/Master/texmf-dist/doc/latex/eledmac/examples/sections-not-in-line-numbering.pdf
index 1062c95a8c0..b43ec73ae03 100644
--- a/Master/texmf-dist/doc/latex/eledmac/examples/sections-not-in-line-numbering.pdf
+++ b/Master/texmf-dist/doc/latex/eledmac/examples/sections-not-in-line-numbering.pdf
Binary files differ
diff --git a/Master/texmf-dist/doc/latex/eledmac/examples/sections-parallel-not-in-line-numbering.pdf b/Master/texmf-dist/doc/latex/eledmac/examples/sections-parallel-not-in-line-numbering.pdf
index 9c946e5f4db..a2e7d27e9fe 100644
--- a/Master/texmf-dist/doc/latex/eledmac/examples/sections-parallel-not-in-line-numbering.pdf
+++ b/Master/texmf-dist/doc/latex/eledmac/examples/sections-parallel-not-in-line-numbering.pdf
Binary files differ
diff --git a/Master/texmf-dist/doc/latex/eledmac/examples/sections-with-critical-notes-in-parallel-columns.pdf b/Master/texmf-dist/doc/latex/eledmac/examples/sections-with-critical-notes-in-parallel-columns.pdf
index 2914b76e814..0e9b0da1f67 100644
--- a/Master/texmf-dist/doc/latex/eledmac/examples/sections-with-critical-notes-in-parallel-columns.pdf
+++ b/Master/texmf-dist/doc/latex/eledmac/examples/sections-with-critical-notes-in-parallel-columns.pdf
Binary files differ
diff --git a/Master/texmf-dist/doc/latex/eledmac/examples/sections-with-critical-notes-in-parallel-pages.pdf b/Master/texmf-dist/doc/latex/eledmac/examples/sections-with-critical-notes-in-parallel-pages.pdf
index 1f6b36d9224..3176fed43ab 100644
--- a/Master/texmf-dist/doc/latex/eledmac/examples/sections-with-critical-notes-in-parallel-pages.pdf
+++ b/Master/texmf-dist/doc/latex/eledmac/examples/sections-with-critical-notes-in-parallel-pages.pdf
Binary files differ
diff --git a/Master/texmf-dist/doc/latex/eledmac/examples/sections-with-critical-notes.pdf b/Master/texmf-dist/doc/latex/eledmac/examples/sections-with-critical-notes.pdf
index b277919424d..3b3292e8cfb 100644
--- a/Master/texmf-dist/doc/latex/eledmac/examples/sections-with-critical-notes.pdf
+++ b/Master/texmf-dist/doc/latex/eledmac/examples/sections-with-critical-notes.pdf
Binary files differ
diff --git a/Master/texmf-dist/doc/latex/eledmac/examples/side-notes.pdf b/Master/texmf-dist/doc/latex/eledmac/examples/side-notes.pdf
index 05c8c82ec00..0fb3302aaf7 100644
--- a/Master/texmf-dist/doc/latex/eledmac/examples/side-notes.pdf
+++ b/Master/texmf-dist/doc/latex/eledmac/examples/side-notes.pdf
Binary files differ
diff --git a/Master/texmf-dist/doc/latex/eledmac/examples/spaces-around-footnote-rule.pdf b/Master/texmf-dist/doc/latex/eledmac/examples/spaces-around-footnote-rule.pdf
index 4d2420eee5b..104516ebea2 100644
--- a/Master/texmf-dist/doc/latex/eledmac/examples/spaces-around-footnote-rule.pdf
+++ b/Master/texmf-dist/doc/latex/eledmac/examples/spaces-around-footnote-rule.pdf
Binary files differ
diff --git a/Master/texmf-dist/doc/latex/eledmac/examples/tabular.pdf b/Master/texmf-dist/doc/latex/eledmac/examples/tabular.pdf
index 8cf8c554ded..a5c0b147413 100644
--- a/Master/texmf-dist/doc/latex/eledmac/examples/tabular.pdf
+++ b/Master/texmf-dist/doc/latex/eledmac/examples/tabular.pdf
Binary files differ
diff --git a/Master/texmf-dist/doc/latex/eledmac/examples/text-between-verses-in-parallel.pdf b/Master/texmf-dist/doc/latex/eledmac/examples/text-between-verses-in-parallel.pdf
index cfa1fecc183..1275b8eb734 100644
--- a/Master/texmf-dist/doc/latex/eledmac/examples/text-between-verses-in-parallel.pdf
+++ b/Master/texmf-dist/doc/latex/eledmac/examples/text-between-verses-in-parallel.pdf
Binary files differ
diff --git a/Master/texmf-dist/source/latex/eledmac/eledmac.dtx b/Master/texmf-dist/source/latex/eledmac/eledmac.dtx
index 6aee357726f..65e3e13b41e 100644
--- a/Master/texmf-dist/source/latex/eledmac/eledmac.dtx
+++ b/Master/texmf-dist/source/latex/eledmac/eledmac.dtx
@@ -51,7 +51,7 @@
%
% \fi
%
-% \CheckSum{10319}
+% \CheckSum{10302}
%
% \makeatletter
% \newcommand*{\DescribeIt}{\leavevmode\@bsphack\begingroup\MakePrivateLetters
@@ -295,7 +295,7 @@
% The \Eledmac{} package makes the
% \edmac, \tabmac{} and \edstanza{} facilities available to authors
% who would prefer
-% to use LaTeX. The principal functions provided by the package
+% to use \LaTeX. The principal functions provided by the package
% are marginal line numbering and multiple series of
% foot- and endnotes keyed to line numbers.
%
@@ -2858,7 +2858,7 @@
% \begin{macrocode}
%<*code>
\NeedsTeXFormat{LaTeX2e}
-\ProvidesPackage{eledmac}[2014/10/20 v1.13.4 LaTeX port of EDMAC]%
+\ProvidesPackage{eledmac}[2014/10/27 v1.14.0 LaTeX port of EDMAC]%
% \end{macrocode}
%
% Generally, these are the modifications to the original.
@@ -2867,7 +2867,7 @@
% \item Replace as many \cs{def}'s by \cs{newcommand}'s as possible
% to avoid overwriting \LaTeX\ macros.
%
-% \item Replace user-level TeX counts by \LaTeX\ counters.
+% \item Replace user-level \TeX\ counts by \LaTeX\ counters.
%
% \item Use the \LaTeX\ font handling mechanisms.
%
@@ -2875,7 +2875,7 @@
%
% \end{itemize}
%
-%
+% \subsection{Package options}
% \begin{macro}{\ifledfinal}
% \begin{macro}{\ifparapparatus@}
% \begin{macro}{\ifnoquotation@}
@@ -2938,7 +2938,7 @@
% The \cs{if@RTL} is defined by the bidi package, which is sometimes loaded by \emph{polyglossia}.
% But we define it if the bidi package is not loaded.
% \begin{macrocode}
-\ifcsdef{if@RTL}{}{\newif\if@RTL}
+\ifdef{\if@RTL}{}{\newif\if@RTL}
% \end{macrocode}
% \end{macro}
% \begin{macro}{\showlemma}
@@ -2954,34 +2954,22 @@
% \end{macrocode}
% \end{macro}
-%
-% \begin{macro}{\linenumberlist}
-% The code for the \verb?\linenumberlist? mechanism was given to Peter Wilson by Wayne
-% Sullivan\index{Sullivan, Wayne} on 2004/02/11.
-%
-% Initialize it as \verb?\empty?
-% \changes{v0.3}{2004/02/14}{Added \cs{linenumberlist} mechanism}
-% \begin{macrocode}
-\let\linenumberlist=\empty
-
-% \end{macrocode}
-% \end{macro}
-%
-% \begin{macro}{\@l@dtempcnta}
-% \begin{macro}{\@l@dtempcntb}
-% In imitation of \LaTeX, we create a couple of scratch counters.
-%
-% \LaTeX\ already defines \cs{@tempcnta} and \cs{@tempcntb} but Peter Wilson have
-% found in the past that it can be dangerous to use these (for example
-% one of the AMS packages did something nasty to the \Lpack{ccaption}
-% package's use of one of these).
-% \begin{macrocode}
-\newcount\@l@dtempcnta \newcount\@l@dtempcntb
+% \subsection{Packages loading}
+% Loading package \emph{xargs} to declare commands with optional arguments.
+% \emph {Etoolbox} is also used to make code clearer - for example, in dynamic command names (which can replace \cs{csname} etc.).
+% Use \emph{suffix} to declare commands with a starred version, \Lpack{xstring} to work with strings and \emph{iflutex} to test if LuaLaTeX is running, and \Lpack{ragged2e} to manage ragging for paragraphed notes.
+% \changes{v1.4}{2012/11/16}{Compatibility with LuaTeX of RTL notes.}
+% \begin{macrocode}
+\RequirePackage{xargs}
+\RequirePackage{etoolbox}
+\reserveinserts{32}
+\RequirePackage{suffix}
+\RequirePackage{xstring}
+\RequirePackage{ifluatex}
+\RequirePackage{ragged2e}
% \end{macrocode}
-% \end{macro}
-% \end{macro}
-%
%
+% \subsection{Boolean flags}
% \begin{macro}{\ifl@dmemoir}
% Define a flag for if the \Lpack{memoir} class has been used.
% \changes{v0.2}{2003/07/25}{Added \cs{ifl@dmemoir} for memoir class having been used}
@@ -3000,6 +2988,13 @@
\@ifpackageloaded{imakeidx}{\l@imakeidxtrue}{\l@imakeidxfalse}
% \end{macrocode}
% \end{macro}
+% \begin{macro}{\if@RTL}
+% The \cs{if@RTL} is defined by the bidi package, which is sometimes loaded by \emph{polyglossia}.
+% But we define it if the bidi package is not loaded.
+% \begin{macrocode}
+\ifcsdef{if@RTL}{}{\newif\if@RTL}
+% \end{macrocode}
+% \end{macro}
% \subsection{Messages}
%
% All the messages are grouped here as macros. This saves TeX's memory
@@ -3282,6 +3277,47 @@
% \end{macrocode}
% \end{macro}
%
+% \subsection{Gobbling}
+% \changes{v1.14.0}{2014/10/27}{Provide \cs{\@gobblefour}}
+% \changes{v1.14.0}{2014/10/27}{Moves gobbling command}
+% \changes{v0.2.2}{2003/11/05}{Used \cs{providecommand} for \cs{@gobblethree}
+% to avoid clash with the amsfonts package}
+% \begin{macro}{\@gobblethree}
+% \begin{macro}{\@gobblefour}
+% \begin{macrocode}
+\providecommand*{\@gobblethree}[3]{}
+\providecommand*{\@gobblefour}[4]{}
+% \end{macrocode}
+% \end{macro}
+% \end{macro}
+% Here, we define some commands which gobble their arguments.
+% \subsection{Miscellaneous commands}
+% \begin{macro}{\linenumberlist}
+% The code for the \verb?\linenumberlist? mechanism was given to Peter Wilson by Wayne
+% Sullivan\index{Sullivan, Wayne} on 2004/02/11.
+%
+% Initialize it as \verb?\empty?
+% \changes{v0.3}{2004/02/14}{Added \cs{linenumberlist} mechanism}
+% \begin{macrocode}
+\let\linenumberlist=\empty
+
+% \end{macrocode}
+% \end{macro}
+%
+% \begin{macro}{\@l@dtempcnta}
+% \begin{macro}{\@l@dtempcntb}
+% In imitation of \LaTeX, we create a couple of scratch counters.
+%
+% \LaTeX\ already defines \cs{@tempcnta} and \cs{@tempcntb} but Peter Wilson have
+% found in the past that it can be dangerous to use these (for example
+% one of the AMS packages did something nasty to the \Lpack{ccaption}
+% package's use of one of these).
+% \begin{macrocode}
+\newcount\@l@dtempcnta \newcount\@l@dtempcntb
+% \end{macrocode}
+% \end{macro}
+% \end{macro}
+%
%
% \section{Sectioning commands}
%
@@ -9113,6 +9149,7 @@
% \end{macro}
% \section{Endnotes}
% \changes{v1.8.1}{2013/12/15}{Debug endnotes when more than one series is used (change the position where tools for endnotes are defined).}
+% \changes{v1.14.0}{2014/10/20}{Debug spurious characters before endnotes.}
% \label{endnotes}\relax
%
% \begin{macro}{\l@d@end}
@@ -9164,7 +9201,6 @@
% \end{macro}
%
% \begin{macro}{\endprint}
-% \begin{macro}{\@gobblethree}
% \begin{macro}{\l@d@section}
% The \cs{endprint} here is nearly identical in its
% functioning to \cs{normalfootfmt}.
@@ -9173,19 +9209,17 @@
% supply the section numbers from the main text; standard \Eledmac{} does
% nothing with this information, but it's there if you want to write
% custom macros to do something with it.
-% \changes{v0.2.2}{2003/11/05}{Used \cs{providecommand} for \cs{@gobblethree}
-% to avoid clash with the amsfonts package}
+
% \begin{macrocode}
\def\endprint#1#2#3#4{{\csuse{bhookXendnote@#4}\csuse{Xendnotefontsize@#4}{\csuse{Xendnotenumfont@#4}\printendlines#1|}%
\enspace{\nottoggle{Xendlemmadisablefontselection@#4}{\select@lemmafont#1|#2}{#2}}\enskip#3\par}}
-\providecommand*{\@gobblethree}[3]{}
\let\l@d@section=\@gobble
% \end{macrocode}
% \end{macro}
% \end{macro}
-% \end{macro}
+
%
% \begin{macro}{\setprintendlines}
% The \cs{printendlines} macro is similar to \cs{printlines} but is
@@ -9493,7 +9527,7 @@
% defined in the amsfonts package.}
% \begin{macrocode}
- \global\csletcs{#1end}{@gobblethree}
+ \global\cslet{#1end}{\@gobblefour}
%\end{macrocode}
% We need to be able to modify \Eledmac's footnote macros and restore their
@@ -10355,7 +10389,7 @@
% \begin{macrocode}
\protected@write\@auxout{}%
{\string\l@dmake@labels\space\thepage|\label@refs|\the\c@pstart|{#1}}%
- \ifcsdef{hypertarget}{\hypertarget{#1}{}}{}%
+ \ifdef{\hypertarget}{\hypertarget{#1}{}}{}%
\@esphack}
% \end{macrocode}
@@ -11371,90 +11405,93 @@
% \end{macro}
% The \Lpack{memoir} class provides more flexible indexing than the
% standard classes. We need different code if the \Lpack{memoir}
-% class is being used.
-%
-% \begin{macrocode}
-\@ifclassloaded{memoir}{%
-% \end{macrocode}
-% \Lpack{memoir} is being used.
-% \changes{v0.4.1}{2003/03/29}{Let eledmac take advantage of memoir's indexing}
-%
-% \begin{macro}{\makeindex}
+% class is being used, except if \Lpack{imakeidx} is used.
% \begin{macro}{\edindex}
+% \changes{v0.4.1}{2003/03/29}{Let eledmac take advantage of memoir's indexing}
% \changes{v1.5}{2013/07/11}{Compatibility with \Lpack{imakeidx} package, and possibility to use multiple index with \cs{edindex}.}
+% \changes{v1.12.0}{2014/08/05}{Use correctly default index when \Lpack{imakeidx} is loaded.}
+% \changes{v1.14.0}{2014/10/27}{Let eledmac take advantage of imakeidx even when memoir class is used}
+% \subsection{Memoir compatibility}
+% \begin{macro}{\create@edindex@for@memoir}
+% \cs{create@edindex@for@memoir} define the \cs{edindex} command and related tool when:
+% \begin{enumerate}
+% \item Memoir class is used.
+% \item AND \Lpack{imakeidx} is not used.
+% \end{enumerate}
% Need to add the definition of |\edindex| to |\makeindex|, and initialise
% |\edindex| to do nothing. In this case |\edindex| has an optional
% argument. We use the hook provided in \Lpack{memoir} v1.61.
% \begin{macrocode}
+\def\create@edindex@for@memoir{
+% \end{macrocode}
+% \begin{macrocode}
\g@addto@macro{\makememindexhook}{%
\def\edindex{\@bsphack%
\@ifnextchar [{\l@d@index}{\l@d@index[\jobname]}}}
\newcommand{\edindex}[2][\jobname]{\@bsphack\@esphack}
% \end{macrocode}
-% \end{macro}
-% \end{macro}
%
% \begin{macro}{\l@d@index}
% |\l@d@index[file]| is the first stage of |\edindex|, handling the
% |idx| file. This a virtually a verbatim copy of \Lpack{memoir}'s |\@index|,
% the change being calling |\l@dwrindexm@m| instead of |\@wrindexm@m|.
% \begin{macrocode}
- \def\l@d@index[#1]{%
- \@ifundefined{#1@idxfile}%
+ \def\l@d@index[##1]{%
+ \@ifundefined{##1@idxfile}%
{\ifreportnoidxfile
- \led@warn@NoIndexFile{#1}%
+ \led@warn@NoIndexFile{##1}%
\fi
\begingroup
\@sanitize
\@nowrindex}%
- {\def\@idxfile{#1}%
+ {\def\@idxfile{##1}%
\doedindexlabel
\begingroup
\@sanitize
\l@d@wrindexm@m}}
% \end{macrocode}
% \end{macro}
-%
+%
% \begin{macro}{\l@d@wrindexm@m}
% \begin{macro}{\l@d@@wrindexhyp}
% |\l@d@wrindexm@m{item}| writes the |idx| file name and the indexed
% item to the |aux| file. These are almost verbatim copies of \Lpack{memoir}'s
% |\@wrindexm@m| and |\@@wrindexhyp|.
% \begin{macrocode}
- \newcommand{\l@d@wrindexm@m}[1]{\l@d@@wrindexhyp#1||\\}
- \def\l@d@@wrindexhyp#1|#2|#3\\{%
- \ifshowindexmark\@showidx{#1}\fi
- \ifx\\#2\\%
+ \newcommand{\l@d@wrindexm@m}[1]{\l@d@@wrindexhyp##1||\\}
+ \def\l@d@@wrindexhyp##1|##2|##3\\{%
+ \ifshowindexmark\@showidx{##1}\fi
+ \ifx\\##2\\%
\if@edindex@fornote@%
\protected@write\@auxout{}%
- {\string\@@wrindexm@m{\@idxfile}{#1|(ledinnotehyperpage}{\thestartpageline}}%
+ {\string\@@wrindexm@m{\@idxfile}{##1|(ledinnotehyperpage}{\thestartpageline}}%
\protected@write\@auxout{}%
- {\string\@@wrindexm@m{\@idxfile}{#1|)ledinnotehyperpage}{\theendpageline}}%
+ {\string\@@wrindexm@m{\@idxfile}{##1|)ledinnotehyperpage}{\theendpageline}}%
\else%
\protected@write\@auxout{}%
- {\string\@@wrindexm@m{\@idxfile}{#1|hyperpage}{\thepageline}}%
+ {\string\@@wrindexm@m{\@idxfile}{##1|hyperpage}{\thepageline}}%
\fi%
\else
- \def\Hy@temp@A{#2}%
+ \def\Hy@temp@A{##2}%
\ifx\Hy@temp@A\HyInd@ParenLeft
\if@edindex@fornote@%
\protected@write\@auxout{}%
- {\string\@@wrindexm@m{\@idxfile}{#1|(ledinnotehyperpage{#2}}{\thestartpageline}}%
+ {\string\@@wrindexm@m{\@idxfile}{##1|(ledinnotehyperpage{##2}}{\thestartpageline}}%
\protected@write\@auxout{}%
- {\string\@@wrindexm@m{\@idxfile}{#1|)ledinnotehyperpage{#2}}{\theendpageline}}%
+ {\string\@@wrindexm@m{\@idxfile}{##1|)ledinnotehyperpage{##2}}{\theendpageline}}%
\else%
\protected@write\@auxout{}%
- {\string\@@wrindexm@m{\@idxfile}{#1|#2hyperpage}{\thepageline}}%
+ {\string\@@wrindexm@m{\@idxfile}{##1|##2hyperpage}{\thepageline}}%
\fi%
\else
\if@edindex@fornote@%
\protected@write\@auxout{}%
- {\string\@@wrindexm@m{\@idxfile}{#1|(ledinnote{#2}}{\thestartpageline}}%
+ {\string\@@wrindexm@m{\@idxfile}{##1|(ledinnote{##2}}{\thestartpageline}}%
\protected@write\@auxout{}%
- {\string\@@wrindexm@m{\@idxfile}{#1|)ledinnote{#2}}{\theendpageline}}%
+ {\string\@@wrindexm@m{\@idxfile}{##1|)ledinnote{##2}}{\theendpageline}}%
\else%
\protected@write\@auxout{}%
- {\string\@@wrindexm@m{\@idxfile}{#1|#2}{\thepageline}}%
+ {\string\@@wrindexm@m{\@idxfile}{##1|##2}{\thepageline}}%
\fi%
\fi
\fi
@@ -11463,48 +11500,39 @@
% \end{macrocode}
% \end{macro}
% \end{macro}
-%
+% \end{macro}
% That finishes the \Lpack{memoir}-specific code.
% \begin{macrocode}
-}{%
+}
% \end{macrocode}
-% \Lpack{memoir} is not being used, which makes life somewhat simpler.
-%
-% \begin{macro}{\makeindex}
-% \begin{macro}{\edindex}
-% Need to add the definition of |\edindex| to |\makeindex|, and initialise
-% |\edindex| to do nothing.
+% \subsection{Normal setting}
+% \begin{macro}{\create@edindex@notfor@memoir}
+% \cs{create@edindex@notfor@memoir} define the \cs{edindex} command and related tool when:
+% \begin{enumerate}
+% \item Memoir class is NOT used.
+% \item OR \Lpack{imakeidx} is used.
+% \end{enumerate}
% \begin{macrocode}
- \pretocmd{\makeindex}{%
- \def\edindex{\@bsphack
- \doedindexlabel
- \begingroup
- \@sanitize
- \@wredindex}}{}{}
- \newcommand{\edindex}[1]{\@bsphack\@esphack}
+\def\create@edindex@notfor@memoir{
% \end{macrocode}
-% \end{macro}
-% \end{macro}
-%
% \begin{macro}{\@wredindex}
% Write the index information to the \file{idx} file.
-% \changes{v1.12.0}{2014/08/05}{Use correctly default index when \Lpack{imakeidx} is loaded.}
% \begin{macrocode}
\newcommandx{\@wredindex}[2][1=\expandonce\jobname,usedefault]{%#1 = the index name, #2 = the text
\global\let\old@Rlineflag\Rlineflag%
\gdef\Rlineflag{}%
\ifl@imakeidx%
\if@edindex@fornote@%
- \IfSubStr[1]{#2}{|}{\get@index@command#2+}{\get@index@command#2|+}%
- \expandafter\imki@wrindexentry{#1}{\@index@txt|(ledinnote{\@index@command}}{\thestartpageline}%
- \expandafter\imki@wrindexentry{#1}{\@index@txt|)ledinnote{\@index@command}}{\theendpageline}%
+ \IfSubStr[1]{##2}{|}{\get@index@command##2+}{\get@index@command##2|+}%
+ \expandafter\imki@wrindexentry{##1}{\@index@txt|(ledinnote{\@index@command}}{\thestartpageline}%
+ \expandafter\imki@wrindexentry{##1}{\@index@txt|)ledinnote{\@index@command}}{\theendpageline}%
\else%
- \get@edindex@hyperref{#2}%
- \imki@wrindexentry{#1}{\@index@txt\@edindex@hyperref}{\thepageline}%
+ \get@edindex@hyperref{##2}%
+ \imki@wrindexentry{##1}{\@index@txt\@edindex@hyperref}{\thepageline}%
\fi%
\else%
\if@edindex@fornote@%
- \IfSubStr[1]{#2}{|}{\get@index@command#2+}{\get@index@command#2|+}%
+ \IfSubStr[1]{##2}{|}{\get@index@command##2+}{\get@index@command##2|+}%
\expandafter\protected@write\@indexfile{}%
{\string\indexentry{\@index@txt|(ledinnote{\@index@command}}{\thestartpageline}
}%
@@ -11513,7 +11541,7 @@
}%
\else%
\protected@write\@indexfile{}%
- {\string\indexentry{#2}{\thepageline}
+ {\string\indexentry{##2}{\thepageline}
}%
\fi%
\fi%
@@ -11521,12 +11549,32 @@
\global\let\Rlineflag\old@Rlineflag%
\@esphack}
% \end{macrocode}
-% \end{macro}
-%
-% That finishes the non-\Lpack{memoir} index code.
+% Need to add the definition of |\edindex| to |\makeindex|, and initialise
+% |\edindex| to do nothing.
+% \begin{macrocode}
+ \pretocmd{\makeindex}{%
+ \def\edindex{\@bsphack
+ \doedindexlabel
+ \begingroup
+ \@sanitize
+ \@wredindex}}{}{}
+ \newcommand{\edindex}[1]{\@bsphack\@esphack}
+% \end{macrocode}
% \begin{macrocode}
+% That finishes the non-\Lpack{memoir} index code.
}
-
+% \end{macrocode}
+% \end{macro}
+% \end{macro}
+% \end{macro}
+% \subsection{Choose the good variant}
+% And now, call \cs{create@edindex@for@memoir} or \cs{create@edindex@notfor@memoir} depending of the use of \Lpack{memoir} and \Lpack{imakeidx}
+% \begin{macrocode}
+\@ifclassloaded{memoir}{%
+ \@ifpackageloaded{imakeidx}%
+ {\create@edindex@notfor@memoir}{\create@edindex@for@memoir}%
+ }%
+ {\create@edindex@notfor@memoir}%
% \end{macrocode}
%
% \subsection{Hyperref compatibility}
@@ -11564,7 +11612,7 @@
% \cs{get@edindex@hyperref} is to be used to define the \cs{@edindex@hyperref} macro, which, in index, links to the point where the index was called (with \Lpack{hyperref}.
% \begin{macrocode}
\newcommand{\get@edindex@hyperref}[1]{%
- \ifcsdef{hyperlink}%
+ \ifdef{\hyperlink}%
% \end{macrocode}
% We have to disable spaces to work with a \Lpack{xstring} bug
% \begin{macrocode}
@@ -11601,30 +11649,7 @@
% \end{macrocode}
% \end{macro}
% \end{macro}
-% \begin{macro}{\l@d@@wrindexhyp}
-% If the \Lpack{hyperref} package is not loaded, it doesn't make sense
-% to clutter up the index with hyperreffing things. Not that memoir class have yet a not standard behavior.
-% \begin{macrocode}
-\ifl@dmemoir\else%
-\AtBeginDocument{\@ifpackageloaded{hyperref}{}{%
- \def\l@d@@wrindexhyp#1||\\{%
- \ifshowindexmark\@showidx{#1}\fi
- \IfSubStr[1]{#1}{|}{\get@index@command#1+}{\get@index@command#1|+}%
- \if@edindex@fornote@%
- \protected@write\@auxout{}%
- {\string\@@wrindexm@m{\@idxfile}{\@index@txt|(ledinnote{\@index@command}}{\thestartpageline}}%
- \protected@write\@auxout{}%
- {\string\@@wrindexm@m{\@idxfile}{\@index@txt|)ledinnote{\@index@command}}{\theendpageline}}%
- \else%
- \protected@write\@auxout{}%
- {\string\@@wrindexm@m{\@idxfile}{#1}{\thepageline}}%
- \fi%
- \endgroup
- \@esphack}}}
-\fi%
-
-% \end{macrocode}
-% \end{macro}
+% \changes{v1.14.0}{2014/10/27}{Delete previous override of \cs{l@d@@wrindexhyp} at the beginning of a document when hyperref was not loaded.}
%
%
% \section{Macro as environment}
diff --git a/Master/texmf-dist/tex/latex/eledmac/eledmac.sty b/Master/texmf-dist/tex/latex/eledmac/eledmac.sty
index ae2eee74105..395b386bda8 100644
--- a/Master/texmf-dist/tex/latex/eledmac/eledmac.sty
+++ b/Master/texmf-dist/tex/latex/eledmac/eledmac.sty
@@ -25,7 +25,7 @@
\NeedsTeXFormat{LaTeX2e}
-\ProvidesPackage{eledmac}[2014/10/20 v1.13.4 LaTeX port of EDMAC]%
+\ProvidesPackage{eledmac}[2014/10/27 v1.14.0 LaTeX port of EDMAC]%
\newif\ifledfinal
\newif\ifparapparatus@
\newif\ifnoquotation@
@@ -51,21 +51,26 @@
\RequirePackage{xstring}
\RequirePackage{ifluatex}
\RequirePackage{ragged2e}
-\ifcsdef{if@RTL}{}{\newif\if@RTL}
+\ifdef{\if@RTL}{}{\newif\if@RTL}
\ifledfinal
\newcommand*{\showlemma}[1]{#1}
\else
\newcommand*{\showlemma}[1]{\underline{#1}}
\fi
-\let\linenumberlist=\empty
-
-\newcount\@l@dtempcnta \newcount\@l@dtempcntb
+\RequirePackage{xargs}
+\RequirePackage{etoolbox}
+\reserveinserts{32}
+\RequirePackage{suffix}
+\RequirePackage{xstring}
+\RequirePackage{ifluatex}
+\RequirePackage{ragged2e}
\newif\ifl@dmemoir
\@ifclassloaded{memoir}{\l@dmemoirtrue}{\l@dmemoirfalse}
\newif\ifl@imakeidx
\@ifpackageloaded{imakeidx}{\l@imakeidxtrue}{\l@imakeidxfalse}
+\ifcsdef{if@RTL}{}{\newif\if@RTL}
\newcommand{\eledmac@warning}[1]{\PackageWarning{eledmac}{#1}}
\newcommand{\eledmac@error}[2]{\PackageError{eledmac}{#1}{#2}}
\newcommand*{\led@err@NumberingStarted}{%
@@ -187,6 +192,11 @@
\newcommand{\led@error@ImakeidxAfterEledmac}{%
\eledmac@error{Imakeidx must be loaded before eledmac.}{\@ehd}%
}%
+\providecommand*{\@gobblethree}[3]{}
+\providecommand*{\@gobblefour}[4]{}
+\let\linenumberlist=\empty
+
+\newcount\@l@dtempcnta \newcount\@l@dtempcntb
\newcount\section@num
\section@num=0
\let\extensionchars=\empty
@@ -2506,12 +2516,13 @@
\fi
\immediate\write\l@d@end{\string\l@d@section{\the\section@num}}}
+
\def\endprint#1#2#3#4{{\csuse{bhookXendnote@#4}\csuse{Xendnotefontsize@#4}{\csuse{Xendnotenumfont@#4}\printendlines#1|}%
\enspace{\nottoggle{Xendlemmadisablefontselection@#4}{\select@lemmafont#1|#2}{#2}}\enskip#3\par}}
-\providecommand*{\@gobblethree}[3]{}
\let\l@d@section=\@gobble
+
\newcommand*{\setprintendlines}[6]{%
\l@d@pnumfalse \l@d@dashfalse
\ifnum#4=#1 \else
@@ -2680,7 +2691,7 @@
{\ifnumberedpar@\csexpandonce{@tag}\fi}{\csexpandonce{content}}{#1}}}\ignorespaces%
}
- \global\csletcs{#1end}{@gobblethree}
+ \global\cslet{#1end}{\@gobblefour}
\global\csletcs{#1@@footnote}{#1footnote}
@@ -3116,7 +3127,7 @@
\fi
\protected@write\@auxout{}%
{\string\l@dmake@labels\space\thepage|\label@refs|\the\c@pstart|{#1}}%
- \ifcsdef{hypertarget}{\hypertarget{#1}{}}{}%
+ \ifdef{\hypertarget}{\hypertarget{#1}{}}{}%
\@esphack}
\newcounter{line}%
@@ -3603,86 +3614,80 @@
}
\newcommand{\ledinnote}[2]{\csuse{#1}{#2\emph{n}}}
\newcommand{\ledinnotehyperpage}[2]{\csuse{#1}{\hyperpage{#2}\emph{n}}}
-\@ifclassloaded{memoir}{%
+\def\create@edindex@for@memoir{
\g@addto@macro{\makememindexhook}{%
\def\edindex{\@bsphack%
\@ifnextchar [{\l@d@index}{\l@d@index[\jobname]}}}
\newcommand{\edindex}[2][\jobname]{\@bsphack\@esphack}
- \def\l@d@index[#1]{%
- \@ifundefined{#1@idxfile}%
+ \def\l@d@index[##1]{%
+ \@ifundefined{##1@idxfile}%
{\ifreportnoidxfile
- \led@warn@NoIndexFile{#1}%
+ \led@warn@NoIndexFile{##1}%
\fi
\begingroup
\@sanitize
\@nowrindex}%
- {\def\@idxfile{#1}%
+ {\def\@idxfile{##1}%
\doedindexlabel
\begingroup
\@sanitize
\l@d@wrindexm@m}}
- \newcommand{\l@d@wrindexm@m}[1]{\l@d@@wrindexhyp#1||\\}
- \def\l@d@@wrindexhyp#1|#2|#3\\{%
- \ifshowindexmark\@showidx{#1}\fi
- \ifx\\#2\\%
+ \newcommand{\l@d@wrindexm@m}[1]{\l@d@@wrindexhyp##1||\\}
+ \def\l@d@@wrindexhyp##1|##2|##3\\{%
+ \ifshowindexmark\@showidx{##1}\fi
+ \ifx\\##2\\%
\if@edindex@fornote@%
\protected@write\@auxout{}%
- {\string\@@wrindexm@m{\@idxfile}{#1|(ledinnotehyperpage}{\thestartpageline}}%
+ {\string\@@wrindexm@m{\@idxfile}{##1|(ledinnotehyperpage}{\thestartpageline}}%
\protected@write\@auxout{}%
- {\string\@@wrindexm@m{\@idxfile}{#1|)ledinnotehyperpage}{\theendpageline}}%
+ {\string\@@wrindexm@m{\@idxfile}{##1|)ledinnotehyperpage}{\theendpageline}}%
\else%
\protected@write\@auxout{}%
- {\string\@@wrindexm@m{\@idxfile}{#1|hyperpage}{\thepageline}}%
+ {\string\@@wrindexm@m{\@idxfile}{##1|hyperpage}{\thepageline}}%
\fi%
\else
- \def\Hy@temp@A{#2}%
+ \def\Hy@temp@A{##2}%
\ifx\Hy@temp@A\HyInd@ParenLeft
\if@edindex@fornote@%
\protected@write\@auxout{}%
- {\string\@@wrindexm@m{\@idxfile}{#1|(ledinnotehyperpage{#2}}{\thestartpageline}}%
+ {\string\@@wrindexm@m{\@idxfile}{##1|(ledinnotehyperpage{##2}}{\thestartpageline}}%
\protected@write\@auxout{}%
- {\string\@@wrindexm@m{\@idxfile}{#1|)ledinnotehyperpage{#2}}{\theendpageline}}%
+ {\string\@@wrindexm@m{\@idxfile}{##1|)ledinnotehyperpage{##2}}{\theendpageline}}%
\else%
\protected@write\@auxout{}%
- {\string\@@wrindexm@m{\@idxfile}{#1|#2hyperpage}{\thepageline}}%
+ {\string\@@wrindexm@m{\@idxfile}{##1|##2hyperpage}{\thepageline}}%
\fi%
\else
\if@edindex@fornote@%
\protected@write\@auxout{}%
- {\string\@@wrindexm@m{\@idxfile}{#1|(ledinnote{#2}}{\thestartpageline}}%
+ {\string\@@wrindexm@m{\@idxfile}{##1|(ledinnote{##2}}{\thestartpageline}}%
\protected@write\@auxout{}%
- {\string\@@wrindexm@m{\@idxfile}{#1|)ledinnote{#2}}{\theendpageline}}%
+ {\string\@@wrindexm@m{\@idxfile}{##1|)ledinnote{##2}}{\theendpageline}}%
\else%
\protected@write\@auxout{}%
- {\string\@@wrindexm@m{\@idxfile}{#1|#2}{\thepageline}}%
+ {\string\@@wrindexm@m{\@idxfile}{##1|##2}{\thepageline}}%
\fi%
\fi
\fi
\endgroup
\@esphack}
-}{%
- \pretocmd{\makeindex}{%
- \def\edindex{\@bsphack
- \doedindexlabel
- \begingroup
- \@sanitize
- \@wredindex}}{}{}
- \newcommand{\edindex}[1]{\@bsphack\@esphack}
+}
+\def\create@edindex@notfor@memoir{
\newcommandx{\@wredindex}[2][1=\expandonce\jobname,usedefault]{%#1 = the index name, #2 = the text
\global\let\old@Rlineflag\Rlineflag%
\gdef\Rlineflag{}%
\ifl@imakeidx%
\if@edindex@fornote@%
- \IfSubStr[1]{#2}{|}{\get@index@command#2+}{\get@index@command#2|+}%
- \expandafter\imki@wrindexentry{#1}{\@index@txt|(ledinnote{\@index@command}}{\thestartpageline}%
- \expandafter\imki@wrindexentry{#1}{\@index@txt|)ledinnote{\@index@command}}{\theendpageline}%
+ \IfSubStr[1]{##2}{|}{\get@index@command##2+}{\get@index@command##2|+}%
+ \expandafter\imki@wrindexentry{##1}{\@index@txt|(ledinnote{\@index@command}}{\thestartpageline}%
+ \expandafter\imki@wrindexentry{##1}{\@index@txt|)ledinnote{\@index@command}}{\theendpageline}%
\else%
- \get@edindex@hyperref{#2}%
- \imki@wrindexentry{#1}{\@index@txt\@edindex@hyperref}{\thepageline}%
+ \get@edindex@hyperref{##2}%
+ \imki@wrindexentry{##1}{\@index@txt\@edindex@hyperref}{\thepageline}%
\fi%
\else%
\if@edindex@fornote@%
- \IfSubStr[1]{#2}{|}{\get@index@command#2+}{\get@index@command#2|+}%
+ \IfSubStr[1]{##2}{|}{\get@index@command##2+}{\get@index@command##2|+}%
\expandafter\protected@write\@indexfile{}%
{\string\indexentry{\@index@txt|(ledinnote{\@index@command}}{\thestartpageline}
}%
@@ -3691,15 +3696,26 @@
}%
\else%
\protected@write\@indexfile{}%
- {\string\indexentry{#2}{\thepageline}
+ {\string\indexentry{##2}{\thepageline}
}%
\fi%
\fi%
\endgroup
\global\let\Rlineflag\old@Rlineflag%
\@esphack}
+ \pretocmd{\makeindex}{%
+ \def\edindex{\@bsphack
+ \doedindexlabel
+ \begingroup
+ \@sanitize
+ \@wredindex}}{}{}
+ \newcommand{\edindex}[1]{\@bsphack\@esphack}
}
-
+\@ifclassloaded{memoir}{%
+ \@ifpackageloaded{imakeidx}%
+ {\create@edindex@notfor@memoir}{\create@edindex@for@memoir}%
+ }%
+ {\create@edindex@notfor@memoir}%
\newcommand{\hyperlinkformat}[3]{%
\ifstrempty{#1}%
{\hyperlink{#2}{#3}}%
@@ -3714,7 +3730,7 @@
}%
\newcommand{\get@edindex@hyperref}[1]{%
- \ifcsdef{hyperlink}%
+ \ifdef{\hyperlink}%
{%
\edef\temp@{%
\catcode`\ =9 %space need for catcode
@@ -3745,24 +3761,6 @@
\gdef\@index@txt{#1}%
\gdef\@edindex@hyperref{}}%
}
-\ifl@dmemoir\else%
-\AtBeginDocument{\@ifpackageloaded{hyperref}{}{%
- \def\l@d@@wrindexhyp#1||\\{%
- \ifshowindexmark\@showidx{#1}\fi
- \IfSubStr[1]{#1}{|}{\get@index@command#1+}{\get@index@command#1|+}%
- \if@edindex@fornote@%
- \protected@write\@auxout{}%
- {\string\@@wrindexm@m{\@idxfile}{\@index@txt|(ledinnote{\@index@command}}{\thestartpageline}}%
- \protected@write\@auxout{}%
- {\string\@@wrindexm@m{\@idxfile}{\@index@txt|)ledinnote{\@index@command}}{\theendpageline}}%
- \else%
- \protected@write\@auxout{}%
- {\string\@@wrindexm@m{\@idxfile}{#1}{\thepageline}}%
- \fi%
- \endgroup
- \@esphack}}}
-\fi%
-
\newtoks\@emptytoks
\newtoks\l@denvbody