summaryrefslogtreecommitdiff
path: root/macros/latex/contrib/textpos/examples/t5.tex
diff options
context:
space:
mode:
Diffstat (limited to 'macros/latex/contrib/textpos/examples/t5.tex')
-rw-r--r--macros/latex/contrib/textpos/examples/t5.tex66
1 files changed, 66 insertions, 0 deletions
diff --git a/macros/latex/contrib/textpos/examples/t5.tex b/macros/latex/contrib/textpos/examples/t5.tex
new file mode 100644
index 0000000000..37a181c87d
--- /dev/null
+++ b/macros/latex/contrib/textpos/examples/t5.tex
@@ -0,0 +1,66 @@
+%%% Testing:spacing
+\documentclass{article}
+
+\usepackage{textpos}
+%\usepackage[showboxes]{textpos}
+
+\hoffset=0pt
+\voffset=0pt
+\oddsidemargin=0pt
+\topmargin=0pt
+\headheight=0pt
+\headsep=0pt
+
+\setlength{\TPHorizModule}{50pt}
+\setlength{\TPVertModule}{\TPHorizModule}
+
+\pagestyle{empty}
+
+\begin{document}
+
+\setlength{\parindent}{0pt}
+\setlength{\parskip}{30pt}
+\setlength{\baselineskip}{20pt}
+
+% Make sure that all text appears precisely where it ought to. The
+% above dimensions mean that text appears in round-number locations.
+%
+% The \showbox puts detailed calculations in the log file
+%
+% Output of 'dvireport -F -up t5.dvi':
+% c 97[a] 0,20pt
+% c 121[y] 4.72223,20pt
+% c 98[b] 0,28.8889pt
+% c 121[y] 5.27777,28.8889pt
+% c 99[c] 50,76.25pt
+% c 100[d] 0,70pt
+% c 121[y] 5.55556,70pt
+%
+% The most important thing is that `a' and `d' are 50pt
+% apart, \parskip+\baselineskip
+%
+% This test may not currently be working (2005 August 30). There's an
+% extra 30pt (\parskip) appearing before the by and cy in their boxes,
+% which clearly isn't present in the t5.correct.dvi. Ought it to be
+% there? Have I done something (when?) which has caused this to
+% spuriously appear?
+
+
+\showboxdepth=8
+\showboxbreadth=8
+
+\noindent ay
+\vrule height 20pt depth 0pt width 0pt % strut -- makes base of this
+ % line 20pt from top
+\begin{textblock}{3}(0,0)
+\noindent by
+\end{textblock}
+\begin{textblock}{2}(1,1)
+\noindent cy
+\end{textblock}
+\noindent
+dy
+
+%\showlists % put detailed diagnostics into log file
+
+\end{document}