tl;dr– This answer plays with spacing just for fun.
@PM2Ring's answer suggested \mathstrut
, then @GNUSupporter8964民主女神地下教會's answer tried constructing a similar mechanism through \vphantom{\bigcup}
.
So, in that spirit and just for fun, trying \vphantom
with differing heights, mostly just to see what they look like:
$$
{\def\Spacing#1{\vphantom{\rule{0em}{#1em}}}}
{\def\Example#1#2{
{#2{\sqrt{6 + 2 \sqrt{7 + 3\sqrt{\Spacing{#1} 8 + \cdots}}}}}}}
{\def\Row#1{\\ \text{#1} & \Example{#1}{} & \Example{#1}{\displaystyle}}}
\begin{array}{lcc}
\begin{array}{c}\textbf{Height} \\[-25px] \left(\texttt{em}\right)\end{array}
& \begin{array}{c}\textbf{Rendering, without} \\[-25px] \texttt{\displaystyle} \end{array}
& \begin{array}{c}\textbf{Rendering, with} \\[-25px] \texttt{\displaystyle} \end{array}
\Row{0}
\Row{0.5}
\Row{0.75}
\Row{0.9}
\Row{1}
\Row{1.1}
\Row{1.25}
\Row{1.5}
\Row{2}
\end{array}
_{.}
$$
Each line is
$$
\boxed{
\begin{array}{l}
\color{blue}{\overbrace{\texttt{\displaystyle}}^{\text{with or without}}}
~\texttt{\{\sqrt\{6 + 2 \\sqrt\{7 + 3}
\\[0.5em]
\texttt{\\sqrt\{}
\color{red}{\texttt{\\vphantom\{\\rule\{0em\}}}
\color{red}{\underbrace{\texttt{\{}x~\texttt{em\}}}_{\begin{array}{c}\text{height} \\[-25px] \text{value}\end{array}} \texttt{\}}}
~\texttt{8 + \\cdots\}\}\}\}\}}
\end{array}
}_{,}
$$
with the coloring for the $\color{blue}{\texttt{\\displaystyle}}$ and ${\color{red}{\textbf{height}}}$ parts.