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 drew a tree with the qtree package. However, this tree has no consistent baseline.

Screenshot:

enter image description here

MWE:

\documentclass{scrreprt}
\usepackage{qtree}
\begin{document}

  \Tree[.table 
         [.thead 
           [.tr 
             [.th [.\textit{Vorname} ] ]
             [.th [.\textit{Nachname} ] ]
           ]
         ]              
         [.tbody 
           [.tr 
             [.td [.\textit{Donald} ] ]
             [.td [.\textit{Duck} ] ]
           ]
         ]
       ]

\end{document}

How do I get a consistent baseline?

share|improve this question

1 Answer 1

up vote 3 down vote accepted

Without changing anything in your tree-syntax, the tikz-qtree package allows you to get the right result:

\documentclass{scrreprt}
\usepackage{tikz-qtree}
\begin{document}

  \Tree[.table 
         [.thead 
           [.tr 
             [.th [.\textit{Vorname} ] ]
             [.th [.\textit{Nachname} ] ]
           ]
         ]              
         [.tbody 
           [.tr 
             [.td [.\textit{Donald} ] ]
             [.td [.\textit{Duck} ] ]
           ]
         ]
       ]

\end{document}

gives:

enter image description here

share|improve this answer
    
Thank you very much! –  Benny Neugebauer Feb 23 '13 at 12:45
    
@BennyNeugebauer: you're welcome :) –  Claudio Fiandrino Feb 23 '13 at 14:44

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.