Measure character height?

I need to get the computed height of the tallest character in a sentence.

TextFragmentState allows the width to be figured out easily - and supports the font style, just like I need.
But I see no options for the height.

Where should I look?

@TraitDev

If you want to get the height of text, you can use TextFragment.Rectangle.Height property. Hope this helps you.

If you still face problem, please share your sample PDF along with expected output. We will then provide you more information on it.

There’s no PDF involved here. Just need the measurement to do things with.
I suppose I can create a non box bound text fragment, get the height, and then dispose of it.
It should do the trick hopefully. Will update if not.

Unfortunately, this method seems to only be returning the font size in-spite of the font being styled and therefore larger than the rectangle value that is being returned.

Any other method to achieve this similarly to MeasureString ?

@TraitDev

Font.MeasureString returns width of the string represented with this font and the specified size.

We have logged your requirement in our issue tracking system as PDFNET-52882. You will be informed once there is an update available on it. We apologize for your inconvenience.

The issues you have found earlier (filed as PDFNET-52882) have been fixed in this update.