The font size is too large in the order shown below.
So when I call Document.Save(), it get stuck in infinite loop.
Is there a way for Text width to find the perfect font size for cell width?
TextState textState = new TextState(“Courier”, true, false);
float fontSize = textState.FontSize;
while (textState.MeasureString(“Some Text”) < Table.GetWidth())
{
fontSize = fontSize + 0.2f;
textState.FontSize = fontSize;
}