[varLib/avar2] Don't require base master to be specified explicitly
We can deduce it as empty mapping.
This commit is contained in:
parent
ff7f49a94c
commit
d915f08e76
@ -232,6 +232,11 @@ def _add_avar(font, axes, mappings, axisTags):
|
||||
for mapping in mappings
|
||||
]
|
||||
|
||||
# If base-master is missing, insert it at zero location.
|
||||
if not any(all(v == 0 for k, v in loc.items()) for loc in inputLocations):
|
||||
inputLocations.insert(0, {})
|
||||
outputLocations.insert(0, {})
|
||||
|
||||
model = models.VariationModel(inputLocations, axisTags)
|
||||
builder = varStore.OnlineVarStoreBuilder(axisTags)
|
||||
builder.setModel(model)
|
||||
|
@ -14,13 +14,6 @@
|
||||
<labelname xml:lang="en">Weight</labelname>
|
||||
</axis>
|
||||
<mappings>
|
||||
<mapping>
|
||||
<input>
|
||||
<dimension name="weight" xvalue="90"/>
|
||||
</input>
|
||||
<output>
|
||||
</output>
|
||||
</mapping>
|
||||
<mapping>
|
||||
<input>
|
||||
<dimension name="weight" xvalue="128"/>
|
||||
|
Loading…
x
Reference in New Issue
Block a user