varLib_test: add test for variable CFF2 with empty glyph in sparse master
Three masters, Regular and Bold have glyphs .notdef, a, e; Medium only has .notdef (but empty, no contours) and e.
This commit is contained in:
parent
839e76b84d
commit
653bccdb02
23
Tests/varLib/data/SparseCFF2.designspace
Normal file
23
Tests/varLib/data/SparseCFF2.designspace
Normal file
@ -0,0 +1,23 @@
|
||||
<?xml version='1.0' encoding='UTF-8'?>
|
||||
<designspace format="5.0">
|
||||
<axes>
|
||||
<axis tag="wght" name="Weight" minimum="350" maximum="625" default="350"/>
|
||||
</axes>
|
||||
<sources>
|
||||
<source filename="master_sparse_cff2_empty/SparseCFF-Regular.ttx" name="Sparse Font Regular" familyname="Sparse Font" stylename="Regular">
|
||||
<location>
|
||||
<dimension name="Weight" xvalue="350"/>
|
||||
</location>
|
||||
</source>
|
||||
<source filename="master_sparse_cff2_empty/SparseCFF-Medium.ttx" name="Sparse Font Medium" familyname="Sparse Font" stylename="Medium">
|
||||
<location>
|
||||
<dimension name="Weight" xvalue="450"/>
|
||||
</location>
|
||||
</source>
|
||||
<source filename="master_sparse_cff2_empty/SparseCFF-Bold.ttx" name="Sparse Font Bold" familyname="Sparse Font" stylename="Bold">
|
||||
<location>
|
||||
<dimension name="Weight" xvalue="625"/>
|
||||
</location>
|
||||
</source>
|
||||
</sources>
|
||||
</designspace>
|
302
Tests/varLib/data/master_sparse_cff2_empty/SparseCFF-Bold.ttx
Normal file
302
Tests/varLib/data/master_sparse_cff2_empty/SparseCFF-Bold.ttx
Normal file
@ -0,0 +1,302 @@
|
||||
<?xml version="1.0" encoding="UTF-8"?>
|
||||
<ttFont sfntVersion="OTTO" ttLibVersion="4.41">
|
||||
|
||||
<GlyphOrder>
|
||||
<!-- The 'id' attribute is only for humans; it is ignored when parsed. -->
|
||||
<GlyphID id="0" name=".notdef"/>
|
||||
<GlyphID id="1" name="a"/>
|
||||
<GlyphID id="2" name="e"/>
|
||||
</GlyphOrder>
|
||||
|
||||
<head>
|
||||
<!-- Most of this table will be recalculated by the compiler -->
|
||||
<tableVersion value="1.0"/>
|
||||
<fontRevision value="0.0"/>
|
||||
<checkSumAdjustment value="0xaa7fc0dd"/>
|
||||
<magicNumber value="0x5f0f3cf5"/>
|
||||
<flags value="00000000 00000011"/>
|
||||
<unitsPerEm value="1000"/>
|
||||
<created value="Wed Nov 21 11:49:03 2018"/>
|
||||
<modified value="Wed Aug 2 11:47:17 2023"/>
|
||||
<xMin value="-64"/>
|
||||
<yMin value="-350"/>
|
||||
<xMax value="608"/>
|
||||
<yMax value="812"/>
|
||||
<macStyle value="00000000 00000001"/>
|
||||
<lowestRecPPEM value="6"/>
|
||||
<fontDirectionHint value="2"/>
|
||||
<indexToLocFormat value="0"/>
|
||||
<glyphDataFormat value="0"/>
|
||||
</head>
|
||||
|
||||
<hhea>
|
||||
<tableVersion value="0x00010000"/>
|
||||
<ascent value="950"/>
|
||||
<descent value="-250"/>
|
||||
<lineGap value="0"/>
|
||||
<advanceWidthMax value="600"/>
|
||||
<minLeftSideBearing value="-64"/>
|
||||
<minRightSideBearing value="-63"/>
|
||||
<xMaxExtent value="608"/>
|
||||
<caretSlopeRise value="1"/>
|
||||
<caretSlopeRun value="0"/>
|
||||
<caretOffset value="0"/>
|
||||
<reserved0 value="0"/>
|
||||
<reserved1 value="0"/>
|
||||
<reserved2 value="0"/>
|
||||
<reserved3 value="0"/>
|
||||
<metricDataFormat value="0"/>
|
||||
<numberOfHMetrics value="2"/>
|
||||
</hhea>
|
||||
|
||||
<maxp>
|
||||
<tableVersion value="0x5000"/>
|
||||
<numGlyphs value="3"/>
|
||||
</maxp>
|
||||
|
||||
<OS_2>
|
||||
<!-- The fields 'usFirstCharIndex' and 'usLastCharIndex'
|
||||
will be recalculated by the compiler -->
|
||||
<version value="4"/>
|
||||
<xAvgCharWidth value="580"/>
|
||||
<usWeightClass value="400"/>
|
||||
<usWidthClass value="5"/>
|
||||
<fsType value="00000000 00000100"/>
|
||||
<ySubscriptXSize value="650"/>
|
||||
<ySubscriptYSize value="600"/>
|
||||
<ySubscriptXOffset value="0"/>
|
||||
<ySubscriptYOffset value="75"/>
|
||||
<ySuperscriptXSize value="650"/>
|
||||
<ySuperscriptYSize value="600"/>
|
||||
<ySuperscriptXOffset value="0"/>
|
||||
<ySuperscriptYOffset value="350"/>
|
||||
<yStrikeoutSize value="50"/>
|
||||
<yStrikeoutPosition value="300"/>
|
||||
<sFamilyClass value="0"/>
|
||||
<panose>
|
||||
<bFamilyType value="0"/>
|
||||
<bSerifStyle value="0"/>
|
||||
<bWeight value="0"/>
|
||||
<bProportion value="0"/>
|
||||
<bContrast value="0"/>
|
||||
<bStrokeVariation value="0"/>
|
||||
<bArmStyle value="0"/>
|
||||
<bLetterForm value="0"/>
|
||||
<bMidline value="0"/>
|
||||
<bXHeight value="0"/>
|
||||
</panose>
|
||||
<ulUnicodeRange1 value="00000000 00000000 00000000 00000001"/>
|
||||
<ulUnicodeRange2 value="00000000 00000000 00000000 00000000"/>
|
||||
<ulUnicodeRange3 value="00000000 00000000 00000000 00000000"/>
|
||||
<ulUnicodeRange4 value="00000000 00000000 00000000 00000000"/>
|
||||
<achVendID value="NONE"/>
|
||||
<fsSelection value="00000000 00100000"/>
|
||||
<usFirstCharIndex value="97"/>
|
||||
<usLastCharIndex value="101"/>
|
||||
<sTypoAscender value="750"/>
|
||||
<sTypoDescender value="-250"/>
|
||||
<sTypoLineGap value="200"/>
|
||||
<usWinAscent value="950"/>
|
||||
<usWinDescent value="250"/>
|
||||
<ulCodePageRange1 value="00000000 00000000 00000000 00000001"/>
|
||||
<ulCodePageRange2 value="00000000 00000000 00000000 00000000"/>
|
||||
<sxHeight value="500"/>
|
||||
<sCapHeight value="700"/>
|
||||
<usDefaultChar value="0"/>
|
||||
<usBreakChar value="32"/>
|
||||
<usMaxContext value="4"/>
|
||||
</OS_2>
|
||||
|
||||
<name>
|
||||
<namerecord nameID="1" platformID="3" platEncID="1" langID="0x409">
|
||||
Sparse CFF
|
||||
</namerecord>
|
||||
<namerecord nameID="2" platformID="3" platEncID="1" langID="0x409">
|
||||
Bold
|
||||
</namerecord>
|
||||
<namerecord nameID="3" platformID="3" platEncID="1" langID="0x409">
|
||||
0.000;NONE;SparseCFF-Bold
|
||||
</namerecord>
|
||||
<namerecord nameID="4" platformID="3" platEncID="1" langID="0x409">
|
||||
Sparse CFF Bold
|
||||
</namerecord>
|
||||
<namerecord nameID="5" platformID="3" platEncID="1" langID="0x409">
|
||||
Version 0.000
|
||||
</namerecord>
|
||||
<namerecord nameID="6" platformID="3" platEncID="1" langID="0x409">
|
||||
SparseCFF-Bold
|
||||
</namerecord>
|
||||
</name>
|
||||
|
||||
<cmap>
|
||||
<tableVersion version="0"/>
|
||||
<cmap_format_4 platformID="0" platEncID="3" language="0">
|
||||
<map code="0x61" name="a"/><!-- LATIN SMALL LETTER A -->
|
||||
<map code="0x65" name="e"/><!-- LATIN SMALL LETTER E -->
|
||||
</cmap_format_4>
|
||||
<cmap_format_4 platformID="3" platEncID="1" language="0">
|
||||
<map code="0x61" name="a"/><!-- LATIN SMALL LETTER A -->
|
||||
<map code="0x65" name="e"/><!-- LATIN SMALL LETTER E -->
|
||||
</cmap_format_4>
|
||||
</cmap>
|
||||
|
||||
<post>
|
||||
<formatType value="3.0"/>
|
||||
<italicAngle value="0.0"/>
|
||||
<underlinePosition value="-100"/>
|
||||
<underlineThickness value="50"/>
|
||||
<isFixedPitch value="0"/>
|
||||
<minMemType42 value="0"/>
|
||||
<maxMemType42 value="0"/>
|
||||
<minMemType1 value="0"/>
|
||||
<maxMemType1 value="0"/>
|
||||
</post>
|
||||
|
||||
<CFF>
|
||||
<major value="1"/>
|
||||
<minor value="0"/>
|
||||
<CFFFont name="SparseCFF-Bold">
|
||||
<version value="0.0"/>
|
||||
<Notice value=""/>
|
||||
<Copyright value=""/>
|
||||
<FullName value="Sparse CFF Bold"/>
|
||||
<FamilyName value="Sparse CFF"/>
|
||||
<isFixedPitch value="0"/>
|
||||
<ItalicAngle value="0"/>
|
||||
<UnderlinePosition value="-100"/>
|
||||
<UnderlineThickness value="50"/>
|
||||
<PaintType value="0"/>
|
||||
<CharstringType value="2"/>
|
||||
<FontMatrix value="0.001 0 0 0.001 0 0"/>
|
||||
<FontBBox value="-64 -350 608 812"/>
|
||||
<StrokeWidth value="0"/>
|
||||
<!-- charset is dumped separately as the 'GlyphOrder' element -->
|
||||
<Encoding name="StandardEncoding"/>
|
||||
<Private>
|
||||
<BlueScale value="0.039625"/>
|
||||
<BlueShift value="7"/>
|
||||
<BlueFuzz value="1"/>
|
||||
<ForceBold value="0"/>
|
||||
<LanguageGroup value="0"/>
|
||||
<ExpansionFactor value="0.06"/>
|
||||
<initialRandomSeed value="0"/>
|
||||
<defaultWidthX value="600"/>
|
||||
<nominalWidthX value="0"/>
|
||||
</Private>
|
||||
<CharStrings>
|
||||
<CharString name=".notdef">
|
||||
500 50 -350 rmoveto
|
||||
500 0 rlineto
|
||||
0 1100 rlineto
|
||||
-500 0 rlineto
|
||||
50 -950 rmoveto
|
||||
0 900 rlineto
|
||||
300 0 rlineto
|
||||
0 -900 rlineto
|
||||
endchar
|
||||
</CharString>
|
||||
<CharString name="a">
|
||||
468 -1 rmoveto
|
||||
-21 435 rlineto
|
||||
-233 70 rlineto
|
||||
-205 -76 rlineto
|
||||
27 -147 rlineto
|
||||
172 60 rlineto
|
||||
96 -38 rlineto
|
||||
3 -304 rlineto
|
||||
71 264 rmoveto
|
||||
-352 -23 rlineto
|
||||
3 -218 rlineto
|
||||
139 -34 rlineto
|
||||
221 83 rlineto
|
||||
-6 78 rlineto
|
||||
-182 -47 rlineto
|
||||
-38 31 rlineto
|
||||
2 46 rlineto
|
||||
216 5 rlineto
|
||||
endchar
|
||||
</CharString>
|
||||
<CharString name="e">
|
||||
197 229 rmoveto
|
||||
404 -4 rlineto
|
||||
-5 79 rlineto
|
||||
-282 244 rlineto
|
||||
-305 -286 rlineto
|
||||
179 -280 rlineto
|
||||
340 18 rlineto
|
||||
-4 184 rlineto
|
||||
-280 -54 rlineto
|
||||
-27 134 rlineto
|
||||
84 96 rlineto
|
||||
103 -67 rlineto
|
||||
-209 6 rlineto
|
||||
endchar
|
||||
</CharString>
|
||||
</CharStrings>
|
||||
</CFFFont>
|
||||
|
||||
<GlobalSubrs>
|
||||
<!-- The 'index' attribute is only for humans; it is ignored when parsed. -->
|
||||
</GlobalSubrs>
|
||||
</CFF>
|
||||
|
||||
<GDEF>
|
||||
<Version value="0x00010000"/>
|
||||
<GlyphClassDef>
|
||||
<ClassDef glyph="e" class="1"/>
|
||||
</GlyphClassDef>
|
||||
</GDEF>
|
||||
|
||||
<GPOS>
|
||||
<Version value="0x00010000"/>
|
||||
<ScriptList>
|
||||
<!-- ScriptCount=1 -->
|
||||
<ScriptRecord index="0">
|
||||
<ScriptTag value="DFLT"/>
|
||||
<Script>
|
||||
<DefaultLangSys>
|
||||
<ReqFeatureIndex value="65535"/>
|
||||
<!-- FeatureCount=0 -->
|
||||
</DefaultLangSys>
|
||||
<!-- LangSysCount=0 -->
|
||||
</Script>
|
||||
</ScriptRecord>
|
||||
</ScriptList>
|
||||
<FeatureList>
|
||||
<!-- FeatureCount=0 -->
|
||||
</FeatureList>
|
||||
<LookupList>
|
||||
<!-- LookupCount=0 -->
|
||||
</LookupList>
|
||||
</GPOS>
|
||||
|
||||
<GSUB>
|
||||
<Version value="0x00010000"/>
|
||||
<ScriptList>
|
||||
<!-- ScriptCount=1 -->
|
||||
<ScriptRecord index="0">
|
||||
<ScriptTag value="DFLT"/>
|
||||
<Script>
|
||||
<DefaultLangSys>
|
||||
<ReqFeatureIndex value="65535"/>
|
||||
<!-- FeatureCount=0 -->
|
||||
</DefaultLangSys>
|
||||
<!-- LangSysCount=0 -->
|
||||
</Script>
|
||||
</ScriptRecord>
|
||||
</ScriptList>
|
||||
<FeatureList>
|
||||
<!-- FeatureCount=0 -->
|
||||
</FeatureList>
|
||||
<LookupList>
|
||||
<!-- LookupCount=0 -->
|
||||
</LookupList>
|
||||
</GSUB>
|
||||
|
||||
<hmtx>
|
||||
<mtx name=".notdef" width="500" lsb="50"/>
|
||||
<mtx name="a" width="600" lsb="9"/>
|
||||
<mtx name="e" width="600" lsb="9"/>
|
||||
</hmtx>
|
||||
|
||||
</ttFont>
|
100
Tests/varLib/data/master_sparse_cff2_empty/SparseCFF-Medium.ttx
Normal file
100
Tests/varLib/data/master_sparse_cff2_empty/SparseCFF-Medium.ttx
Normal file
@ -0,0 +1,100 @@
|
||||
<?xml version="1.0" encoding="UTF-8"?>
|
||||
<ttFont sfntVersion="OTTO" ttLibVersion="4.41">
|
||||
|
||||
<GlyphOrder>
|
||||
<!-- The 'id' attribute is only for humans; it is ignored when parsed. -->
|
||||
<GlyphID id="0" name=".notdef"/>
|
||||
<GlyphID id="1" name="e"/>
|
||||
</GlyphOrder>
|
||||
|
||||
<head>
|
||||
<!-- Most of this table will be recalculated by the compiler -->
|
||||
<tableVersion value="1.0"/>
|
||||
<fontRevision value="0.0"/>
|
||||
<checkSumAdjustment value="0x263f439"/>
|
||||
<magicNumber value="0x5f0f3cf5"/>
|
||||
<flags value="00000000 00000011"/>
|
||||
<unitsPerEm value="1000"/>
|
||||
<created value="Wed Nov 21 11:49:03 2018"/>
|
||||
<modified value="Wed Aug 2 11:47:17 2023"/>
|
||||
<xMin value="40"/>
|
||||
<yMin value="-18"/>
|
||||
<xMax value="576"/>
|
||||
<yMax value="513"/>
|
||||
<macStyle value="00000000 00000000"/>
|
||||
<lowestRecPPEM value="6"/>
|
||||
<fontDirectionHint value="2"/>
|
||||
<indexToLocFormat value="0"/>
|
||||
<glyphDataFormat value="0"/>
|
||||
</head>
|
||||
|
||||
<maxp>
|
||||
<tableVersion value="0x5000"/>
|
||||
<numGlyphs value="2"/>
|
||||
</maxp>
|
||||
|
||||
<CFF>
|
||||
<major value="1"/>
|
||||
<minor value="0"/>
|
||||
<CFFFont name="LayerFont-Regular">
|
||||
<version value="0.0"/>
|
||||
<Notice value=""/>
|
||||
<Copyright value=""/>
|
||||
<FullName value="Layer Font Regular"/>
|
||||
<FamilyName value="Layer Font"/>
|
||||
<isFixedPitch value="0"/>
|
||||
<ItalicAngle value="0"/>
|
||||
<UnderlinePosition value="-75"/>
|
||||
<UnderlineThickness value="50"/>
|
||||
<PaintType value="0"/>
|
||||
<CharstringType value="2"/>
|
||||
<FontMatrix value="0.001 0 0 0.001 0 0"/>
|
||||
<FontBBox value="40 -18 576 513"/>
|
||||
<StrokeWidth value="0"/>
|
||||
<!-- charset is dumped separately as the 'GlyphOrder' element -->
|
||||
<Encoding name="StandardEncoding"/>
|
||||
<Private>
|
||||
<BlueScale value="0.039625"/>
|
||||
<BlueShift value="7"/>
|
||||
<BlueFuzz value="1"/>
|
||||
<ForceBold value="0"/>
|
||||
<LanguageGroup value="0"/>
|
||||
<ExpansionFactor value="0.06"/>
|
||||
<initialRandomSeed value="0"/>
|
||||
<defaultWidthX value="500"/>
|
||||
<nominalWidthX value="500"/>
|
||||
</Private>
|
||||
<CharStrings>
|
||||
<CharString name=".notdef">
|
||||
endchar
|
||||
</CharString>
|
||||
<CharString name="e">
|
||||
100 126 203 rmoveto
|
||||
450 -4 rlineto
|
||||
-5 106 rlineto
|
||||
-255 208 rlineto
|
||||
-276 -252 rlineto
|
||||
148 -279 rlineto
|
||||
338 63 rlineto
|
||||
-19 112 rlineto
|
||||
-243 -41 rlineto
|
||||
-84 148 rlineto
|
||||
138 123 rlineto
|
||||
78 -90 rlineto
|
||||
-271 1 rlineto
|
||||
endchar
|
||||
</CharString>
|
||||
</CharStrings>
|
||||
</CFFFont>
|
||||
|
||||
<GlobalSubrs>
|
||||
<!-- The 'index' attribute is only for humans; it is ignored when parsed. -->
|
||||
</GlobalSubrs>
|
||||
</CFF>
|
||||
|
||||
<hmtx>
|
||||
<mtx name=".notdef" width="500" lsb="0"/>
|
||||
<mtx name="e" width="600" lsb="40"/>
|
||||
</hmtx>
|
||||
|
||||
</ttFont>
|
302
Tests/varLib/data/master_sparse_cff2_empty/SparseCFF-Regular.ttx
Normal file
302
Tests/varLib/data/master_sparse_cff2_empty/SparseCFF-Regular.ttx
Normal file
@ -0,0 +1,302 @@
|
||||
<?xml version="1.0" encoding="UTF-8"?>
|
||||
<ttFont sfntVersion="OTTO" ttLibVersion="4.41">
|
||||
|
||||
<GlyphOrder>
|
||||
<!-- The 'id' attribute is only for humans; it is ignored when parsed. -->
|
||||
<GlyphID id="0" name=".notdef"/>
|
||||
<GlyphID id="1" name="a"/>
|
||||
<GlyphID id="2" name="e"/>
|
||||
</GlyphOrder>
|
||||
|
||||
<head>
|
||||
<!-- Most of this table will be recalculated by the compiler -->
|
||||
<tableVersion value="1.0"/>
|
||||
<fontRevision value="0.0"/>
|
||||
<checkSumAdjustment value="0xbfef2bdd"/>
|
||||
<magicNumber value="0x5f0f3cf5"/>
|
||||
<flags value="00000000 00000011"/>
|
||||
<unitsPerEm value="1000"/>
|
||||
<created value="Wed Nov 21 11:49:03 2018"/>
|
||||
<modified value="Wed Aug 2 11:47:17 2023"/>
|
||||
<xMin value="-37"/>
|
||||
<yMin value="-250"/>
|
||||
<xMax value="582"/>
|
||||
<yMax value="750"/>
|
||||
<macStyle value="00000000 00000000"/>
|
||||
<lowestRecPPEM value="6"/>
|
||||
<fontDirectionHint value="2"/>
|
||||
<indexToLocFormat value="0"/>
|
||||
<glyphDataFormat value="0"/>
|
||||
</head>
|
||||
|
||||
<hhea>
|
||||
<tableVersion value="0x00010000"/>
|
||||
<ascent value="950"/>
|
||||
<descent value="-250"/>
|
||||
<lineGap value="0"/>
|
||||
<advanceWidthMax value="600"/>
|
||||
<minLeftSideBearing value="-37"/>
|
||||
<minRightSideBearing value="-50"/>
|
||||
<xMaxExtent value="582"/>
|
||||
<caretSlopeRise value="1"/>
|
||||
<caretSlopeRun value="0"/>
|
||||
<caretOffset value="0"/>
|
||||
<reserved0 value="0"/>
|
||||
<reserved1 value="0"/>
|
||||
<reserved2 value="0"/>
|
||||
<reserved3 value="0"/>
|
||||
<metricDataFormat value="0"/>
|
||||
<numberOfHMetrics value="2"/>
|
||||
</hhea>
|
||||
|
||||
<maxp>
|
||||
<tableVersion value="0x5000"/>
|
||||
<numGlyphs value="3"/>
|
||||
</maxp>
|
||||
|
||||
<OS_2>
|
||||
<!-- The fields 'usFirstCharIndex' and 'usLastCharIndex'
|
||||
will be recalculated by the compiler -->
|
||||
<version value="4"/>
|
||||
<xAvgCharWidth value="580"/>
|
||||
<usWeightClass value="400"/>
|
||||
<usWidthClass value="5"/>
|
||||
<fsType value="00000000 00000100"/>
|
||||
<ySubscriptXSize value="650"/>
|
||||
<ySubscriptYSize value="600"/>
|
||||
<ySubscriptXOffset value="0"/>
|
||||
<ySubscriptYOffset value="75"/>
|
||||
<ySuperscriptXSize value="650"/>
|
||||
<ySuperscriptYSize value="600"/>
|
||||
<ySuperscriptXOffset value="0"/>
|
||||
<ySuperscriptYOffset value="350"/>
|
||||
<yStrikeoutSize value="50"/>
|
||||
<yStrikeoutPosition value="300"/>
|
||||
<sFamilyClass value="0"/>
|
||||
<panose>
|
||||
<bFamilyType value="0"/>
|
||||
<bSerifStyle value="0"/>
|
||||
<bWeight value="0"/>
|
||||
<bProportion value="0"/>
|
||||
<bContrast value="0"/>
|
||||
<bStrokeVariation value="0"/>
|
||||
<bArmStyle value="0"/>
|
||||
<bLetterForm value="0"/>
|
||||
<bMidline value="0"/>
|
||||
<bXHeight value="0"/>
|
||||
</panose>
|
||||
<ulUnicodeRange1 value="00000000 00000000 00000000 00000001"/>
|
||||
<ulUnicodeRange2 value="00000000 00000000 00000000 00000000"/>
|
||||
<ulUnicodeRange3 value="00000000 00000000 00000000 00000000"/>
|
||||
<ulUnicodeRange4 value="00000000 00000000 00000000 00000000"/>
|
||||
<achVendID value="NONE"/>
|
||||
<fsSelection value="00000000 01000000"/>
|
||||
<usFirstCharIndex value="97"/>
|
||||
<usLastCharIndex value="101"/>
|
||||
<sTypoAscender value="750"/>
|
||||
<sTypoDescender value="-250"/>
|
||||
<sTypoLineGap value="200"/>
|
||||
<usWinAscent value="950"/>
|
||||
<usWinDescent value="250"/>
|
||||
<ulCodePageRange1 value="00000000 00000000 00000000 00000001"/>
|
||||
<ulCodePageRange2 value="00000000 00000000 00000000 00000000"/>
|
||||
<sxHeight value="500"/>
|
||||
<sCapHeight value="700"/>
|
||||
<usDefaultChar value="0"/>
|
||||
<usBreakChar value="32"/>
|
||||
<usMaxContext value="4"/>
|
||||
</OS_2>
|
||||
|
||||
<name>
|
||||
<namerecord nameID="1" platformID="3" platEncID="1" langID="0x409">
|
||||
Sparse CFF
|
||||
</namerecord>
|
||||
<namerecord nameID="2" platformID="3" platEncID="1" langID="0x409">
|
||||
Regular
|
||||
</namerecord>
|
||||
<namerecord nameID="3" platformID="3" platEncID="1" langID="0x409">
|
||||
0.000;NONE;SparseCFF-Regular
|
||||
</namerecord>
|
||||
<namerecord nameID="4" platformID="3" platEncID="1" langID="0x409">
|
||||
Sparse CFF Regular
|
||||
</namerecord>
|
||||
<namerecord nameID="5" platformID="3" platEncID="1" langID="0x409">
|
||||
Version 0.000
|
||||
</namerecord>
|
||||
<namerecord nameID="6" platformID="3" platEncID="1" langID="0x409">
|
||||
SparseCFF-Regular
|
||||
</namerecord>
|
||||
</name>
|
||||
|
||||
<cmap>
|
||||
<tableVersion version="0"/>
|
||||
<cmap_format_4 platformID="0" platEncID="3" language="0">
|
||||
<map code="0x61" name="a"/><!-- LATIN SMALL LETTER A -->
|
||||
<map code="0x65" name="e"/><!-- LATIN SMALL LETTER E -->
|
||||
</cmap_format_4>
|
||||
<cmap_format_4 platformID="3" platEncID="1" language="0">
|
||||
<map code="0x61" name="a"/><!-- LATIN SMALL LETTER A -->
|
||||
<map code="0x65" name="e"/><!-- LATIN SMALL LETTER E -->
|
||||
</cmap_format_4>
|
||||
</cmap>
|
||||
|
||||
<post>
|
||||
<formatType value="3.0"/>
|
||||
<italicAngle value="0.0"/>
|
||||
<underlinePosition value="-75"/>
|
||||
<underlineThickness value="50"/>
|
||||
<isFixedPitch value="0"/>
|
||||
<minMemType42 value="0"/>
|
||||
<maxMemType42 value="0"/>
|
||||
<minMemType1 value="0"/>
|
||||
<maxMemType1 value="0"/>
|
||||
</post>
|
||||
|
||||
<CFF>
|
||||
<major value="1"/>
|
||||
<minor value="0"/>
|
||||
<CFFFont name="SparseCFF-Regular">
|
||||
<version value="0.0"/>
|
||||
<Notice value=""/>
|
||||
<Copyright value=""/>
|
||||
<FullName value="Sparse CFF Regular"/>
|
||||
<FamilyName value="Sparse CFF"/>
|
||||
<isFixedPitch value="0"/>
|
||||
<ItalicAngle value="0"/>
|
||||
<UnderlinePosition value="-75"/>
|
||||
<UnderlineThickness value="50"/>
|
||||
<PaintType value="0"/>
|
||||
<CharstringType value="2"/>
|
||||
<FontMatrix value="0.001 0 0 0.001 0 0"/>
|
||||
<FontBBox value="-37 -250 582 750"/>
|
||||
<StrokeWidth value="0"/>
|
||||
<!-- charset is dumped separately as the 'GlyphOrder' element -->
|
||||
<Encoding name="StandardEncoding"/>
|
||||
<Private>
|
||||
<BlueScale value="0.039625"/>
|
||||
<BlueShift value="7"/>
|
||||
<BlueFuzz value="1"/>
|
||||
<ForceBold value="0"/>
|
||||
<LanguageGroup value="0"/>
|
||||
<ExpansionFactor value="0.06"/>
|
||||
<initialRandomSeed value="0"/>
|
||||
<defaultWidthX value="600"/>
|
||||
<nominalWidthX value="0"/>
|
||||
</Private>
|
||||
<CharStrings>
|
||||
<CharString name=".notdef">
|
||||
500 50 -250 rmoveto
|
||||
400 0 rlineto
|
||||
0 1000 rlineto
|
||||
-400 0 rlineto
|
||||
50 -950 rmoveto
|
||||
0 900 rlineto
|
||||
300 0 rlineto
|
||||
0 -900 rlineto
|
||||
endchar
|
||||
</CharString>
|
||||
<CharString name="a">
|
||||
468 -1 rmoveto
|
||||
-21 435 rlineto
|
||||
-233 70 rlineto
|
||||
-205 -76 rlineto
|
||||
27 -91 rlineto
|
||||
172 60 rlineto
|
||||
155 -40 rlineto
|
||||
3 -360 rlineto
|
||||
12 266 rmoveto
|
||||
-352 -23 rlineto
|
||||
3 -218 rlineto
|
||||
139 -34 rlineto
|
||||
221 83 rlineto
|
||||
-6 63 rlineto
|
||||
-222 -60 rlineto
|
||||
-75 52 rlineto
|
||||
2 46 rlineto
|
||||
294 35 rlineto
|
||||
endchar
|
||||
</CharString>
|
||||
<CharString name="e">
|
||||
127 228 rmoveto
|
||||
449 -2 rlineto
|
||||
-5 79 rlineto
|
||||
-255 208 rlineto
|
||||
-276 -252 rlineto
|
||||
148 -279 rlineto
|
||||
338 63 rlineto
|
||||
-17 84 rlineto
|
||||
-280 -54 rlineto
|
||||
-82 188 rlineto
|
||||
170 153 rlineto
|
||||
163 -124 rlineto
|
||||
-355 6 rlineto
|
||||
endchar
|
||||
</CharString>
|
||||
</CharStrings>
|
||||
</CFFFont>
|
||||
|
||||
<GlobalSubrs>
|
||||
<!-- The 'index' attribute is only for humans; it is ignored when parsed. -->
|
||||
</GlobalSubrs>
|
||||
</CFF>
|
||||
|
||||
<GDEF>
|
||||
<Version value="0x00010000"/>
|
||||
<GlyphClassDef>
|
||||
<ClassDef glyph="e" class="1"/>
|
||||
</GlyphClassDef>
|
||||
</GDEF>
|
||||
|
||||
<GPOS>
|
||||
<Version value="0x00010000"/>
|
||||
<ScriptList>
|
||||
<!-- ScriptCount=1 -->
|
||||
<ScriptRecord index="0">
|
||||
<ScriptTag value="DFLT"/>
|
||||
<Script>
|
||||
<DefaultLangSys>
|
||||
<ReqFeatureIndex value="65535"/>
|
||||
<!-- FeatureCount=0 -->
|
||||
</DefaultLangSys>
|
||||
<!-- LangSysCount=0 -->
|
||||
</Script>
|
||||
</ScriptRecord>
|
||||
</ScriptList>
|
||||
<FeatureList>
|
||||
<!-- FeatureCount=0 -->
|
||||
</FeatureList>
|
||||
<LookupList>
|
||||
<!-- LookupCount=0 -->
|
||||
</LookupList>
|
||||
</GPOS>
|
||||
|
||||
<GSUB>
|
||||
<Version value="0x00010000"/>
|
||||
<ScriptList>
|
||||
<!-- ScriptCount=1 -->
|
||||
<ScriptRecord index="0">
|
||||
<ScriptTag value="DFLT"/>
|
||||
<Script>
|
||||
<DefaultLangSys>
|
||||
<ReqFeatureIndex value="65535"/>
|
||||
<!-- FeatureCount=0 -->
|
||||
</DefaultLangSys>
|
||||
<!-- LangSysCount=0 -->
|
||||
</Script>
|
||||
</ScriptRecord>
|
||||
</ScriptList>
|
||||
<FeatureList>
|
||||
<!-- FeatureCount=0 -->
|
||||
</FeatureList>
|
||||
<LookupList>
|
||||
<!-- LookupCount=0 -->
|
||||
</LookupList>
|
||||
</GSUB>
|
||||
|
||||
<hmtx>
|
||||
<mtx name=".notdef" width="500" lsb="50"/>
|
||||
<mtx name="a" width="600" lsb="9"/>
|
||||
<mtx name="e" width="600" lsb="40"/>
|
||||
</hmtx>
|
||||
|
||||
</ttFont>
|
119
Tests/varLib/data/test_results/SparseCFF2-VF.ttx
Normal file
119
Tests/varLib/data/test_results/SparseCFF2-VF.ttx
Normal file
@ -0,0 +1,119 @@
|
||||
<?xml version="1.0" encoding="UTF-8"?>
|
||||
<ttFont sfntVersion="OTTO" ttLibVersion="4.41">
|
||||
|
||||
<GlyphOrder>
|
||||
<!-- The 'id' attribute is only for humans; it is ignored when parsed. -->
|
||||
<GlyphID id="0" name=".notdef"/>
|
||||
<GlyphID id="1" name="a"/>
|
||||
<GlyphID id="2" name="e"/>
|
||||
</GlyphOrder>
|
||||
|
||||
<CFF2>
|
||||
<major value="2"/>
|
||||
<minor value="0"/>
|
||||
<CFFFont name="CFF2Font">
|
||||
<FontMatrix value="0.001 0 0 0.001 0 0"/>
|
||||
<FDArray>
|
||||
<FontDict index="0">
|
||||
<Private>
|
||||
<BlueScale value="0.039625"/>
|
||||
<BlueShift value="7"/>
|
||||
<BlueFuzz value="1"/>
|
||||
<LanguageGroup value="0"/>
|
||||
<ExpansionFactor value="0.06"/>
|
||||
</Private>
|
||||
</FontDict>
|
||||
</FDArray>
|
||||
<CharStrings>
|
||||
<CharString name=".notdef">
|
||||
50 -250 -100 1 blend
|
||||
rmoveto
|
||||
400 1000 -400 100 100 -100 3 blend
|
||||
hlineto
|
||||
50 -950 rmoveto
|
||||
900 300 -900 vlineto
|
||||
</CharString>
|
||||
<CharString name="a">
|
||||
468 -1 rmoveto
|
||||
-21 435 -233 70 -205 -76 27 -91 -56 1 blend
|
||||
172 60 155 -40 -59 2 2 blend
|
||||
3 -360 56 1 blend
|
||||
rlineto
|
||||
12 266 59 -2 2 blend
|
||||
rmoveto
|
||||
-352 -23 3 -218 139 -34 221 83 -6 63 -222 -60 -75 52 15 40 13 37 -21 5 blend
|
||||
2 46 294 35 -78 -30 2 blend
|
||||
rlineto
|
||||
</CharString>
|
||||
<CharString name="e">
|
||||
1 vsindex
|
||||
127 228 -1 70 -25 1 2 blend
|
||||
rmoveto
|
||||
449 -2 1 -45 -2 -2 2 blend
|
||||
-5 79 -255 208 -276 -252 148 -279 338 63 -17 84 -280 -54 -82 188 170 153 163 -124 -355 6 27 0 0 -27 0 36 0 -29 0 -34 0 31 0 -1 0 2 0 -45 -2 13 28 100 37 0 13 0 -2 55 -40 -54 -32 -86 -30 -57 -85 -60 34 57 84 146 -5 0 21 blend
|
||||
rlineto
|
||||
</CharString>
|
||||
</CharStrings>
|
||||
<VarStore Format="1">
|
||||
<Format value="1"/>
|
||||
<VarRegionList>
|
||||
<!-- RegionAxisCount=1 -->
|
||||
<!-- RegionCount=3 -->
|
||||
<Region index="0">
|
||||
<VarRegionAxis index="0">
|
||||
<StartCoord value="0.0"/>
|
||||
<PeakCoord value="1.0"/>
|
||||
<EndCoord value="1.0"/>
|
||||
</VarRegionAxis>
|
||||
</Region>
|
||||
<Region index="1">
|
||||
<VarRegionAxis index="0">
|
||||
<StartCoord value="0.0"/>
|
||||
<PeakCoord value="0.36365"/>
|
||||
<EndCoord value="1.0"/>
|
||||
</VarRegionAxis>
|
||||
</Region>
|
||||
<Region index="2">
|
||||
<VarRegionAxis index="0">
|
||||
<StartCoord value="0.36365"/>
|
||||
<PeakCoord value="1.0"/>
|
||||
<EndCoord value="1.0"/>
|
||||
</VarRegionAxis>
|
||||
</Region>
|
||||
</VarRegionList>
|
||||
<!-- VarDataCount=2 -->
|
||||
<VarData index="0">
|
||||
<!-- ItemCount=0 -->
|
||||
<NumShorts value="0"/>
|
||||
<!-- VarRegionCount=1 -->
|
||||
<VarRegionIndex index="0" value="0"/>
|
||||
</VarData>
|
||||
<VarData index="1">
|
||||
<!-- ItemCount=0 -->
|
||||
<NumShorts value="0"/>
|
||||
<!-- VarRegionCount=2 -->
|
||||
<VarRegionIndex index="0" value="1"/>
|
||||
<VarRegionIndex index="1" value="2"/>
|
||||
</VarData>
|
||||
</VarStore>
|
||||
</CFFFont>
|
||||
|
||||
<GlobalSubrs>
|
||||
<!-- The 'index' attribute is only for humans; it is ignored when parsed. -->
|
||||
</GlobalSubrs>
|
||||
</CFF2>
|
||||
|
||||
<fvar>
|
||||
|
||||
<!-- Weight -->
|
||||
<Axis>
|
||||
<AxisTag>wght</AxisTag>
|
||||
<Flags>0x0</Flags>
|
||||
<MinValue>350.0</MinValue>
|
||||
<DefaultValue>350.0</DefaultValue>
|
||||
<MaxValue>625.0</MaxValue>
|
||||
<AxisNameID>256</AxisNameID>
|
||||
</Axis>
|
||||
</fvar>
|
||||
|
||||
</ttFont>
|
@ -999,6 +999,16 @@ Expected to see .ScriptCount==1, instead saw 0""",
|
||||
save_before_dump=True,
|
||||
)
|
||||
|
||||
def test_varlib_build_variable_cff2_with_empty_sparse_glyph(self):
|
||||
# https://github.com/fonttools/fonttools/issues/3233
|
||||
self._run_varlib_build_test(
|
||||
designspace_name="SparseCFF2",
|
||||
font_name="SparseCFF2",
|
||||
tables=["GlyphOrder", "CFF2", "fvar"],
|
||||
expected_ttx_name="SparseCFF2-VF",
|
||||
save_before_dump=True,
|
||||
)
|
||||
|
||||
|
||||
def test_load_masters_layerName_without_required_font():
|
||||
ds = DesignSpaceDocument()
|
||||
|
Loading…
x
Reference in New Issue
Block a user