I'm curious how does \vrule
determine the height of the current box?
\documentclass{article}
\usepackage{amsmath}
\[
\Big(
~
\vrule width.7pt
~
\Big)
\]
this image was created by stitching together different ones after compiling with each of \Bigg
, \Big
and \big
delimiters.
How can I retentive the height of the current box as a dimension to use for my needs?
In sake of simplicity, lets consider the following: make the same rule with \rule[]{}{}
command that has height as a mandatory argument. And I want it to produce the same rule as \vrule width.7pt
by setting some kind of arguments that contain dimension of the current box
\rule[<current depth>]{.7pt}{<current height>}
But the actual need for that is to draw a curved line using tikz
that would have a height of the current box.
this one has been created simply by eyeballing
\documentclass{article}
\usepackage{amsmath}
\usepackage{tikz}
\[
\Big(
\,
\tikz[overlay]\draw (0,-9pt) to[in=10] (5pt, 16.5pt);
\hspace{2ex}
\Big)
\]
Note:
The main requirement is to avoid saving a chunk of code with the box beforehand. The goal -- make it inline as \vrule
does.
\setbox0=\hbox{...}
or\setbox0=\vbox{...}
to set contents. Then,\ht0
,\dp0
, and\wd0
can retrieve height, depth, and width.\box0
will destructively typeset the box, whereas\copy0
will non-destructively set it. Register numbers range 0-255. Even numbers are local box registers, odd numbers are global box registers. If I recall, 255 is reserved for special use.\box255
is a\vbox
where the TeX page builder stores the page body once the best page break has been found, ready for use by the\output
routine (cf. TeXbook p. 125, plus the chapter about\output
routines).