I have a similar problem using freetype to display a bunch of text elements that will appear in the grid. Not all text elements have the same dimension, and I need to pre-define them before I know where they will be laid out. Different sizes were the biggest problem when changing heights, for example, for letters with descending parts (for example, "j" or "Q").
In the end, I used the height that is on the face (sort of like with bbox). But, as you already mentioned, this value was great. It should be basic for the base distance, but it turned out to be about twice as large. So, I made an easy exit and divided the reported height by 2 and used this as the total height value. Most likely, the height is too high, because there are some characters in the font that go high or low.
I suggest that a better way could be to loop through all the characters that are expected to be used, get their glyph metrics and keep the highest found height. But this is not like anything that would be great.
source share