How to measure the pixel width of a digit in a given font / size (C#)
I am trying to calculate the pixel width of Excel columns, as described in this post , using the official formula from the OpenXML specification. However, in order to apply this formula, I need to know the Maximum Digit Width of the Normal font, which is the pixel width of the widest numeric digit. The OpenXML specification gives this example as a clarification: Using the Calibri font as an example, the maximum digit width of 11 point font size is 7 pixels (at 96 dpi). I have checked that this is correct by visually examining a Calibri 11-point digit and it is indeed 7 pixels wide. So, I am