How do I get height & width of a text element?

Q: As far as I know, to get the length (width) of a given text
element, all we need is to call the GetTextLength() on an element
object. However, I need to get the height of a given text, but I've
got no idea how to do that.
--------
A: You could use element.GetBBox(rect) to obtain a bounding box for
any page element including text. The height of a text element would be
rect.Height().