Take the 2-minute tour ×
TeX - LaTeX Stack Exchange is a question and answer site for users of TeX, LaTeX, ConTeXt, and related typesetting systems. It's 100% free, no registration required.

How can I style the vertical bar in parcolumns that appears when using rulebetween=true?

I am trying to do something similar to what you can do with \vrule like the below:

\newcommand\VRule{\color{gray}\vrule width 0.5pt}

Here is what I have currently:

\documentclass{article}
\usepackage[margin=1in]{geometry}% http://ctan.org/pkg/geometry
\usepackage{lipsum}% http://ctan.org/pkg/lipsum
\usepackage{parcolumns}% http://ctan.org/pkg/parcolumns
\begin{document}
    \begin{parcolumns}[nofirstindent,colwidths={1=2cm},rulebetween=true]{2}
        \colchunk[1]{\noindent 1770 }
        \colchunk[2]{\noindent \lipsum [1-3]}
    \end{parcolumns}
\end{document}
share|improve this question
add comment

1 Answer

up vote 4 down vote accepted

Just patch the \pc@placeboxes command; be sure to provide a definition for \VRULE, however.

\documentclass{article}
\usepackage[margin=1in]{geometry}
\usepackage{lipsum}
\usepackage{parcolumns}
\usepackage{color}

\usepackage{etoolbox}
\makeatletter
\patchcmd{\pc@placeboxes}{\vrule}{{\VRULE}}{}{}
\makeatother
\newcommand\VRULE{\color{red}\vrule width 0.5pt}


\begin{document}

\begin{parcolumns}[nofirstindent,colwidths={1=2cm},rulebetween=true]{2}
\colchunk[1]{\noindent 1770 }
\colchunk[2]{\noindent \lipsum [1-3]}
\end{parcolumns}

\end{document}

enter image description here

share|improve this answer
    
This will alter every \vrule below the \patchcmd though correct? –  Ryan Gates Jan 27 '13 at 17:21
1  
@RyanGates Only every dividing rule produced by parcolumns. If you \renewcommand{\VRULE}{...} in between two such environments, you can change the appearance of it. –  egreg Jan 27 '13 at 17:23
    
@HarishKumar I keep doing that mistake, thanks. :) –  egreg Jan 27 '13 at 23:04
    
Thank you for clarifying. –  Ryan Gates Jan 28 '13 at 19:41
add comment

Your Answer

 
discard

By posting your answer, you agree to the privacy policy and terms of service.

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