At least for some CJK character sets, FontForge writes a font which
includes a METRICSSET section in the preamble, and later in some glyphs
skips the SWIDTH/DWIDTH lines in preference to the default values specified
in the METRICSSET. According to the Adobe document describing the 2.2
format, this is ia size optimization for storing bdf fonts because many
glyphs have the same metrics, particular for vertical text layouts.
X's bdftopcf never accepted these extensions not present in BDF 2.1,
but fontforge writes them anyway. (I'm not sure who is using fontforge's
BDF output, given this fact)
This adds minimal support for these elements of the font.
Testing performed:
* converted yasa-200.bdf to pcf, then rendered with Adafruit_CircuitPython_BitmapFont's simpletest on a host computer
with https://github.com/adafruit/Adafruit_CircuitPython_Bitmap_Font/pull/34 applied. (this was broken before this PR)
* converted a bdf file produced by otf2bdf and displayed it similarly (this was working before)
this was needed for a pretty much worst-case font, yasahshi rendered at
200 points tall. Conversion also takes long enough that the browser
starts getting irritated.
Actions gave the inscrutable error:
Error: fatal: unable to access 'https://github.com/jepler/web-bdftopcf/': server certificate verification failed. CAfile: none CRLfile: none