I'm looking to label different words in a sentence (well, it'll be a lot of sentences if I get this to work) with their function in the sentence. Take a look at the attached image to see what I mean.
... is there a package or something in LaTeX that can do that?
Thanks,
-Wm
Text Formatting ⇒ Supertext issue
Supertext issue
- Attachments
-
- text_problem.png (2.48 KiB) Viewed 2240 times
NEW: TikZ book now 40% off at Amazon.com for a short time.
Supertext issue
I don't know of any package that suits your purpose, but you could do something like:
or to make typing simpler:
Note that if you do this, you won't have any hyphenation, so it might be better to use \raggedright.
Regards
Nicola Talbot
Code: Select all
\documentclass{article}
\usepackage{amsmath}
\newcommand*{\word}[2]{\shortstack{\tiny\smash[b]{#1}\\\rule{0pt}{2ex}#2}}
\begin{document}
\word{article}{The} \word{noun/subject}{fence} \word{LV}{is}
\word{predicate adj.}{white.}
\end{document}
Code: Select all
\documentclass{article}
\usepackage{amsmath}
\newcommand*{\word}[2]{\shortstack{\tiny\smash[b]{#1}\\\rule{0pt}{2ex}#2}}
\newcommand*{\art}[1]{\word{article}{#1}}
\newcommand*{\nounsub}[1]{\word{noun/subject}{#1}}
\newcommand*{\LV}[1]{\word{LV}{is}}
\newcommand*{\predadj}[1]{\word{predicate adj.}{#1}}
\begin{document}
\art{The} \nounsub{fence} \LV{is} \predadj{white.}
\end{document}
Regards
Nicola Talbot
LaTeX Resources: http://www.dickimaw-books.com/latexresources.html
Creating a Minimal Example: http://www.dickimaw-books.com/latex/minexample/
Creating a Minimal Example: http://www.dickimaw-books.com/latex/minexample/
Re: Supertext issue
Hmmm, that should work nicely.
Thank you so much.
-Wm
Thank you so much.

-Wm