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 would like to create a series of horizontally linked 'text boxes', with arrows between each one. Each box will contain some text (probably a list with a title). I would like it to look something like this: enter image description here

What would be the best package/method for going about doing this?

Ideally, the overall width of the three boxes would be automatically resized to fill the full width of the column they are in, but this is only a secondary requirement.

(I realise that this is effectively a flow chart—however, all the flowchart packages I've come across seem more suited to the free-form, spidery flowcharts and seem to be overkill for this purpose. Feel free to suggest them nonetheless if they are suitable.)

share|improve this question
add comment

3 Answers

up vote 8 down vote accepted

A quick and dirty solution (without any extra package):

\fbox{\parbox[t]{6em}{Title \#1\\Item\\Item\\Item\\Item}}%
\raisebox{-4ex}{$\to$}%
\fbox{\parbox[t]{6em}{Title \#2\\Item\\Item\\Item\\Item\\Item}}%
\raisebox{-4ex}{$\to$}%
\fbox{\parbox[t]{6em}{Title \#3\\Item\\Item\\Item}}

And you can define some commands for convenience.

\newcommand\mybox[2][6em]{%
  \raisebox{4ex}{\fbox{\parbox[t]{#1}{#2}}}}
\newcommand\Rarrow{$\rightarrow$}

\mybox{Title \#1\\Item\\Item\\Item\\Item}%
\Rarrow
\mybox{Title \#2\\Item\\Item\\Item\\Item\\Item}%
\Rarrow
\mybox{Title \#3\\Item\\Item\\Item}

This is enough, if the requested diagrams are very simple. However, for more complicated diagrams (at arbitrary position, with curves, shaded boxes, etc.), it is better to use more powerful tools, like tikz and pstricks.

share|improve this answer
    
Thanks, this is exactly what I was looking for. I think I'll also set another input to the \mybox for the title. –  Bill Cheatham Feb 17 '11 at 16:01
add comment

This doesn't exactly meet up with the example output, but I wanted to try my hand at this because the given picture sort of looks like just a bunch of boxes stacked after each other:

\def\repeating#1{\vcenter{\offinterlineskip
  \halign{\vrule\strut\enspace##\hfil\quad\vrule\cr
    \noalign{\hrule}#1\noalign{\hrule}}}}
\def\title#1{\vphantom{$\Big($}\bf#1}
$ \repeating{\title{Title \#1}\cr Item\cr Item\cr Item\cr Item\cr}
\mathord{\longrightarrow}
  \repeating{\title{Title \#2}\cr Item\cr Item\cr Item\cr Item\cr Item\cr Item\cr}
\mathord{\longrightarrow}
  \repeating{\title{Title \#3}\cr Item\cr Item\cr Item\cr} $
\bye

enter image description here

I am still wondering if I could somehow make the \halign's \vcenter a \vtop instead, and the \longrightarrows inside a \vcenter, but I haven't yet got that to work.

share|improve this answer
add comment

perhaps tikz block diagrams may aid you?

http://www.texample.net/tikz/examples/tag/block-diagrams/

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.