Invalid component glyph flags in the Ubuntu fonts
- Dominant language
- HTML
- Stars
- 20.5k
- Forks
- 2.9k
- Avg merge
- 1d 21h
- Merged PRs (30d)
- 95
Description
**Describe the bug**
When parsing the [Glyph Data](https://learn.microsoft.com/en-us/typography/opentype/spec/glyf) of the fonts in the `ufl` folder, there are glyphs where the Component Glyph Flags are set to 0x236. However, according to the specification, the bits given by 0xE010 are reserved, which making bit 4 contain an invalid value.
**To Reproduce**
Check the fourth bit in the Component Glyph Flags. For instance, using `fonttools`:
```python
from fontTools.ttLib import TTFont
font = TTFont("ufl/ubuntucondensed/UbuntuCondensed-Regular.ttf")
hex(font["glyf"]["colon"].components[0].flags)
# 0x214
```
Here one should note that it is not 0x236 but 0x214 because of this “cleaning” conjunction:
[_g_l_y_f.py#L1419-L1421](https://github.com/fonttools/fonttools/blob/5a0dc4bc8dfaa0c7da146cf902395f748b3cebe5/Lib/fontTools/ttLib/tables/_g_l_y_f.py#L1419-L1421)
When printing the original value there, one gets 0x236.
**Expected behavior**
Bit 4 should not be set.
Contributor guide
Assessment
This issue has not been assessed yet.