The high level problem I am trying to calculate the width of a line of text for a given font. I am generating a dynamic PDF using fpdf.org’s tool. FPDF utilizes PHP ﬁles among other things to generate the PDF. I can use this PDF to generate the length of a line of text given the deﬁnition. I’ve provided two sample deﬁnitions below, one for Arial and one for Amazon (a script font).
My problem is I want to make sure I’m understanding what all of these variables are ﬁrst. I don’t understand what the following variables are:
As you can see from the images below, Arial isn’t really caluclating correctly, but Amazon is. The reason I don’t think Arial is calculating correctly is because the ration between the EM Square =2692 and the EM Width (width of an U.C. “M”) =833 be SO far apart. Am I misinterpretting the numbers and/or variables?
FOR DETAILS AND IMAGES SEE:
Technical font terminology question