[Tex/LaTex] Get a box with zero depth including some text

boxes

How to get a box including some text in text mode, which depth 0pt?

Best Answer

You can use \raisebox to modify the official height and depth of some text:

\raisebox{0pt}[\height][0pt]{<text>}

This raises the text by 0pt (so not at all), keeps the official height identical to the original height and sets the depth to 0pt.