.svg import with serifs despite explicit font-family="sans-serif" instruction
Openbabel allows to interconvert chemistry relevant formats into each other, and the generation of a graphical representation in either .png or .svg format. Advantageously, these conversions may be run in batches, too. Beside working with «true files», it is possible to provide openbabel a SMILES string describing the structure in sufficient detail as input, i.e.
obabel -:"c1ccccn1" -O pyridine.svg
to create a structure representation about pyridine which equally is attached below. I wonder, however, why EOG displays the character «N» with serifs, despite the underlying .svg clearly states in lines 22 and 23:
<text font-size="18.000000" fill ="black" font-family="sans-serif"
x="10.000000" y="20.000000" ></text>
Converting the .svg with cairosvg into a .pdf yields the expected representation without serifs:
cairosvg pyridine.svg -o pyridine.pdf
Just for testing the font issue, muting all chemical reason, I then requested openabel to create a not-reasonable heterocycle including oxygen, nitrogen, sulfur, fluorine, chlorine, bromine, and iodine by
obabel -:"c1onsFClBrI1" -O testing.svg
which, replicating this «feature», displays the labels again with the not-expected serifs in the .svg:
As a side note, ristretto (0.8.2) and pinta (1.6) equally matches eog's pattern. Inkscape 0.92.3 (2405546, 2018-03-11) however provides a correct, non-serif import of the .svg in question.
System setup:
Xubuntu 18.04.2 LTS 64 bit,
GNOME Image Viewer 3.28.1,
cairosvg 2.4.0,
Atril document viewer 1.20.1 backed by poppler/cairo (0.62.0).