Closed
Description
Investigating the linux failures in #12982 discovered that we are not parsing AFM files correctly.
https://www.adobe.com/content/dam/acom/en/devnet/font/pdfs/5004.AFM_Spec.pdf for reference...
- weird values for underline information. There are some files which have lines like
where we expect this to be a "number" which can a decimal, we are expecting to cast to float (see page 10 in the pdf). An example of this (on arch) is
UnderlinePosition -41,5039 UnderlineThickness 43,9453
/usr/share/texmf-dist/fonts/afm/public/dejavu/DejaVuSansCondensed-BoldOblique.afm
- It seems that there are strings encoded as latin-1 (
b'Notice' b'Copyright (c) Typographer Mediengestaltung, 2000. All rights reserved. Zallman-Caps \xa9 1991 by D. Rakowski.'
to get in ©. According to the first section of the linked pdf AFM files are ASCII encoded. Some fonts are parsing with weights that are not in the weight dictionary (which is what caused the
failure on azure
In [7]: [(f.fname, f.weight) for f in fm.afmlist if f.weight not in matplotlib.font_manager.weight_dict]
Out[7]:
[('/usr/share/texmf-dist/fonts/afm/public/aurical/AuriocusKalligraphicusRslant.afm',
'reverseoblique'),
('/usr/share/texmf-dist/fonts/afm/public/aurical/AuriocusKalligraphicusSlant.afm',
'oblique'),
('/usr/share/texmf-dist/fonts/afm/public/aurical/AmiciLogoRslant.afm',
'reverseoblique'),
('/usr/share/texmf-dist/fonts/afm/public/prodint/prodint.afm', 'plain'),
('/usr/share/texmf-dist/fonts/afm/public/aurical/LukasSvatbaSlant.afm',
'oblique'),
('/usr/share/texmf-dist/fonts/afm/public/aurical/JanaSkrivanaRslant.afm',
'reverseoblique'),
('/usr/share/texmf-dist/fonts/afm/public/txfontsb/FreeSerifb-SmallCapsAlt.afm',
'smallcaps'),
('/usr/share/texmf-dist/fonts/afm/public/aurical/LukasSvatbaRslant.afm',
'reverseoblique'),
('/usr/share/texmf-dist/fonts/afm/public/cochineal/Cochineal-Italic.afm',
'italic'),
('/usr/share/texmf-dist/fonts/afm/public/aurical/LukasSvatbaBoldRslant.afm',
'boldreverseoblique'),
('/usr/share/texmf-dist/fonts/afm/public/tex-gyre/qcsbi.afm', 'bolditalic'),
('/usr/share/texmf-dist/fonts/afm/public/aurical/JanaSkrivanaBoldRslant.afm',
'boldreverseoblique'),
('/usr/share/texmf-dist/fonts/afm/public/mathpazo/fplmbb.afm',
'blackboardbold'),
('/usr/share/texmf-dist/fonts/afm/public/dejavu/DejaVuSans-ExtraLight.afm',
'extra-light'),
('/usr/share/texmf-dist/fonts/afm/public/aurical/JanaSkrivanaBoldSlant.afm',
'boldoblique'),
('/usr/share/texmf-dist/fonts/afm/public/aurical/AuriocusKalligraphicusBoldRslant.afm',
'boldreverseoblique'),
('/usr/share/texmf-dist/fonts/afm/public/aurical/AuriocusKalligraphicusBoldSlant.afm',
'boldoblique'),
('/usr/share/texmf-dist/fonts/afm/public/aurical/AmiciLogoSlant.afm',
'oblique'),
('/usr/share/texmf-dist/fonts/afm/public/txfontsb/FreeSerifb-SmallCaps.afm',
'smallcaps'),
('/usr/share/texmf-dist/fonts/afm/public/aurical/AmiciLogoBoldRslant.afm',
'boldreverseoblique'),
('/usr/share/texmf-dist/fonts/afm/public/aurical/AmiciLogoBoldSlant.afm',
'boldoblique'),
('/usr/share/texmf-dist/fonts/afm/public/aurical/LukasSvatbaBoldSlant.afm',
'boldoblique'),
('/usr/share/texmf-dist/fonts/afm/public/aurical/JanaSkrivanaSlant.afm',
'oblique')]
there are mostly weight that should have been split into a weight + a slant or weight + style.
Metadata
Metadata
Assignees
Labels
No labels