Anonymous
2014-11-25 18:37:38 UTC
This is roughly what I need:
===8<------------------------------
field1 field2
this is a lower text line that is longer than the above
===8<------------------------------
What's important is that the east of field2 is vertically aligned with
the east of the lower line. I know I could make this happen with one
large node, but I need 3 separate nodes so I can draw lines and
reference the positions of the text.
When I request that alignment, this is roughly what I get:
===8<------------------------------
field1 field2
this is a lower text line that is longer than the above
===8<------------------------------
What's wrong with this code?
===8<------------------------------
\documentclass{minimal}
\usepackage{tikz}
\usetikzlibrary{positioning}
\usepackage[pdftex,active,tightpage]{preview}
\PreviewEnvironment{tikzpicture}
\begin{document}
\begin{tikzpicture}
\node (upr-fld-1) {field1};
\node [anchor=west] (upr-fld-2) [right =of upr-fld-1] {field2};
\node [anchor=north east] (lower) [below =of upr-fld-2.east] {%
this is a lower text line that is longer than the above};
\end{tikzpicture}
\end{document}
===8<------------------------------
===8<------------------------------
field1 field2
this is a lower text line that is longer than the above
===8<------------------------------
What's important is that the east of field2 is vertically aligned with
the east of the lower line. I know I could make this happen with one
large node, but I need 3 separate nodes so I can draw lines and
reference the positions of the text.
When I request that alignment, this is roughly what I get:
===8<------------------------------
field1 field2
this is a lower text line that is longer than the above
===8<------------------------------
What's wrong with this code?
===8<------------------------------
\documentclass{minimal}
\usepackage{tikz}
\usetikzlibrary{positioning}
\usepackage[pdftex,active,tightpage]{preview}
\PreviewEnvironment{tikzpicture}
\begin{document}
\begin{tikzpicture}
\node (upr-fld-1) {field1};
\node [anchor=west] (upr-fld-2) [right =of upr-fld-1] {field2};
\node [anchor=north east] (lower) [below =of upr-fld-2.east] {%
this is a lower text line that is longer than the above};
\end{tikzpicture}
\end{document}
===8<------------------------------