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.

I am using the multicol package to make a 2 columns based document but I want in a place to have just fusion these two columns, and then go back to the 2 columns but I can't figure out how to achieve this.

share|improve this question
add comment

2 Answers

up vote 8 down vote accepted

Here's a generalized version of Tom Bombadil's \multicolinterrupt macro: The current value of \col@number is saved before ending the multicols environment, and after typesetting the "interruption" text a new multicols environment with the same number of columns as the last one is started.

\documentclass[parskip]{scrartcl}
\usepackage[margin=15mm]{geometry}
\usepackage{lipsum}
\usepackage{multicol}
\usepackage{xcolor}

\newcounter{tempcolnum}

\makeatletter
\newcommand{\multicolinterrupt}[1]{% Stuff to span both rows
\setcounter{tempcolnum}{\col@number}
\end{multicols}
#1%
\begin{multicols}{\value{tempcolnum}}
}
\makeatother

\begin{document}

\begin{multicols}{3}
\lipsum[1-2]
\multicolinterrupt{\textcolor{blue}{\lipsum[3-4]}}
\lipsum[5-6]
\end{multicols}

\end{document}
share|improve this answer
    
Nice, I was wondering if the current column number was somehow accessible, but was, to be honest, too lazy to look it up :) –  Tom Bombadil Jun 9 '12 at 10:56
add comment

Probably like this?

\documentclass[parskip]{scrartcl}
\usepackage[margin=15mm]{geometry}
\usepackage{lipsum}
\usepackage{multicol}
\usepackage{xcolor}

\newcommand{\multicolinterrupt}[1]{% Stuff to span both rows
\end{multicols}
#1
\begin{multicols}{2}
}

\begin{document}

\begin{multicols}{2}
\lipsum[1-2]
\multicolinterrupt{\textcolor{blue}{\lipsum[3-4]}}
\lipsum[5-6]
\end{multicols}

\end{document}

enter image description here

share|improve this answer
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.