diff options
Diffstat (limited to 'macros/generic/misc/underlin.tex')
-rw-r--r-- | macros/generic/misc/underlin.tex | 18 |
1 files changed, 18 insertions, 0 deletions
diff --git a/macros/generic/misc/underlin.tex b/macros/generic/misc/underlin.tex new file mode 100644 index 0000000000..eec6aaa129 --- /dev/null +++ b/macros/generic/misc/underlin.tex @@ -0,0 +1,18 @@ +% underlin.tex - real multi-word underlining +% By Stephen Gildea <gildea@x.org> January 1995. + +% Usage: \textul{text to underline} + +\def\textul#1{\leavevmode\let\textulnext=\textuli\textuli#1 & } +\def\textuli#1 {\ifx\unskip\let\textulnext=\relax\else + \textulword{#1}\textulspace\fi \textulnext} +\newskip\textulspskip %saved size of a space +\def\textulword#1{% + \setbox0\hbox{#1\space\global\textulspskip=\the\lastskip\unskip}% + \dimen0=\dp0\dp0=1.2pt + \setbox0\vtop{\box0\hrule}\ifdim\dp0<\dimen0\dp0=\dimen0\fi \box0} +\def\textulspace{\leaders\hrule height -1.2pt depth 1.6pt + \hskip\textulspskip} + +% For a much fancier version with many options (e.g., strikeout), +% see ulem.sty in the CTAN archive. |