Details
-
Bug
-
Resolution: Unresolved
-
P3: Somewhat important
-
None
-
5.12.7
-
None
Description
As per summary, `averageCharWidth()` returns obviously incorrects widths for OpenType bitmap (OTB) font: the value is much larger than the expected one, for example 605 for a 5 pixel-wide font. This can cause all sort of problems for programs that use metrics to size widgets and is how I came upon this.
Before reporting the bug I have tested multiple fonts, some generated with fontforge and other with different tools (like mkfonttosfnt), and all show the same issue, so it's very unlikely to be an incorrect value in the font itself.
To try to reproduce the issue here's an OTB font: cozette.otb