summaryrefslogtreecommitdiff
path: root/Master/texmf-dist/source/latex/eledmac/eledmac.dtx
diff options
context:
space:
mode:
authorKarl Berry <karl@freefriends.org>2012-11-18 00:44:30 +0000
committerKarl Berry <karl@freefriends.org>2012-11-18 00:44:30 +0000
commit470ffcd8dbbbffcee050065eb4671f7581e02024 (patch)
treef27083f65b637fa451347892f3184c735e474fee /Master/texmf-dist/source/latex/eledmac/eledmac.dtx
parent38f5841b2d128e31223c2cbace56b0416b3e806f (diff)
eledmac (17nov12)
git-svn-id: svn://tug.org/texlive/trunk@28288 c570f23f-e606-0410-a88d-b1316a301751
Diffstat (limited to 'Master/texmf-dist/source/latex/eledmac/eledmac.dtx')
-rw-r--r--Master/texmf-dist/source/latex/eledmac/eledmac.dtx63
1 files changed, 37 insertions, 26 deletions
diff --git a/Master/texmf-dist/source/latex/eledmac/eledmac.dtx b/Master/texmf-dist/source/latex/eledmac/eledmac.dtx
index fe879f3293a..5aee1d6971a 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{8188}
+% \CheckSum{8205}
%
% \makeatletter
% \newcommand*{\DescribeIt}{\leavevmode\@bsphack\begingroup\MakePrivateLetters
@@ -2277,6 +2277,9 @@
% The typographical consequences will resemble the outside numbered sections, based on the styles of the \emph{book} class.
% However, if you use a package that redefines these environments, these redefinitions won't be available inside the numbering section.
% You must open the quotation environments inside a \cs{start}-\cs{pend} block, not outside.
+%
+% In some case, you don't want these environments be redefined in numbered section.
+% You can load the package with the option \verb+noquotation+ to prevent this redefinition.
% \section{Miscellaneous}
%
%
@@ -2647,7 +2650,7 @@
% \begin{macrocode}
%<*code>
\NeedsTeXFormat{LaTeX2e}
-\ProvidesPackage{eledmac}[2012/11/16 v1.4 LaTeX port of EDMAC]
+\ProvidesPackage{eledmac}[2012/11/16 v1.4.1 LaTeX port of EDMAC]
% \end{macrocode}
%
% In general there is the following modifications to the original
@@ -2673,7 +2676,9 @@
% \begin{macrocode}
\newif\ifledfinal
\newif\ifparapparatus@
+\newif\ifnoquotation@
\parapparatus@false
+\DeclareOption{noquotation}{\noquotation@true}
\DeclareOption{final}{\ledfinaltrue}
\DeclareOption{draft}{\ledfinalfalse}
\DeclareOption{parapparatus}{\parapparatus@true}
@@ -3124,6 +3129,7 @@
% \begin{macro}{\endquote}
% \changes{v1.2}{2012/10/08}{Compatibility of \cs{ledchapter} with the \emph{memoir} class.}
% \changes{v1.3}{2012/11/01}{\emph{Quotation} and {quote} environment inside the numbering sections.}
+% \changes{v1.4.1}{2012/11/16}{New option \emph{noquotation}.}
% \cs{initnumbering@sectcmd} defines sectioning commands inside numbered section.
% It also defines quotation environment.
% Note that it's suppose user didn't change \cs{chapter}.
@@ -3187,6 +3193,7 @@
\newcommand\beforeledchapter{\pend\cleardoublepage\pstart}
\patchcmd{\chapter}{\cleardoublepage}{\relax}{}{}
\patchcmd{\chapter}{\clearpage}{\relax}{}{}
+ \ifnoquotation@\else
\renewcommand{\quotation}{\par\leavevmode%
\parindent=1.5em%
\skipnumbering%
@@ -3231,6 +3238,7 @@
\vskip\topsep%
\fi%
}
+ \fi
}
% \end{macrocode}
% \end{macro}
@@ -7800,18 +7808,19 @@
% \verb?\vl@dbfnote? calls the original \verb?\@footnotetext?.
% \changes{v0.6}{2004/11/23}{Changed \cs{l@dbfnote} and \cs{vl@dbfnote} as
% originals could give incorrect markers in the footnotes}
+% \changes{v1.4.1}{2012/11/16}{Compatibility of standard footnotes with eledmac when theses footnotes contain any commands.}
% \begin{macrocode}
\newcommand{\l@dbfnote}[1]{%
\ifnumberedpar@
- \xright@appenditem{\noexpand\vl@dbfnote{{#1}}{\@thefnmark}}%
+ \gdef\@tag{#1}
+ \xright@appenditem{\noexpand\vl@dbfnote{{\csexpandonce{@tag}}}{\@thefnmark}}%
\to\inserts@list
\global\advance\insert@count \@ne
\fi\ignorespaces}
\newcommand{\vl@dbfnote}[2]{%
\def\@thefnmark{#2}%
\l@doldold@footnotetext{#1}}
-
-% \end{macrocode}
+% \end{macrocode}
% \end{macro}
% \end{macro}
%
@@ -9385,22 +9394,23 @@
%\begin{macro}{\advancelabel@refs}
%\begin{macro}{\labelrefsparseline}
%\begin{macro}{\labelrefsparsesubline}
-% \begin{macrocode}
+% \changes{v1.4.1}{2012/11/16}{Fix bug with \cs{edlabel}.}
%In cases where \cs{edlabel} is the first element in a paragraph, we have a problem with line counts, because line counts change only at the first horizontal box of the paragraph.
%Hence, we need to test \cs{edlabel} if it occurs at the start of a paragraph. To do so, we use \cs{ifvmode}. If the test is true, we must advance by one unit the amount of text we write into the \verb].aux] file.
-%We do so using \cs[advancelabel@refs} command.
+% We do so using \cs{advancelabel@refs} command.
+% \begin{macrocode}
+\newcounter{line}%
+\newcounter{subline}%
\newcommand{\advancelabel@refs}{%
- \newcounter{line}%
\setcounter{line}{\expandafter\labelrefsparseline\label@refs}%
\stepcounter{line}%
\ifsublines@%
- \newcounter{subline}%
\setcounter{subline}{\expandafter\labelrefsparsesubline\label@refs}%
\stepcounter{subline}{1}%
- \def\label@refs{\theline|\thesubline}%
+ \def\label@refs{\theline|\thesubline}%
\else%
\def\label@refs{\theline|0}%
-\fi%
+ \fi%
}
\def\labelrefsparseline#1|#2{#1}
\def\labelrefsparsesubline#1|#2{#2}
@@ -10038,6 +10048,7 @@
%
% Before do it, we concatenate all moveable sidenotes of the line, using \cs{sidenotesep} as separator.
% It's the result that we put on the sidenote.
+% \changes{v1.4.1}{2012/11/16}{Remove spurious spaces.}
% \begin{macrocode}
\newcommand*{\affixside@note}{%
\def\sidenotecontent@{}%
@@ -10051,29 +10062,29 @@
\numdef{\itemcount@}{\itemcount@+1}%
}%
\dolistloop{\l@dcsnotetext}%
- \ifnumgreater{\itemcount@}{1}{\eledmac@warning{\itemcount@\space sidenotes on line \the\line@num\space p. \the\page@num,}}{}
+ \ifnumgreater{\itemcount@}{1}{\eledmac@warning{\itemcount@\space sidenotes on line \the\line@num\space p. \the\page@num,}}{}%
% \end{macrocode}
% And now, the main part of the macro
% \begin{macrocode}
\gdef\@templ@d{}%
- \ifx\@templ@d\l@dcsnotetext \else
- \if@twocolumn
- \if@firstcolumn
+ \ifx\@templ@d\l@dcsnotetext \else%
+ \if@twocolumn%
+ \if@firstcolumn%
\setl@dlp@rbox{##1}{\sidenotecontent@}%
- \else
+ \else%
\setl@drp@rbox{\sidenotecontent@}%
- \fi
- \else
- \@l@dtempcntb=\sidenote@margin
- \ifnum\@l@dtempcntb>\@ne
- \advance\@l@dtempcntb by\page@num
- \fi
- \ifodd\@l@dtempcntb
+ \fi%
+ \else%
+ \@l@dtempcntb=\sidenote@margin%
+ \ifnum\@l@dtempcntb>\@ne%
+ \advance\@l@dtempcntb by\page@num%
+ \fi%
+ \ifodd\@l@dtempcntb%
\setl@drp@rbox{\sidenotecontent@}%
- \else
+ \else%
\setl@dlp@rbox{\sidenotecontent@}%
- \fi
- \fi
+ \fi%
+ \fi%
\fi}
% \end{macrocode}
% \end{macro}