6

I'm using paracol to build a document composed by a header, followed by text in two columns, as in the example:

\documentclass[11pt, a4paper]{article} \usepackage{paracol,lipsum} \begin{document} \lipsum[1] \vspace{1cm} \columnratio{0.29,0.69} \begin{paracol}{2} \setlength{\columnseprule}{0.4pt} \setlength{\columnsep}{2em} \begin{leftcolumn} \section{Section One} \lipsum [1-2] \end{leftcolumn} \begin{rightcolumn} \section{section two} \lipsum[3-4] \end{rightcolumn} \end{paracol} \end{document} 

which gives:

enter image description here

How can I remove the excess in the rule length above the section titles, but keeping the rule in the rest of the text? In other words: how can I set the rule length?

0

1 Answer 1

11

First I fixed the line-breaking problem with \sloppy (SOP for narrow columns). Next I used \globalcounter{section} to fix the section numbers. Finally I erased the top part of the line between the columns with white-out.

\documentclass[11pt, a4paper]{article} \usepackage{paracol,lipsum} \usepackage{xcolor} \globalcounter{section} \begin{document} \lipsum[1] \vspace{1cm} \setcolumnwidth{0.29\textwidth,0.69\textwidth} \begin{paracol}{2} \setlength{\columnseprule}{0.4pt} \setlength{\columnsep}{2em} \begin{leftcolumn} \sloppy \section{Section One} \lipsum [1-2] \end{leftcolumn} \begin{rightcolumn} \section{section two} \leavevmode\llap{\smash{\color{white}\rule[\ht\strutbox]{\columnsep}{2cm}}}% erase top \lipsum[3-4] \end{rightcolumn} \end{paracol} \end{document} 

full page

4
  • Under both MacTeX 2016 and 2017 (pretest) your code does not compile: Undefined control sequence. l.12 \columnratio {0.29,0.69}. Odd. I checked the documentation and everything looks right... Commented May 24, 2017 at 13:52
  • @sgmoye - In any case, it was being used incorrectly. Commented May 24, 2017 at 14:06
  • My bad. I found an old copy of paracol in my ~/texmf directory. Sorry for the noise. Commented May 24, 2017 at 14:07
  • I had to change the size of white thing covering the rule, but it worked well. Thanks! Commented May 25, 2017 at 16:35

You must log in to answer this question.

Start asking to get answers

Find the answer to your question by asking.

Ask question

Explore related questions

See similar questions with these tags.