I am trying to determine how to get the height on a block of latex output (not the whole document, and not the code..but rather a block of
I think this will work:
\newlength{\somenamehere}
\settoheight{\somenamehere}{\hbox{...}}
Where ...
is your content you like to measure. And you can then use \somenamehere
as the height of that content.
Example:
\documentclass[english]{article}
\usepackage[T1]{fontenc}
\usepackage[latin9]{inputenc}
\usepackage{babel}
\begin{document}
\newlength{\heightofhw}
\settoheight{\heightofhw}{\hbox{Hello World!}}
Value = \the\heightofhw
\end{document}
Will output:
Value = 6.8872pt
Note:
Update:
Use \hbox
to correctly calculate the height of a different sized environment, but it won't work with newlines :-(