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 do I insert an image from text in two columns so that the text go around the picture?enter image description here

share|improve this question
    
wrapfig should be able to do this with some "manual intervention". See How to use wrapfig to span multiple columns. –  Werner Nov 11 '11 at 3:21
3  
You really should provide more information with your questions, otherwise you run the risk of making the impression that you're not willing to do any research by yourself. How do you generate the shape (is it an image, is it a TikZ shape)? Why did other solutions (like tex.stackexchange.com/questions/32997/…) not work for you? –  Jake Nov 11 '11 at 3:25

1 Answer 1

up vote 8 down vote accepted

As Werner mentioned, the wrapfig package can do this sort of thing; a little example (you can replace the black rectangle with an image or a \parbox containing text, for example):

\documentclass[twocolumn]{article}
\usepackage{wrapfig}

\newcommand\Text{Lorem ipsum dolor sit amet, consectetuer adipiscing elit. Ut purus elit,
vestibulum ut, placerat ac, adipiscing vitae, felis. Curabitur dictum gravida
mauris. Nam arcu libero, nonummy eget, consectetuer id, vulputate a, magna.
Donec vehicula augue eu neque. Pellentesque habitant morbi tristique senectus
et netus et malesuada fames ac turpis egestas. Mauris ut leo.}

\begin{document}

\Text\Text\Text
\begin{wrapfigure}[8]{r}[\dimexpr.5\width+.5\columnsep\relax]{6cm}
  \centering
  \rule{5cm}{2.5cm}
\end{wrapfigure}%
\Text\Text\Text\Text\Text Lorem ipsum dolor sit amet, consectetuer adipiscing elit. Ut purus elit, vestibulum ut, placerat ac, adipiscing vitae, felis. Curabitur dictum gravida
mauris. Nam arcu libero, nonummy eget, consectetuer id, vulputate a, magna.
Donec vehicula augue eu neque. Pellentesque habitant morbi tristique senectus
et netus et malesuada fames ac turpis egestas. Lorem ipsum 
\begin{wrapfigure}[8]{l}[\dimexpr.5\width+.5\columnsep\relax]{6cm}
\vfill
\end{wrapfigure} 

 \noindent dolor sit amet, consectetuer adipiscing elit. Ut purus elit,
vestibulum ut, placerat ac, adipiscing vitae, felis. Curabitur dictum gravida
mauris. Nam arcu libero, nonummy eget, consectetuer id, vulputate a, magna.
Donec vehicula augue eu neque. Pellentesque habitant morbi tristique senectus
et netus et malesuada fames ac turpis egestas.\Text

\end{document}

enter image description here

The exact instructions on how to produce this type of layout can be found in the file multiple-span.txt.

I don't know a package allowing to easily create circular cutouts (shapepar could be an option but I've never used it), but using the \parshape primitive is possible (with some effort) to manually produce a circular cutout and then use, for example, TikZ to place some material; a little example:

\documentclass[twocolumn]{article}
\usepackage{lipsum}
\usepackage{tikz}
\usetikzlibrary{calc}

\begin{document}

\lipsum[1]
\parshape16 0cm \linewidth 
0cm \linewidth 
0cm \linewidth 
0cm \linewidth 
0cm \dimexpr\linewidth-1.1cm\relax
0cm \dimexpr\linewidth-1.6cm\relax
0cm \dimexpr\linewidth-1.9cm\relax
0cm \dimexpr\linewidth-2.15cm\relax
0cm \dimexpr\linewidth-2.25cm\relax
0cm \dimexpr\linewidth-2.27cm\relax
0cm \dimexpr\linewidth-2.25cm\relax
0cm \dimexpr\linewidth-2.15cm\relax
0cm \dimexpr\linewidth-1.9cm\relax
0cm \dimexpr\linewidth-1.6cm\relax
0cm \dimexpr\linewidth-1.1cm\relax
0cm \linewidth
\lipsum[1-3] 
\parshape16 0cm \linewidth 
0cm \linewidth 
0cm \linewidth 
0cm \linewidth 
1.1cm \dimexpr\linewidth-1.1cm\relax
1.6cm \dimexpr\linewidth-1.6cm\relax
1.9cm \dimexpr\linewidth-1.9cm\relax
2.15cm \dimexpr\linewidth-2.15cm\relax
2.25cm \dimexpr\linewidth-2.25cm\relax
2.27cm \dimexpr\linewidth-2.27cm\relax
2.25cm \dimexpr\linewidth-2.25cm\relax
2.15cm \dimexpr\linewidth-2.15cm\relax
1.9cm \dimexpr\linewidth-1.9cm\relax
1.6cm \dimexpr\linewidth-1.6cm\relax
1.1cm \dimexpr\linewidth-1.1cm\relax
0cm \linewidth
\lipsum[1]

\begin{tikzpicture}[remember picture, overlay]
\fill[blue!30] ($(current page.center)+(0,-2.1cm)$) circle [radius=63pt,fill=blue!30];
\end{tikzpicture}

\end{document}

enter image description here

share|improve this answer
    
And circle shape is also possible? –  Regis da Silva Nov 11 '11 at 4:15
    
@RegisdaSilva: see my updated answer. –  Gonzalo Medina Nov 11 '11 at 14:35
    
Very good. Perfect. Thank you. –  Regis da Silva Nov 11 '11 at 23:04
    
Dimensions as you draw the circle? Manually? –  Regis da Silva Nov 12 '11 at 1:36
    
And if one column? How to do? –  Regis da Silva Nov 12 '11 at 1:48

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.