Warning W1113 does not divulge which glyph has degenerated contours
madig opened this issue · comments
One of our fonts triggers this: W1113 Degenerated contour(s), Number of glyphs with the warning = 1
. I guess the code to find these contours is at https://github.com/HinTak/Font-Validator/blob/master/Glyph/GErr.cs#L980, however:
- I don't understand what the code does
- It doesn't seem to use indGlyphOwner to note down the specific glyph index
I'd prepare a patch to fix 2., but the specifics string doesn't even seem to be used in the report?!
(Sent to your at-users.sourceforge.net address)
Argh, I saw this problem while testing visual-studio-2008-built FontVal 2.1.3 with Microsoft's times - I 'll look into it at some point.
@madig : sorry it has taken a while. I think I can answer both question 1 and 2: the glyph id is kept by the caller, and also summary-filtered out by the caller, in OTFontFileVal/val_glyf.cs
. What you want to do is to disable the filtering, which can be done by commenting out (I.e. prepend with "//") the line "GERR_CONT_DEGEN"
in the struct m_namesInfoCnt
near line 147.
As I said I saw it with Microsoft Times - there are 11 such glyphs, all in the u200x unicode range, for various sort of spaces. In all the cases, the glyph has a single contour with a single point, so the diagnosis is correct, though uninteresting. Removing the single contour would get the font smaller.
I had a quick look at some of the older reports I collected; many fonts have a non-zero summary count. I assume the small ones (10-ish or below) are the u200x spaces, but some fonts have summary counts in the 100's so cannot really be that.
You can have a go at commenting out that line and see what glyph id it says - I'd suggest start with a font with a high count.
I am okay pushing this change (the commenting) as 2.1.4, if you have trouble building/running with mono.