5

After karlkoeller cam up with a solution for How to allow page breaks within footnotes, when using dblfnote? I really like to use it but unfortunately the styling of the footnotes isn’t flexible enough. The following MWE shows war I want to have and what I got so far …

\documentclass{scrbook}

% WHAT I WANT
%\deffootnotemark{\textsuperscript{\thefootnotemark}}
%\usepackage{dblfnote}% Setzt die Fußnoten zweispaltig
%   \DFNtrysingle
%   \renewcommand\footnoterule{\vspace*{-3pt}%
%        \vspace*{2.6pt}%
%   }
%   \setlength{\DFNcolumnsep}{1.5em}
%   \setlength{\skip\footins}{1\baselineskip plus 20pt minus 5pt}
%\deffootnote{1.4em}{1em}{%
%   \makebox[1.4em][l]{\thefootnotemark}%
%}
%\setkomafont{footnote}{\itshape}

% WHAT I GOT
\usepackage{eledmac,etoolbox}
   \patchcmd{\twocolfootfmtX}{\raggedright}{}{}{}
   \foottwocolX{C}

   \renewcommand\Cfootnoterule{\vspace*{-3pt}\vspace*{2.6pt}}
   \setlength{\skip\Cfootins}{1\baselineskip plus 20pt minus 5pt}

   \Xhangindent[C]{1.4em}
   \afternumberinfootnote[C]{0em}
   \boxlinenum[C]{1.4em}

   \notenumfontX[C]{\itshape}

   \newlength{\fncolwidth}
      \setlength{\fncolwidth}{0.5\textwidth}
      \addtolength{\fncolwidth}{-0.75em}
   \hsizetwocol[C]{\fncolwidth}

   \let\footnote\footnoteC


\usepackage{lipsum}
\setlength{\parskip}{0pt}

\begin{document}
   Lipsum\footnote{\lipsum[1]} \lipsum[1]
   Lipsum\footnote{\lipsum[2]} \lipsum[3]
   Lipsum\footnote{\lipsum[2-4]} \lipsum[2]
   Lipsum\footnote{\lipsum[2]} \lipsum[1]
\end{document}

In my real document I furthermore got the problem, that the column gap doesn’t work:

trouble with column spacing

4

With some formatting, here is more or less what you are trying to achieve...

\documentclass{scrbook}

\usepackage{eledmac}

\notenumfontX[C]{\itshape}
\hsizetwocolX[C]{\dimexpr.5\columnwidth-.75em\relax}
\hangindentX[C]{1.4em}

\renewcommand\footnoteruleC{\relax}
\setlength{\skip\footinsC}{1\baselineskip plus 20pt minus 5pt}


\makeatletter
\renewcommand*{\twocolfootfmtX}[2]{%
   \protected@edef\@currentlabel{%
       \@nameuse{@thefnmark#1}%
   }%
  \normal@pars
  \everypar{\hangindent=\csuse{hangindentX@#1}}%
  \hsize \csuse{hsizetwocolX@#1}
  \parindent=\z@
%%%  \parfillskip=0pt \@plus 1fil
  \tolerance=5000\relax
  \leavevmode
  {\csuse{notenumfontX@#1}\@nameuse{footfootmark#1}\strut%\enspace
    #2\strut\par}\allowbreak}
\makeatother

\foottwocolX{C}

\let\footnote\footnoteC

\usepackage{lipsum}

\setlength{\parskip}{0pt}

\begin{document}
   Lipsum\footnote{\lipsum[1]} \lipsum[1]
   Lipsum\footnote{\lipsum[2]} \lipsum[3]
   Lipsum\footnote{\lipsum[2-4]} \lipsum[2]
   \lipsum[2-4]\footnote{\lipsum[2]} \lipsum[1]
\end{document} 

enter image description here

  • Thanks for this code. Is it possible to control the vertical space between the notes and to make it a little flexible so that both columns flush at the bottom (in the example the left one is slightly higher)? – Tobi Mar 22 '15 at 15:18
2

The column gap doesn't work because you don't set it.

\hsizetwocol[C]{\fncolwidth} is for setting column width for critical notes.

\hsizetwocolX[C]{\fncolwidth} is for setting column width for familiar notes.

1

This is the fromat I created based on karl's answer:

\documentclass{scrbook}

\setlength{\parskip}{0pt}

\usepackage{eledmac}

\notenumfontX[C]{\itshape}% actually this will be
                          % a condenses upright font

\renewcommand\footnoteruleC{\relax}
\setlength{\skip\footinsC}{1\baselineskip plus 20pt minus 5pt}

\hsizetwocolX[C]{\dimexpr.5\columnwidth-.75em\relax}
\hangindentX[C]{1.4em}
\makeatletter
\renewcommand*{\twocolfootfmtX}[2]{%
   \protected@edef\@currentlabel{%
      \@nameuse{@thefnmark#1}%
   }%
   \normal@pars
   %\everypar{\hangindent=\csuse{hangindentX@#1}}%
   \hsize \csuse{hsizetwocolX@#1}
   \setlength{\parskip}{0pt}%
   %\addtolength{\parindent}{\csuse{hangindentX@#1}}
   %%%  \parfillskip=0pt \@plus 1fil
   \tolerance=5000\relax
   \leavevmode
   {%
      \hspace*{-\parindent}%
      \csuse{notenumfontX@#1}%
      \makebox[1.4em][l]{%
         \textbf{\@nameuse{@thefnmark#1}}%
         %\strut%\enspace
      }%
   #2\strut\par
   }%
   \allowbreak
}
\renewcommand*{\normalbodyfootmarkX}[1]{%
   \textsuperscript{\@nameuse{@thefnmark#1}}%
}
\makeatother

\foottwocolX{C}
\let\footnote\footnoteC

\usepackage{lipsum}

\begin{document}
   Lipsum\footnote{\lipsum[1]} \lipsum[1]
   Lipsum\footnote{\lipsum[2]} \lipsum[3]
   Lipsum\footnote{\lipsum[2-4]} \lipsum[2]
   \lipsum[2-4]\footnote{\lipsum[2]} \lipsum[1]
\end{document} 

result

  • Since you've modified the code, I'll answer here. Simply remove the % before \strut in the line %\strut%\enspace. – karlkoeller Mar 22 '15 at 16:18
  • @karlkoeller: Thanks, adding the \strut back again actually makes both columns aligned. But could you explain, where the vertical space comes from? And why the baselineskip is to small if I remove both \struts? – Tobi Mar 22 '15 at 16:39
  • I'm sorry, no.... – karlkoeller Mar 22 '15 at 18:20
  • you shoul note override \twocolfootfmtX.Except for the bug with geometry (which you didn't speak here), it's preferable to ask for new LaTeX hooks. Any new \renwcommand is problematic for the compatibility with future version of eledmac. – Maïeul Mar 22 '15 at 22:32
  • for example, for the footnotemark in box, you could use – Maïeul Mar 22 '15 at 22:38

Your Answer

By clicking “Post Your Answer”, you agree to our terms of service, privacy policy and cookie policy

Not the answer you're looking for? Browse other questions tagged or ask your own question.