summaryrefslogtreecommitdiff
path: root/Master/texmf-dist/source/latex/eledmac
diff options
context:
space:
mode:
authorKarl Berry <karl@freefriends.org>2014-09-18 22:58:23 +0000
committerKarl Berry <karl@freefriends.org>2014-09-18 22:58:23 +0000
commit5c46cbe2d34d3ae0d9f584f9b183265358484397 (patch)
tree0f840ecd0904500ceac6d2e054f15fc62f773b2f /Master/texmf-dist/source/latex/eledmac
parent049e1d558c44f46e601b82c3183b9865a5c3e488 (diff)
eledmac (16sep14)
git-svn-id: svn://tug.org/texlive/trunk@35199 c570f23f-e606-0410-a88d-b1316a301751
Diffstat (limited to 'Master/texmf-dist/source/latex/eledmac')
-rw-r--r--Master/texmf-dist/source/latex/eledmac/eledmac.dtx357
-rw-r--r--Master/texmf-dist/source/latex/eledmac/eledpar.dtx345
2 files changed, 557 insertions, 145 deletions
diff --git a/Master/texmf-dist/source/latex/eledmac/eledmac.dtx b/Master/texmf-dist/source/latex/eledmac/eledmac.dtx
index 6ebb4ad6c22..c7d383b7086 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{10117}
+% \CheckSum{10305}
%
% \makeatletter
% \newcommand*{\DescribeIt}{\leavevmode\@bsphack\begingroup\MakePrivateLetters
@@ -206,7 +206,7 @@
% \changes{v1.12.3}{2014/08/15}{Correct bug with side and familiar notes in tabular environments.}
% \changes{v1.12.3}{2014/08/15}{Debug left and right notes (bugs added by 1.12.0)}
% \changes{v1.12.3}{2014/08/15}{Debug \cs{eledxxx} with some paper size}
-% \changes{v1.12.4}{2014/08/25}{Debug spurious page breaking before \cs{chapter} (bug added by 1.12.0)}
+% \changes{v1.12.4}{2014/08/25}{Debug spurious page breaks before \cs{chapter} (bug added by 1.12.0)}
% \hyphenation{man-u-script man-u-scripts}
%
%
@@ -1235,25 +1235,25 @@
% \subsubsection{Control line number printing}
% \DescribeMacro{\numberonlyfirstinline}
% \changes{v1.0.1}{2012/09/16}{Correction on \cs{numberonlyfirstinline} with lineation by pstart or by page.}
-% By default, the line number is printed in every note. If you want to print it only the first time for a value (i.e one time for line 1, one time for line 2 etc.), you can use \cs{numberonlyfirstinline}\oarg{s}. Use \cs{numberonlyfirstinline}\oarg{s}\oarg{false} to cancel it (\verb|<s>| can be empty if you want to disable it for every series).
+% By default, the line number is printed in every note. If you want to print it only the first time for a value (i.e one time for line 1, one time for line 2 etc.), you can use \cs{numberonlyfirstinline}\oarg{s}. Use \cs{numberonlyfirstinline}\oarg{s}\verb+[false]+ to cancel it (\verb|<s>| can be empty if you want to disable it for every series).
%
% \DescribeMacro{\numberonlyfirstintwolines}
% \changes{v1.1}{2012/09/25}{Add \cs{numberonlyfirstintwolines}}
% Suppose you have a lemma on line~2 and a lemma between line~2 and line~3.
% With \cs{numberonlyfirstinline}, the second lemma is considered to be on the same line as the first lemma.
% But if you use both \cs{numberonlyfirstinline}\oarg{s} and \cs{numberonlyfirstintwolines}\oarg{s}, the distinction is made.
-% Use \cs{numberonlyfirstintwolines}\oarg{s}\oarg{false} to cancel it (\verb|<s>| can be empty if you want to disable it for every series).
+% Use \cs{numberonlyfirstintwolines}\oarg{s}\verb+[false]+ to cancel it (\verb|<s>| can be empty if you want to disable it for every series).
%
% \DescribeMacro{\symlinenum}
% For setting a particular symbol in place of the line number, you can use \cs{symlinenum}\oarg{s}\marg{symbol} in combination with \cs{numberonlyfirstinline}\oarg{s}. From the second lemma of the same line, the symbol will be used instead of line number.
%
% \DescribeMacro{\nonumberinfootnote}
-% You can use \cs{nonumberinfootnote}\oarg{s} if you don't want to have the line number in a footnote. To cancel it, use \cs{nonumberinfootnote}\oarg{s}\oarg{false}.
+% You can use \cs{nonumberinfootnote}\oarg{s} if you don't want to have the line number in a footnote. To cancel it, use \cs{nonumberinfootnote}\oarg{s}\verb+[false]+.
%
% \changes{v1.1}{2012/09/25}{Add \cs{pstartinfootnote} and \cs{onlypstartinfootnote}}
% \DescribeMacro{\pstartinfootnote}
% You can use \cs{pstartinfootnote}\oarg{s} if you want to print the pstart number in the footnote, before the line and subline number.
-% Use \cs{pstartinfootnote}\oarg{s}\oarg{false} to cancel it (\verb|<s>| can be empty if you want to disable it for every series).
+% Use \cs{pstartinfootnote}\oarg{s}\verb+[false]+ to cancel it (\verb|<s>| can be empty if you want to disable it for every series).
% Note that when you change the lineation system, the option is automatically switched :
% \begin{itemize}
% \item If you use lineation by pstart, the option is enabled.
@@ -1262,7 +1262,7 @@
%
% \DescribeMacro{\onlypstartinfootnote}
% In combination with \cs{pstartinfootnote}, you can use \cs{onlypstartinfootnote}\oarg{s} if you want to print only the pstart number in the footnote, and not the line and subline number.
-% Use \cs{onlypstartinfootnote}\oarg{s}\oarg{false} to cancel it (\verb|<s>| can be empty if you want to disable it for every series).
+% Use \cs{onlypstartinfootnote}\oarg{s}\verb+[false]+ to cancel it (\verb|<s>| can be empty if you want to disable it for every series).
%
% \DescribeMacro{\beforenumberinfootnote}
% With \cs{beforenumberinfootnote}\oarg{s}\marg{l}, you can add some space before the line number in a footnote. If the line number is not printed, the space is not either. The default value is 0~pt.
@@ -1272,7 +1272,7 @@
%
%\changes{v1.4.3}{2012/12/18}{Add \cs{nonbreakableafternumber}.}
%\DescribeMacro{\nonbreakableafternumber}
-% By default, the space defined by \cs{afternumberinfootnote} is breakable. With \cs{nonbreakableafternumber}\oarg{s} it becomes nonbreakable. Use \cs{nonbreakableafternumber}\oarg{s}\oarg{false} to cancel it (\verb|<s>| can be empty if you want to disable it for every series).
+% By default, the space defined by \cs{afternumberinfootnote} is breakable. With \cs{nonbreakableafternumber}\oarg{s} it becomes nonbreakable. Use \cs{nonbreakableafternumber}\oarg{s}\verb+[false]+ to cancel it (\verb|<s>| can be empty if you want to disable it for every series).
%
% \DescribeMacro{\beforesymlinenum}
% With \cs{beforesymlinenum}\oarg{s}\marg{l} you can add some space before the line symbol in a footnote. The default value is value set by \cs{beforenumberinfootnote}.
@@ -1482,7 +1482,13 @@
% the trick. Page \pageref{nobreak} explains why this restriction
% is necessary.}
%
-%
+% \changes{v1.13.0}{2014/09/16}{Add \cs{Xnoteswidthliketwocolumns} and \cs{notesXwidthliketwocolumns}}
+% \DescribeMacro{Xnoteswidthliketwocolumns}\DescribeMacro{notesXwidthliketwocolumns}
+% If you use \Lpack{eledpar} \cs{columns} macro, you can call :
+% \begin{itemize}
+% \item \cs{Xnoteswidthliketwocolumns}\oarg{s} to create critical notes with a two-column size width. Use \cs{Xnoteswidthliketwocolumns}\oarg{s}\verb+[false]+ to disable it.
+% \item \cs{notesXwidthliketwocolumns}\oarg{s} to create familiar notes with a two-column size width. Use \cs{notesXwidthliketwocolumns}\oarg{s}\verb+[false]+ to disable it.
+% \end{itemize}
% \subsection{Fonts}\label{fonts}
% One of the most important features of the appearance of the notes,
% and indeed of your whole document, will be the fonts used. We will
@@ -1954,7 +1960,7 @@
%
% \DescribeMacro{\ledinnernote}
% \DescribeMacro{\ledouternote}
-% \cs{ledleftnote}\marg{text} will put \meta{text} into the inner margin level
+% \cs{ledinnernote}\marg{text} will put \meta{text} into the inner margin level
% with where the command was issued. Similarly, \cs{ledouternote}\marg{text}
% puts \meta{text} in the outer margin.
%
@@ -2439,7 +2445,7 @@
% At the second run, you will see the formating.
% And consequently, at the third run, you will see the table of contents.
%
-% For technical reason, the page break before \cs{elechapter} can't be added automatically. You have to insert it manually via \cs{beforeeledchapter}, which must be called outside of a numbering section.
+% For technical reasons, the page break before \cs{elechapter} can't be added automatically. You have to insert it manually via \cs{beforeeledchapter}, which must be called outside of a numbering section.
% \DescribeMacro{\noeledsec}
% If you aren't going to have any \cs{eledxxx} commands, you can say \cs{noeledsec}
% in your file, before the first \cs{beginnumbering}, to suppress the
@@ -2844,7 +2850,7 @@
% \begin{macrocode}
%<*code>
\NeedsTeXFormat{LaTeX2e}
-\ProvidesPackage{eledmac}[2014/09/12 v1.12.8 LaTeX port of EDMAC]%
+\ProvidesPackage{eledmac}[2014/09/16 v1.13.0 LaTeX port of EDMAC]%
% \end{macrocode}
%
% Generally, these are the modifications to the original.
@@ -2864,15 +2870,22 @@
%
% \begin{macro}{\ifledfinal}
% \begin{macro}{\ifparapparatus@}
+% \begin{macro}{\ifnoquotation@}
+% \begin{macro}{\iflednopbinverse}
+% \begin{macro}{\ifparledgroup}
+% \begin{macro}{\ifwidthliketwocolumns}
+% \begin{macro}{\ifledsecnolinenumber}
% Use this to remember which option is used, set and execute the options
% with final as the default.
% \changes{v0.4}{2004/02/29}{Added final/draft options}
+% \changes{v1.13.0}{2014/09/16}{Added widthliketwocolumns option}
% \begin{macrocode}
\newif\ifledfinal
\newif\ifparapparatus@
\newif\ifnoquotation@
\newif\iflednopbinverse
\newif\ifparledgroup
+\newif\ifwidthliketwocolumns%
\newif\ifledsecnolinenumber
\parapparatus@false
\DeclareOption{noquotation}{\noquotation@true}
@@ -2881,6 +2894,7 @@
\DeclareOption{parapparatus}{\parapparatus@true}
\DeclareOption{nopbinverse}{\lednopbinversetrue}
\DeclareOption{ledsecnolinenumber}{\ledsecnolinenumbertrue}
+\DeclareOption{widthliketwocolumns}{\widthliketwocolumnstrue}%
\ExecuteOptions{final}
% \end{macrocode}
% Use the starred form of \verb?\ProcessOptions? which executes options in
@@ -2894,6 +2908,11 @@
% \end{macrocode}
% \end{macro}
% \end{macro}
+% \end{macro}
+% \end{macro}
+% \end{macro}
+% \end{macro}
+% \end{macro}
% 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.
@@ -3405,6 +3424,10 @@
\else
\begingroup
\initnumbering@sectcmd
+ \ifwidthliketwocolumns%
+ \csuse{setwidthliketwocolumns@\columns@position}%
+ \csuse{setpositionliketwocolumns@\columns@position}%
+ \fi%
\fi
\gdef\eled@sections@@{}%
\if@noeled@sec\else%
@@ -3440,6 +3463,7 @@
% input that require running the file through again to move everything
% to the right place.
% \changes{v0.7}{2005/02/24}{Changed \cs{endnumbering} for eledpar}
+% \changes{v1.12.5}{2014/08/31}{Allow to mix parallel columns and normal text when using \cs{pausenumbering}}
% \begin{macrocode}
\def\endnumbering{%
\ifnumbering
@@ -3466,6 +3490,7 @@
\immediate\closeout\eled@sectioning@out%
\fi%
\ifl@dpairing\else
+ \global\l@dnumpstartsL=\z@%
\endgroup
\fi
}
@@ -3490,6 +3515,7 @@
% by \cs{resumenumbering} to ensure that \cs{pausenumbering} was actually
% invoked.
% \changes{v0.7}{2005/02/24}{Changed \cs{resumenumbering} for eledpar}
+% \changes{v1.12.5}{2014/08/31}{Debug \cs{resumenumbering}}
% \begin{macrocode}
\newcommand*{\resumenumbering}{%
\ifnumbering
@@ -3499,8 +3525,14 @@
\led@mess@SectionContinued{\the\section@num}%
\line@list@stuff{\jobname.\extensionchars\the\section@num}%
\l@dend@stuff
- \begingroup
- \initnumbering@sectcmd
+ \ifl@dpairing\else%
+ \begingroup%
+ \initnumbering@sectcmd%
+ \ifwidthliketwocolumns%
+ \csuse{setwidthliketwocolumns@\columns@position}%
+ \csuse{setpositionliketwocolumns@\columns@position}%
+ \fi%
+ \fi%
\else
\led@err@NumberingShouldHaveStarted
\endnumbering
@@ -5953,6 +5985,18 @@
}
% \end{macrocode}
% \end{macro}
+% \begin{macro}{\dolinehook}
+% \begin{macro}{\doinsidelinehook}
+% These hight level commands just redefine the low level commands.
+% They have to be used be user, without \cs{makeatletter}.
+% \changes{v1.12.5}{2014/08/31}{Added \cs{dolinehook} and \cs{doinsidelinehook}}
+% \begin{macrocode}
+\newcommand*{\dolinehook}[1]{\gdef\do@linehook{#1}}%
+\newcommand*{\doinsidelinehook}[1]{\gdef\do@insidelinehook{#1}}%
+
+% \end{macrocode}
+% \end{macro}
+% \end{macro}
% \begin{macro}{\do@linehook}
% \begin{macro}{\do@insidelinehook}
% Two hooks into \cs{do@line}. The first is called at the beginning of \cs{do@line}, the second is called in the line box.
@@ -6707,7 +6751,7 @@
% \end{macrocode}
% \end{macro}
%
-% \section{Footnotes}
+% \section{Critical footnotes}
% \label{footnotes}\relax
%
% The footnote macros are adapted from those in \PlainTeX, but they
@@ -6854,6 +6898,10 @@
\csuse{bhookXnote@#1}
\csuse{Xnotefontsize@#1}
\footsplitskips
+ \ifl@dpairing%
+ \csuse{setwidthliketwocolumns@\columns@position}%
+ \fi%
+ \setXnotespositionliketwocolumns@{#1}%
\spaceskip=\z@skip \xspaceskip=\z@skip
\csname #1footfmt\endcsname #2[#1]\egroup}
% \end{macrocode}
@@ -7210,7 +7258,12 @@
}%
\vskip\skip\csname #1footins\endcsname%
\leftskip0pt \rightskip0pt
- \csname #1footnoterule\endcsname%
+ \ifl@dpairing\else%
+ \hsize=\old@hsize%
+ \fi%
+ \setXnoteswidthliketwocolumns@{#1}%
+ \setXnotespositionliketwocolumns@{#1}%
+ \print@Xfootnoterule{#1}%%
\vskip\csuse{afterXrule@#1}%
\noindent\leavevmode}
% \end{macrocode}
@@ -7231,7 +7284,11 @@
% contents of the footnote-insert box to the output page without
% alteration.
% \begin{macrocode}
-\newcommand*{\normalfootgroup}[1]{{\csuse{Xnotefontsize@#1}\noindent\csuse{txtbeforeXnotes@#1}}\unvbox\csname #1footins\endcsname}
+\newcommand*{\normalfootgroup}[1]{%
+ {\csuse{Xnotefontsize@#1}\noindent\csuse{txtbeforeXnotes@#1}}%
+ \unvbox\csname #1footins\endcsname%
+ \hsize=\old@hsize%
+ }%
% \end{macrocode}
% \end{macro}
@@ -7250,11 +7307,15 @@
\ifparledgroup%
\ifl@dpairing%
\else%
- \@nameuse{#1footnoterule}%
- \vskip\csuse{afterXrule@#1}%
+ \setXnoteswidthliketwocolumns@{#1}%
+ \setXnotespositionliketwocolumns@{#1}%
+ \print@Xfootnoterule{#1}%%
+ \vskip\csuse{afterXrule@#1}%
\fi%
\else%
- \@nameuse{#1footnoterule}%
+ \setXnoteswidthliketwocolumns@{#1}%
+ \setXnotespositionliketwocolumns@{#1}%
+ \print@Xfootnoterule{#1}%%
\vskip\csuse{afterXrule@#1}%
\fi%
\setlength{\parindent}{0pt}
@@ -7446,11 +7507,11 @@
% \changes{v0.2.2}{2003/11/04}{Added \cs{footfudgefiddle} to \cs{para@footsetup}}
% \begin{macrocode}
\newcommand*{\para@footsetup}[1]{{\csuse{Xnotefontsize@#1}
+ \setXnoteswidthliketwocolumns@{#1}%
\dimen0=\baselineskip
\multiply\dimen0 by 1024
\divide \dimen0 by \columnwidth \multiply\dimen0 by \footfudgefiddle\relax
- \expandafter
- \xdef\csname #1footfudgefactor\endcsname{%
+ \csxdef{#1footfudgefactor}{%
\expandafter\strip@pt\dimen0 }}}
% \end{macrocode}
@@ -7481,7 +7542,9 @@
{}%
}%
\vskip\skip\csname #1footins\endcsname%
- \csname #1footnoterule\endcsname%
+ \setXnoteswidthliketwocolumns@{#1}%
+ \setXnotespositionliketwocolumns@{#1}%
+ \print@Xfootnoterule{#1}%%
\vskip\csuse{afterXrule@#1}%
\noindent\leavevmode}
% \end{macrocode}
@@ -7696,7 +7759,9 @@
\makehboxofhboxes
\setbox0=\hbox{{\csuse{Xnotefontsize@#1}\csuse{txtbeforeXnotes@#1}}\unhbox0 \removehboxes}%
\csuse{Xnotefontsize@#1}
- \noindent\unhbox0\par}
+ \noindent\unhbox0\par%
+ \global\hsize=\old@hsize%
+ }%
% \end{macrocode}
% \end{macro}
@@ -7705,6 +7770,7 @@
% The minipage version.
% \begin{macrocode}
\newcommand*{\mppara@footgroup}[1]{{%
+ \setXnoteswidthliketwocolumns@{#1}%
\vskip\skip\@nameuse{mp#1footins}
\ifl@dpairing\ifparledgroup%
\leavevmode\marks\parledgroup@{begin}%
@@ -7714,12 +7780,16 @@
\ifparledgroup%
\ifl@dpairing%
\else%
- \@nameuse{#1footnoterule}%
- \vskip\csuse{afterXrule@#1}%
+ \setXnoteswidthliketwocolumns@{#1}%
+ \setXnotespositionliketwocolumns@{#1}%
+ \print@Xfootnoterule{#1}%%
+ \vskip\csuse{afterXrule@#1}%
\fi%
\else%
- \@nameuse{#1footnoterule}%
- \vskip\csuse{afterXrule@#1}%
+ \setXnoteswidthliketwocolumns@{#1}%
+ \setXnotespositionliketwocolumns@{#1}%
+ \print@Xfootnoterule{#1}%%
+ \vskip\csuse{afterXrule@#1}%
\fi%
\unvbox\csname mp#1footins\endcsname
\ifcsstring{Xragged@#1}{L}{\RaggedLeft}{}%
@@ -7965,11 +8035,15 @@
\ifparledgroup%
\ifl@dpairing%
\else%
- \@nameuse{#1footnoterule}%
- \vskip\csuse{afterXrule@#1}%
+ \setXnoteswidthliketwocolumns@{#1}%
+ \setXnotespositionliketwocolumns@{#1}%
+ \print@Xfootnoterule{#1}%%
+ \vskip\csuse{afterXrule@#1}%
\fi%
\else%
- \@nameuse{#1footnoterule}%
+ \setXnoteswidthliketwocolumns@{#1}%
+ \setXnotespositionliketwocolumns@{#1}%
+ \print@Xfootnoterule{#1}%%
\vskip\csuse{afterXrule@#1}%
\fi%
{\csuse{Xnotefontsize@#1}\noindent\csuse{txtbeforeXnotes@#1}}\par
@@ -8074,11 +8148,15 @@
\ifparledgroup%
\ifl@dpairing%
\else%
- \@nameuse{#1footnoterule}%
- \vskip\csuse{afterXrule@#1}%
+ \setXnoteswidthliketwocolumns@{#1}%
+ \setXnotespositionliketwocolumns@{#1}%
+ \print@Xfootnoterule{#1}%%
+ \vskip\csuse{afterXrule@#1}%
\fi%
\else%
- \@nameuse{#1footnoterule}%
+ \setXnoteswidthliketwocolumns@{#1}%
+ \setXnotespositionliketwocolumns@{#1}%
+ \print@Xfootnoterule{#1}%%
\vskip\csuse{afterXrule@#1}%
\fi%
{\csuse{Xnotefontsize@#1}\noindent\csuse{txtbeforeXnotes@#1}}\par
@@ -8285,6 +8363,10 @@
\csuse{bhooknoteX@#1}
\csuse{notefontsizeX@#1}
\footsplitskips
+ \ifl@dpairing%
+ \csuse{setwidthliketwocolumns@\columns@position}%
+ \fi%
+ \setnotesXpositionliketwocolumns@{#1}%
\spaceskip=\z@skip \xspaceskip=\z@skip
\csuse{\csuse{footnote@dir}}\if@RTL\else\noindent\leavevmode\fi\@nameuse{footfmt#1}{#1}{#2}\egroup}
@@ -8347,7 +8429,12 @@
\vskip\skip\csname footins#1\endcsname%
\leftskip=\z@
\rightskip=\z@
- \@nameuse{footnoterule#1}%
+ \ifl@dpairing\else%
+ \hsize=\old@hsize%
+ \fi%
+ \setnotesXwidthliketwocolumns@{#1}%
+ \setnotesXpositionliketwocolumns@{#1}%
+ \print@footnoteXrule{#1}%
\vskip\csuse{afterruleX@#1}}
% \end{macrocode}
@@ -8366,7 +8453,9 @@
% insert box to the output page without alteration.
% \begin{macrocode}
\newcommand*{\normalfootgroupX}[1]{%
- \unvbox\@nameuse{footins#1}}
+ \unvbox\@nameuse{footins#1}%
+ \hsize=\old@hsize%
+ }%
% \end{macrocode}
% \end{macro}
@@ -8384,11 +8473,15 @@
\ifparledgroup%
\ifl@dpairing%
\else%
- \@nameuse{footnoterule#1}%
- \vskip\csuse{afterruleX@#1}%
+ \setnotesXwidthliketwocolumns@{#1}%
+ \setnotesXpositionliketwocolumns@{#1}%
+ \print@footnoteXrule{#1}%
+ \vskip\csuse{afterruleX@#1}%
\fi%
\else%
- \@nameuse{footnoterule#1}%
+ \setnotesXwidthliketwocolumns@{#1}%
+ \setnotesXpositionliketwocolumns@{#1}%
+ \print@footnoteXrule{#1}%
\vskip\csuse{afterruleX@#1}%
\fi%
\unvbox\@nameuse{mpfootins#1}}
@@ -8558,11 +8651,15 @@
\ifparledgroup%
\ifl@dpairing%
\else%
- \@nameuse{footnoterule#1}%
- \vskip\csuse{afterruleX@#1}%
+ \setnotesXwidthliketwocolumns@{#1}%
+ \setnotesXpositionliketwocolumns@{#1}%
+ \print@footnoteXrule{#1}%
+ \vskip\csuse{afterruleX@#1}%
\fi%
\else%
- \@nameuse{footnoterule#1}%
+ \setnotesXwidthliketwocolumns@{#1}%
+ \setnotesXpositionliketwocolumns@{#1}%
+ \print@footnoteXrule{#1}%
\vskip\csuse{afterruleX@#1}%
\fi%
\splittopskip=\ht\strutbox
@@ -8661,11 +8758,15 @@
\ifparledgroup%
\ifl@dpairing%
\else%
- \@nameuse{footnoterule#1}%
- \vskip\csuse{afterruleX@#1}%
+ \setnotesXwidthliketwocolumns@{#1}%
+ \setnotesXpositionliketwocolumns@{#1}%
+ \print@footnoteXrule{#1}%
+ \vskip\csuse{afterruleX@#1}%
\fi%
\else%
- \@nameuse{footnoterule#1}%
+ \setnotesXwidthliketwocolumns@{#1}%
+ \setnotesXpositionliketwocolumns@{#1}%
+ \print@footnoteXrule{#1}%
\vskip\csuse{afterruleX@#1}%
\fi%
\splittopskip=\ht\strutbox
@@ -8707,11 +8808,13 @@
% \begin{macro}{\para@footsetupX}
% \cs{para@footsetupX}\marg{series}
% \changes{v0.2.2}{2003/11/04}{Added \cs{footfudgefiddle} to \cs{para@footsetupX}}
+% \changes{v1.13.0}{2014/09/16}{In \cs{para@footsetupX}, use \cs{columnwidth} instead of \cs{hsize}}
% \begin{macrocode}
\newcommand*{\para@footsetupX}[1]{{\csuse{notefontsizeX@#1}
+ \setnotesXwidthliketwocolumns@{#1}%
\dimen0=\baselineskip
\multiply\dimen0 by 1024
- \divide\dimen0 by \hsize \multiply\dimen0 by \footfudgefiddle\relax
+ \divide\dimen0 by \columnwidth \multiply\dimen0 by \footfudgefiddle\relax%
\expandafter
\xdef\csname footfudgefactor#1\endcsname{%
\expandafter\strip@pt\dimen0 }}}
@@ -8734,7 +8837,9 @@
\rightskip=\z@
\parindent=\z@
\vskip\skip\@nameuse{footins#1}%
- \@nameuse{footnoterule#1}%
+ \setnotesXwidthliketwocolumns@{#1}%
+ \setnotesXpositionliketwocolumns@{#1}%
+ \print@footnoteXrule{#1}%
\vskip\csuse{afterruleX@#1}%
}
@@ -8805,6 +8910,7 @@
\csuse{notefontsizeX@#1}
\noindent\unhbox0\par}
\newcommand*{\mppara@footgroupX}[1]{{%
+ \setnotesXwidthliketwocolumns@{#1}%
\vskip\skip\@nameuse{mpfootins#1}
\ifl@dpairing\ifparledgroup
\leavevmode%
@@ -8815,12 +8921,16 @@
\ifparledgroup%
\ifl@dpairing%
\else%
- \@nameuse{footnoterule#1}%
- \vskip\csuse{afterruleX@#1}%
+ \setnotesXwidthliketwocolumns@{#1}%
+ \setnotesXpositionliketwocolumns@{#1}%
+ \print@footnoteXrule{#1}%
+ \vskip\csuse{afterruleX@#1}%
\fi%
\else%
- \@nameuse{footnoterule#1}%
- \vskip\csuse{afterruleX@#1}%
+ \setnotesXwidthliketwocolumns@{#1}%
+ \setnotesXpositionliketwocolumns@{#1}%
+ \print@footnoteXrule{#1}%
+ \vskip\csuse{afterruleX@#1}%
\fi%
\unvbox\csname mpfootins#1\endcsname
\ifcsstring{raggedX@#1}{L}{\RaggedLeft}{}%
@@ -8834,8 +8944,72 @@
% \end{macro}
% \end{macro}
%
-%
-% \subsection{Footnotes' order}
+% \section{Footnotes' width for two columns}
+% We define here some commands which make sense only with \Lpack{eledpar}, but must be called when defining notes paramaters.
+% These commands change the width of block notes to allow them to have the same size than two parallel columns.
+% \begin{macro}{\old@hsize}
+% \begin{macro}{\setXnoteswidthliketwocolumns@}
+% \begin{macro}{\setnotesXwidthliketwocolumns@}
+% These two commands are called at the beginning of critical or familiar notes groups.
+% They set, if the option is enabled, the \cs{hsize}. They are also called at the on the setup for paragraphed notes.
+% \begin{macrocode}
+
+\newdimen\old@hsize%
+\old@hsize=\hsize%
+
+\newcommand{\setXnoteswidthliketwocolumns@}[1]{%
+ \global\let\hsize@fornote=\hsize%
+ \old@hsize=\hsize%
+ \iftoggle{Xnoteswidthliketwocolumns@#1}%
+ {%
+ \csuse{setwidthliketwocolumns@\columns@position}%
+ \global\let\hsize@fornote=\hsize%
+ }%
+ {}%
+ \let\hsize=\hsize@fornote%
+ \let\columnwidth=\hsize@fornote%
+}%
+
+\newcommand{\setnotesXwidthliketwocolumns@}[1]{%
+ \global\let\hsize@fornote=\hsize%
+ \old@hsize=\hsize%
+ \iftoggle{notesXwidthliketwocolumns@#1}%
+ {%
+ \csuse{setwidthliketwocolumns@\columns@position}%
+ \global\let\hsize@fornote=\hsize%
+ }%
+ {}%
+ \let\hsize=\hsize@fornote%
+ \let\columnwidth=\hsize@fornote%
+}%
+
+% \end{macrocode}
+% \end{macro}
+% \end{macro}
+% \end{macro}
+% \begin{macro}{\setXnotespositionliketwocolumns@}
+% \begin{macro}{\setnotesXpositionliketwocolumns@}
+% These two commands set the position of the critical / familiar
+% footnotes, depending on the hooks
+% \verb+Xnoteswidthliketwocolumns+ and \verb+notesXwidthliketwocolumns+.
+% They call commands which are defined only in \Lpack{eledpar}, because this feature has no sens without \Lpack{eledpar}.
+% \begin{macrocode}
+\newcommand{\setXnotespositionliketwocolumns@}[1]{%
+ \iftoggle{Xnoteswidthliketwocolumns@#1}{%
+ \csuse{setnotespositionliketwocolumns@\columns@position}%
+ }{}%
+}%
+
+\newcommand{\setnotesXpositionliketwocolumns@}[1]{%
+ \iftoggle{notesXwidthliketwocolumns@#1}{%
+ \csuse{setnotespositionliketwocolumns@\columns@position}%
+ }{}%
+}%
+
+% \end{macrocode}
+% \end{macro}
+% \end{macro}
+% \section{Footnotes' order}
% \begin{macro}{\fnpos}
% \begin{macro}{\mpfnpos}
% \begin{macro}{\@fnpos}
@@ -8851,12 +9025,27 @@
% \end{macro}
% \end{macro}
% \end{macro}
-% \subsection{Footnotes' output}
+% \section{Footnotes' rule}
+% Because the footnotes' rules can be shifted to the right when footnotes are set like two columns, we don't print them directly, but we put them in a \cs{vbox}.
%
+% \begin{macro}{\print@Xfootnoterule}
+% \begin{macro}{\print@footnoteXrule}
+% \begin{macrocode}
+\newcommand{\print@Xfootnoterule}[1]{%
+ \moveleft-\leftskip\vbox{\csuse{#1footnoterule}}%
+ \nointerlineskip%
+}%
+\newcommand{\print@footnoteXrule}[1]{%
+ \moveleft-\leftskip\vbox{\csuse{footnoterule#1}}%
+ \nointerlineskip%
+}%
+
+% \end{macrocode}
+% \end{macro}
+% \end{macro}
%
-%
-%
+% \section{Footnotes' output}
% \begin{macro}{\doxtrafeeti}
% \begin{macro}{\doreinxtrafeeti}
% We have to add all the new kinds of familiar footnotes to the output
@@ -9171,6 +9360,8 @@
\csgdef{txtbeforeXnotes@#1}{}
\csgdef{maxhnotesX@#1}{\ledfootinsdim}%
\csgdef{maxhXnotes@#1}{\ledfootinsdim}
+ \newtoggle{Xnoteswidthliketwocolumns@#1}%
+ \newtoggle{notesXwidthliketwocolumns@#1}%
% \end{macrocode}
% \subsection{Create inserts, needed to add notes in foot}
% Concerning inserts, see chapter 15 of the TeXBook by D. Knuth
@@ -9331,10 +9522,20 @@
% \subsubsection{Options}
% \begin{macro}{\settoggle@series}
% \changes{v1.1}{2012/09/25}{\cs{settoggle@series} switch the global value of the toggle, not only the local value.}
-% \cs{settoggle@series}\cs{series}{toggle}{value} is a generic command to switch one toggle for one series.
+% \changes{v1.13.0}{2014/09/16}{\cs{settoggle@series} can take an optional arguments to reload series setup.}
+% \cs{settoggle@series}\marg{series}\marg{toggle}\marg{value} is a generic command to switch toggles for some series.
+
% \begin{macrocode}
-\newcommand{\settoggle@series}[3]{%
- \def\do##1{\global\settoggle{#2@##1}{#3}}
+\newcommandx{\settoggle@series}[4][4]{%
+ \def\do##1{%
+ \global\settoggle{#2@##1}{#3}%
+ \ifstrequal{#4}{reload}%
+ {%
+ \csuse{foot\csuse{series@display##1}}{##1}%
+ \csuse{foot\csuse{series@displayX##1}}{##1}%
+ }%
+ {}%
+ }%
\ifstrempty{#1}{%
\dolistloop{\@series}%
}%
@@ -9345,7 +9546,7 @@
% \end{macrocode}
% \end{macro}
% \begin{macro}{\setcommand@series}
-% \cs{setcommand@series}\marg{series}\marg{command}\marg{value} is a generic command to change one command for one series.
+% \cs{setcommand@series}\marg{series}\marg{command}\marg{value} is a generic command to change commands for some series.
% \begin{macrocode}
\newcommandx{\setcommand@series}[4][4]{%
\def\do##1{
@@ -9367,7 +9568,9 @@
% \cs{newhookcommand@series}\cs{command names} is a generic command to add new commands for hooks, like \cs{hsizetwocol}.
% \begin{macrocode}
\newcommand{\newhookcommand@series}[1]{%
- \global\expandafter\newcommand\expandafter*\csname #1\endcsname[2][]{\csuse{setcommand@series}{##1}{#1}{##2}}%
+ \global\expandafter\newcommand\expandafter*\csname #1\endcsname[2][]{%
+ \setcommand@series{##1}{#1}{##2}%
+ }%
}
\newhookcommand@series{Xhangindent}
@@ -9448,7 +9651,7 @@
% \begin{macrocode}
\newcommand{\newhookcommand@series@reload}[1]{%
\global\expandafter\newcommand\expandafter*\csname #1\endcsname[2][]{%
- \csuse{setcommand@series}{##1}{#1}{##2}[reload]
+ \setcommand@series{##1}{#1}{##2}[reload]%
}%
}
\newhookcommand@series@reload{beforeXnotes}
@@ -9464,7 +9667,9 @@
%\cs{newhooktoggle@series}\cs{command names} is a generic command to add new commands for new toggle hook, like \cs{numberonlyfirstinline}.
% \begin{macrocode}
\newcommand{\newhooktoggle@series}[1]{%
- \global\expandafter\newcommandx\expandafter*\csname #1\endcsname[2][1,2={true},usedefault]{\settoggle@series{##1}{#1}{##2}}%
+ \global\expandafter\newcommandx\expandafter*\csname #1\endcsname[2][1,2={true},usedefault]{%
+ \settoggle@series{##1}{#1}{##2}%
+ }%
}
\newhooktoggle@series{numberonlyfirstinline}
\newhooktoggle@series{numberonlyfirstintwolines}
@@ -9476,6 +9681,22 @@
\newhooktoggle@series{Xendlemmadisablefontselection}
% \end{macrocode}
% \end{macro}
+% \begin{macro}{\newhooktoggle@series}
+% \changes{v1.13.0}{2014/09/16}{Add \cs{newhookcommand@toggle@reload}}
+% \cs{newhookcommand@toggle@reload} does the same thing as \cs{newhooktoggle@series}
+% but the commands created by this macro also reload the series displaying (normal, paragraph, twocol, threecol).
+% \begin{macrocode}
+\newcommand{\newhooktoggle@series@reload}[1]{%
+ \global\expandafter\newcommandx\expandafter*\csname #1\endcsname[2][1,2={true},usedefault]{%
+ \settoggle@series{##1}{#1}{##2}[reload]%
+ }%
+}%
+
+\newhooktoggle@series@reload{Xnoteswidthliketwocolumns}%
+\newhooktoggle@series@reload{notesXwidthliketwocolumns}%
+
+% \end{macrocode}
+% \end{macro}
% \subsection{Old commands, kept for backward compatibility}
% The next commands are kept for ascendant compatibily, but should'nt be used anymore.
% \begin{macro}{\notenumfont}
@@ -10522,7 +10743,7 @@
\newcommand*{\ledrightnote}[1]{\edtext{}{\l@drsnote{#1}}}
\newcommand*{\ledinnernote}[1]{%
- \ifodd\c@page% Do not use \page@num, because not yet calculated when command is called
+ \ifodd\c@page% Do not use \page@num, because it is not yet calculated when command is called
\ledleftnote{#1}%
\else%
\ledrightnote{#1}%
@@ -10530,7 +10751,7 @@
}
\newcommand*{\ledouternote}[1]{%
- \ifodd\c@page% Do not use \page@num, because not yet calculated when command is called
+ \ifodd\c@page% Do not use \page@num, because it is not yet calculated when command is called
\ledrightnote{#1}%
\else%
\ledleftnote{#1}%
@@ -11298,7 +11519,7 @@
% \end{macrocode}
% \end{macro}
% \begin{macro}{\hyperlinkR}
-% \cs{hyperlinkR} command is to be used to have both a internal hyperlink \cs{ledRflag}, when indexing.
+% \cs{hyperlinkR} command is to be used to create a internal hyperlink and \cs{ledRflag}, when indexing.
% \begin{macrocode}
\newcommand{\hyperlinkR}[2]{%
\hyperlink{#1}{#2\Rlineflag}%
@@ -11307,7 +11528,7 @@
% \end{macrocode}
% \end{macro}
% \begin{macro}{\hyperlinkformatR}
-% \cs{hyperlinkformatR} command is to be used to have both a internal hyperlink, a format and a \cs{Rlineflag}, when indexing.
+% \cs{hyperlinkformatR} command is to be used to create a internal hyperlink, a format and a \cs{Rlineflag}, when indexing.
% \begin{macrocode}
\newcommand{\hyperlinkformatR}[3]{%
\hyperlinkformat{#1}{#2}{#3\Rlineflag}%
@@ -11317,7 +11538,7 @@
% \end{macro}
% \begin{macro}{\get@edindex@hyperref}
% \begin{macro}{\@edindex@hyperref}
-% \changes{v1.12.5}{2014/08/28}{Debug \cs{edindex} when \Lpack{hyperref} is not load}
+% \changes{v1.12.5}{2014/08/28}{Debug \cs{edindex} when \Lpack{hyperref} is not loaded}
% \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]{%
diff --git a/Master/texmf-dist/source/latex/eledmac/eledpar.dtx b/Master/texmf-dist/source/latex/eledmac/eledpar.dtx
index 8aec3e74504..59a3a2395d8 100644
--- a/Master/texmf-dist/source/latex/eledmac/eledpar.dtx
+++ b/Master/texmf-dist/source/latex/eledmac/eledpar.dtx
@@ -51,7 +51,7 @@
%
% \fi
%
-% \CheckSum{4601}
+% \CheckSum{4749}
%
% \makeatletter
% \newcommand*{\DescribeIt}{\leavevmode\@bsphack\begingroup\MakePrivateLetters
@@ -174,12 +174,13 @@
% \changes{v1.7.0}{2014/04/14}{Add, as in eledmac, features to make crossrefs with pstart numbers.}
% \changes{v1.8.0}{2014/08/05}{Debug eledmac sectioning command after using \cs{resumenumbering}.}
% \changes{v1.8.0}{2014/08/05}{Compatibility with \Lpack{musixtex}.}
-% \changes{v1.8.0}{2014/08/05}{Add, as in eledmac, possibility to insert something after \cs{pend}s / verses.}
-% \changes{v1.8.0}{2014/08/05}{Add, as in eledmac, possibility to insert something between \cs{pstart}s / verse.}
+% \changes{v1.8.0}{2014/08/05}{Add, as in eledmac, option to insert something after \cs{pend}s / verses.}
+% \changes{v1.8.0}{2014/08/05}{Add, as in eledmac, option to insert something between \cs{pstart}s / verse.}
% \changes{v1.8.0}{2014/08/05}{Add, as in eledmac, new system of sectioning commands.}
% \changes{v1.8.2}{2014/08/15}{Debug left and side note (bugs added by 1.8.0)}
-% \changes{v1.8.2}{2014/08/15}{Debug \cs{eledxxx} with some paper size}
+% \changes{v1.8.2}{2014/08/15}{Debug \cs{eledxxx} with some paper sizes}
% \changes{v1.8.3}{2014/08/31}{Add \cs{noeledxxx}, as in eledmac}
+% \changes{v1.9.0}{2014/09/16}{Compatibility with \cs{Xnoteswidthliketwocolumns} and \cs{notesXwidthliketwocolumns}}
% \hyphenation{man-u-script man-u-scripts}
%
%
@@ -363,6 +364,13 @@
% \end{pairs}
% \end{verbatim}
%
+% \DescribeMacro{\AtBeginPairs}
+% \changes{v1.9.0}{2014/09/16}{Add \cs{AtBeginPairs} macro.}
+% You can use the macro \cs{AtBeginPairs} to insert a code at the begining of each \verb+pairs+ environments.
+% That could be useful to add the \cs{sloppy} macro to prevent overfull hboxes in two columns.
+% \begin{verbatim}
+% \AtBeginPairs{\sloppy}
+% \end{verbatim}
% There is no required pagebreak before or after the columns.
%
% \DescribeMacro{\Lcolwidth}
@@ -405,6 +413,12 @@
% \setlength{\aftercolumseparator}{length}
% \end{verbatim}
% If you want to come back to the previous behavior, just set them with a negative value.
+% \DescribeMacro{\widthliketwocolumns}
+% If you want to mix texts in columns and text without columns, you can horizontally align text in one column to text in two columns with \cs{widthliketwocolumnstrue}. To reset this feature, just use \cs{widthliketwocolumnsfalse}.
+%
+% \DescribeMacro{\Xnoteswidthliketwocolumns}
+% \DescribeMacro{\notesXwidthliketwocolumns}
+% In most case, you should use \cs{widthliketwocolumns} in combination with \cs{Xnoteswidthliketwocolumns} and \cs{notesXwidthliketwocolumns} to align the critical/familiar footnotes with the two colums. \Lpack{eledmac} handbook for more details.
% \section{Facing pages}\label{pages}
%
% \DescribeEnv{pages}
@@ -718,7 +732,7 @@
%
%
%
-% \DescribeMacro{\hangingsymbol}Like in eledmac, you could redefine the command \cmd{\hangingsymbol} to insert a character in each hanged line. If you use it, you must run \LaTeX\ two time. Example for the french typographie
+% \DescribeMacro{\hangingsymbol}Like in eledmac, you could redefine the command \cmd{\hangingsymbol} to insert a character in each hanging line. If you use it, you must run \LaTeX\ two time. Example for the French typography
%\begin{verbatim}
%\renewcommand{\hangingsymbol}{[\,}
%\end{verbatim}
@@ -800,15 +814,14 @@
% \endnumbering
% \end{..side}
% \end{verbatim}
-% \subsection{Parallel ledgroups and \Lpack{setspace} package}.
-% If you use the \Lpack{setspace} package and want your notes in parallel ledgroups ledgroups to be single-spaced (not half-spaced or double-spaced), just add to your preamble:
+% \subsection{Parallel ledgroups and \Lpack{setspace} package}
+% If you use the \Lpack{setspace} package and want your notes in parallel ledgroups to be single-spaced (not half-spaced or double-spaced), just add to your preamble:
% \begin{verbatim}
% \let\parledgroupnotespacing\singlespacing
% \end{verbatim}
% \emph{In effect, to have correct spacing, don't change the font size of your notes}.
% \StopEventually{}
%
-% \clearpage
% \section{Sectioning commands}
% \changes{v1.8.0}{2014/08/05}{New sectioning commands, as in eledmac.}
% The standard sectioning commands of eledmac are available, and provide parallel sectionings, for both two-column and two-page layout.
@@ -855,7 +868,7 @@
% \begin{macrocode}
%<*code>
\NeedsTeXFormat{LaTeX2e}
-\ProvidesPackage{eledpar}[2014/08/31 v1.8.3 eledmac extension for parallel texts]%
+\ProvidesPackage{eledpar}[2014/09/16 v1.9.0 eledmac extension for parallel texts]%
% \end{macrocode}
% With the option `shiftedpstarts' a long pstart one the left side (or in the right side) don't make a blank on the corresponding pstart, but the blank is put on the bottom of the page. Consequently, the pstarts on the parallel pages are shifted, but the shifted stop at every end of pages.
@@ -868,9 +881,18 @@
\DeclareOption{shiftedverses}{\shiftedpstartstrue}
\DeclareOption{shiftedpstarts}{\shiftedpstartstrue}
\DeclareOption{parledgroup}{\parledgrouptrue}
-\ProcessOptions
% \end{macrocode}
% \end{macro}
+% \begin{macro}{\ifwidthliketwocolumns}
+% The \cs{widthliketwocolumns} option can be called both in eledpar and eledmac.
+% \changes{v1.9.0}{2014/09/16}{Added widthliketwocolumns option}
+% \begin{macrocode}
+\DeclareOption{widthliketwocolumns}{\widthliketwocolumnstrue}%
+% \end{macrocode}
+% \end{macro}
+% \begin{macrocode}
+\ProcessOptions%
+% \end{macrocode}
% As noted above, much of the code is a duplication of the original
% \Eledmac{} code to handle the extra box(es) for the right hand side text,
% and sometimes for the left hand side as well. In order to distinguish
@@ -1082,6 +1104,7 @@
% \begin{macro}{\resumenumberingR}
% These are the right text equivalents of \cs{pausenumbering} and
% \cs{resumenumbering}.
+% \changes{v1.8.3}{2014/08/31}{Debug \cs{resumenumberingR}}
% \begin{macrocode}
\newcommand*{\pausenumberingR}{%
\endnumberingR\global\numberingRtrue}
@@ -1092,7 +1115,8 @@
\led@mess@SectionContinued{\the\section@numR R}%
\line@list@stuffR{\jobname.\extensionchars\the\section@numR R}%
\l@dend@stuff
- \initnumbering@sectcmd
+ \begingroup%
+ \initnumbering@sectcountR%
\else
\led@err@numberingShouldHaveStarted
\endnumberingR
@@ -2329,10 +2353,20 @@
\l@dpairingtrue
\l@dpagingfalse
\initnumbering@sectcmd
+ \at@begin@pairs%
}{%
\l@dpairingfalse
}
+
% \end{macrocode}
+% \begin{macro}{\AtBeginPairs}
+% The \cs{AtBeginPairs} macro just define a \cs{at@begin@pairs} macro, called at the begining of each \verb+pairs+ environments.
+% \begin{macrocode}
+\newcommand{\AtBeginPairs}[1]{\xdef\at@begin@pairs{#1}}%
+\def\at@begin@pairs{}%
+
+% \end{macrocode}
+% \end{macro}
% The \verb?pages? environment additionally sets the `column' widths to the
% \cs{textwidth} (as known at the time the package is called). In this environment, there are two text in parallel on 2 pages. To prevent chapters starting on a lefthand page, the \cs{chapter} command is redefined to not clear pages.
% \begin{macrocode}
@@ -2805,6 +2839,7 @@
\l@dlsn@te %space kept for backward compatibility
{\ledllfill\hb@xt@ \wd\one@line{\do@insidelineLhook\inserthangingsymbolL\new@lineL\l@dunhbox@line{\one@line}}\correcthangingL\ledrlfill\l@drd@ta%
\l@drsn@te}}
+
% \end{macrocode}
% \end{macro}
% \begin{macro}{\print@eledsectionL}
@@ -2830,8 +2865,27 @@
\fi%
\vskip\eledsection@correcting@skip%
}
+
% \end{macrocode}
% \end{macro}
+% \begin{macro}{\dolineLhook}
+% \begin{macro}{\dolineRhook}
+% \begin{macro}{\doinsidelineLhook}
+% \begin{macro}{\doinsidelineRhook}
+% \changes{v1.8.3}{2014/08/31}{Added \cs{dolineLhook}, \cs{dolineRhook}, \cs{doinsidelineLhook} and \cs{doinsidelineRhook}}
+% These high-level commands just redefine the low-level commands.
+% They have to be used be user, without \cs{makeatletter}.
+% \begin{macrocode}
+\newcommand*{\dolineLhook}[1]{\gdef\do@lineLhook{#1}}%
+\newcommand*{\dolineRhook}[1]{\gdef\do@lineRhook{#1}}%
+\newcommand*{\doinsidelineLhook}[1]{\gdef\do@insidelineLhook{#1}}%
+\newcommand*{\doinsidelineRhook}[1]{\gdef\do@insidelineRhook{#1}}%
+
+% \end{macrocode}
+% \end{macro}
+% \end{macro}
+% \end{macro}
+% \end{macro}
% \changes{v0.3}{2005/02/10}{Added \cs{do@lineLhook} and \cs{do@lineRhook}}
% \changes{v1.4}{2013/07/11}{Added \cs{do@insidelineLhook} and \cs{do@insidelineRhook}}
% \begin{macro}{\do@lineLhook}
@@ -4091,6 +4145,7 @@
% \end{macrocode}
% If on Polyglossia
% \changes{v1.8.0}{2014/08/05}{Correct left/right language setting with polyglossia.}
+% \changes{v1.9.0}{2014/09/16}{Debug left/right language switching with polyglossia. Don't write in .aux file when setting left/right lines.}
% \begin{macrocode}
{ \let\old@otherlanguage\otherlanguage%
\renewcommand{\otherlanguage}[2][]{%
@@ -4098,10 +4153,10 @@
\ifledRcol \gdef\theledlanguageR{#2}%
\else \gdef\theledlanguageL{#2}%
\fi}%
- \let\l@duselanguage\xpg@set@language%
+ \let\l@duselanguage\select@language%
\gdef\theledlanguageL{\xpg@main@language}%
\gdef\theledlanguageR{\xpg@main@language}%
-% \end{macrocode}
+% \end{macrocode}
% That's it.
% \begin{macrocode}
}}
@@ -4112,6 +4167,80 @@
% \end{macro}
%
%
+% \begin{macro}{\if@pstarts}
+% \begin{macro}{\@pstartstrue}
+% \begin{macro}{\@pstartsfalse}
+% \begin{macro}{\check@pstarts}
+% \cs{check@pstarts} returns \cs{@pstartstrue} if there are any unprocessed
+% chunks.
+% \begin{macrocode}
+\newif\if@pstarts
+\newcommand*{\check@pstarts}{%
+ \@pstartsfalse
+ \ifnum\l@dnumpstartsL>\l@dpscL
+ \@pstartstrue
+ \else
+ \ifnum\l@dnumpstartsR>\l@dpscR
+ \@pstartstrue
+ \fi
+ \fi
+}
+
+% \end{macrocode}
+% \end{macro}
+% \end{macro}
+% \end{macro}
+% \end{macro}
+%
+% \begin{macro}{\ifaraw@text}
+% \begin{macro}{\araw@texttrue}
+% \begin{macro}{\araw@textfalse}
+% \begin{macro}{\checkraw@text}
+% \cs{checkraw@text} checks whether the current Left or Right box is
+% void or not. If one or other is not void it sets \cs{araw@texttrue},
+% otherwise both are void and it sets \cs{araw@textfalse}.
+% \begin{macrocode}
+\newif\ifaraw@text
+ \araw@textfalse
+\newcommand*{\checkraw@text}{%
+ \araw@textfalse
+ \ifvbox\namebox{l@dLcolrawbox\the\l@dpscL}
+ \araw@texttrue
+ \else
+ \ifvbox\namebox{l@dRcolrawbox\the\l@dpscR}
+ \araw@texttrue
+ \fi
+ \fi
+}
+
+% \end{macrocode}
+% \end{macro}
+% \end{macro}
+% \end{macro}
+% \end{macro}
+%
+%
+% \begin{macro}{\@writelinesinparL}
+% \begin{macro}{\@writelinesinparR}
+% These write the number of text lines in a chunk to the section files,
+% and then afterwards zero the counter.
+% \begin{macrocode}
+\newcommand*{\@writelinesinparL}{%
+ \edef\next{%
+ \write\linenum@out{\string\@pend[\the\@donereallinesL]}}%
+ \next
+ \global\@donereallinesL \z@}
+\newcommand*{\@writelinesinparR}{%
+ \edef\next{%
+ \write\linenum@outR{\string\@pendR[\the\@donereallinesR]}}%
+ \next
+ \global\@donereallinesR \z@}
+
+% \end{macrocode}
+% \end{macro}
+% \end{macro}
+%
+%
% \section{Parallel columns}
%
% \begin{macro}{\@eledsectionL}
@@ -4336,82 +4465,146 @@
\newlength{\aftercolumnseparator}%
\setlength{\aftercolumnseparator}{-2pt}%
+
% \end{macrocode}
% \end{macro}
% \end{macro}
-% \begin{macro}{\if@pstarts}
-% \begin{macro}{\@pstartstrue}
-% \begin{macro}{\@pstartsfalse}
-% \begin{macro}{\check@pstarts}
-% \cs{check@pstarts} returns \cs{@pstartstrue} if there are any unprocessed
-% chunks.
+%
+% \begin{macro}{setwidthliketwocolumns@L}
+% \begin{macro}{setpositionliketwocolumns@L}
+% \begin{macro}{setnotepositionliketwocolumns@L}
+% \begin{macro}{setwidthliketwocolumns@C}
+% \begin{macro}{setpositionliketwocolumns@C}
+% \begin{macro}{setnotepositionliketwocolumns@C}
+% \begin{macro}{setwidthliketwocolumns@R}
+% \begin{macro}{setpositionliketwocolumns@R}
+% \begin{macro}{setnotepositionliketwocolumns@R}
+% The \cs{setwidth…} macros are called in \cs{beginnumbering} in a \textbf{not parallel}
+% typesetting, to fix the width of the lines to be vertically aligned with parallel columns. They are also called at the beginning of a note's group, if some options are enabled.
+% The \cs{setposition…} macros are called in \cs{beginnumbering} in a \textbf{not parallel} to fix the position of the lines.
+% The \cs{setnoteposition…} macros are called \cs{xxxfootstart} in a \textbf{not parallel} to fix the position of notes block.
+% \begin{macrocode}
+\newcommand{\setwidthliketwocolumns@L}{%
+% Temporary dimension, initially equal to the standard hsize, i.e. text width
% \begin{macrocode}
-\newif\if@pstarts
-\newcommand*{\check@pstarts}{%
- \@pstartsfalse
- \ifnum\l@dnumpstartsL>\l@dpscL
- \@pstartstrue
- \else
- \ifnum\l@dnumpstartsR>\l@dpscR
- \@pstartstrue
- \fi
- \fi
-}
+ \newdimen\temp%
+ \temp=\hsize%
+% \end{macrocode}
+% Hsize : Left + Right width
+% \begin{macrocode}
+ \hsize=\Lcolwidth%
+ \advance\hsize\Rcolwidth%
+% \end{macrocode}
+% Now, calculating the remaining space
+% \begin{macrocode}
+ \advance\temp-\hsize%
+% \end{macrocode}
+% And multiply the hsize by 2/3 of this space
+% \begin{macrocode}
+ \multiply\temp by 2%
+ \divide\temp by 3%
+ \advance\hsize\temp%
+}%
+
+\newcommand{\setpositionliketwocolumns@L}{%
+ \renewcommand{\ledrlfill}{\hfill}%
+}%
+
+\newcommand{\setnotespositionliketwocolumns@L}{%
+}%
+
+
+% \end{macrocode}
+% \begin{macrocode}
+\newcommand{\setwidthliketwocolumns@C}{%
+% Temporary dimension, initially equal to the standard hsize, i.e. text width
+% \end{macrocode}
+% \begin{macrocode}
+ \newdimen\temp%
+ \temp=\hsize%
+% Hsize : Left + Right width
+% \end{macrocode}
+% \begin{macrocode}
+ \hsize=\Lcolwidth%
+ \advance\hsize\Rcolwidth%
+% Now, calculating the remaining space
+% \end{macrocode}
+% \begin{macrocode}
+ \advance\temp-\hsize%
+% \end{macrocode}
+% And multiply the hsize by 1/2 of this space
+% \begin{macrocode}
+ \divide\temp by 2%
+ \advance\hsize\temp%
+}%
+
+\newcommand{\setpositionliketwocolumns@C}{%
+ \doinsidelinehook{\hfill}%
+ \renewcommand{\ledrlfill}{\hfill}%
+}%
+
+\newcommand{\setnotespositionliketwocolumns@C}{%
+ \newdimen\temp%
+ \newdimen\tempa%
+ \temp=\hsize%
+ \tempa=\Lcolwidth%
+ \advance\tempa\Rcolwidth%
+ \advance\temp-\tempa%
+ \divide\temp by 2%
+ \leftskip=\temp%
+ \rightskip=-\temp%
+}%
+
+\newcommand{\setwidthliketwocolumns@R}{%
+% \end{macrocode}
+% Temporary dimension, initially equal to the standard hsize, i.e. text width
+% \begin{macrocode}
+ \newdimen\temp%
+ \temp=\hsize%
+% \end{macrocode}
+% Hsize : Left + Right width
+% \begin{macrocode}
+ \hsize=\Lcolwidth%
+ \advance\hsize\Rcolwidth%
+% \end{macrocode}
+% Now, calculating the remaining space
+% \begin{macrocode}
+ \advance\temp-\hsize%
+% \end{macrocode}
+% And multiply the hsize by 2/3 of this space
+% \begin{macrocode}
+ \multiply\temp by 2%
+ \divide\temp by 3%
+ \advance\hsize\temp%
+}%
+
+\newcommand{\setpositionliketwocolumns@R}{%
+ \doinsidelinehook{\hfill}%
+}%
+
+\newcommand{\setnotespositionliketwocolumns@R}{%
+ \newdimen\temp%
+ \newdimen\tempa%
+ \temp=\hsize%
+ \tempa=\Lcolwidth%
+ \advance\tempa\Rcolwidth%
+ \advance\temp-\tempa%
+ \divide\temp by 2%
+ \leftskip=\temp%
+ \rightskip=-\temp%
+}%
% \end{macrocode}
% \end{macro}
% \end{macro}
% \end{macro}
% \end{macro}
-%
-% \begin{macro}{\ifaraw@text}
-% \begin{macro}{\araw@texttrue}
-% \begin{macro}{\araw@textfalse}
-% \begin{macro}{\checkraw@text}
-% \cs{checkraw@text} checks whether the current Left or Right box is
-% void or not. If one or other is not void it sets \cs{araw@texttrue},
-% otherwise both are void and it sets \cs{araw@textfalse}.
-% \begin{macrocode}
-\newif\ifaraw@text
- \araw@textfalse
-\newcommand*{\checkraw@text}{%
- \araw@textfalse
- \ifvbox\namebox{l@dLcolrawbox\the\l@dpscL}
- \araw@texttrue
- \else
- \ifvbox\namebox{l@dRcolrawbox\the\l@dpscR}
- \araw@texttrue
- \fi
- \fi
-}
-
-% \end{macrocode}
-% \end{macro}
% \end{macro}
% \end{macro}
% \end{macro}
-%
-%
-% \begin{macro}{\@writelinesinparL}
-% \begin{macro}{\@writelinesinparR}
-% These write the number of text lines in a chunk to the section files,
-% and then afterwards zero the counter.
-% \begin{macrocode}
-\newcommand*{\@writelinesinparL}{%
- \edef\next{%
- \write\linenum@out{\string\@pend[\the\@donereallinesL]}}%
- \next
- \global\@donereallinesL \z@}
-\newcommand*{\@writelinesinparR}{%
- \edef\next{%
- \write\linenum@outR{\string\@pendR[\the\@donereallinesR]}}%
- \next
- \global\@donereallinesR \z@}
-
-% \end{macrocode}
% \end{macro}
% \end{macro}
-%
+%
% \section{Parallel pages}
%
% This is considerably more complicated than parallel columns.
@@ -4430,8 +4623,6 @@
% \end{macro}
% \end{macro}
% \end{macro}
-%
-%
% \begin{macro}{\Pages}
% \changes{v1.8.0}{2014/07/28}{Modify \cs{Pages} to enable to add section's title.}
% \changes{v1.8.3}{2014/08/31}{Debug blank pages when using optional argument in the last \cs{pend}.}
@@ -5119,7 +5310,7 @@
\newskip\eledsection@correcting@skip
% \end{macrocode}
% \end{macro}
-% \begin{macro}
+% \begin{macro}{\eled@sectioningR@out}
% We save the sectioning commands of the right side in the \cs{eled@sectioningR@out} file.
% \begin{macrocode}
\newwrite\eled@sectioningR@out