diff --git a/src/fontra/core/instancer.py b/src/fontra/core/instancer.py index 490614916..a2b7345e8 100644 --- a/src/fontra/core/instancer.py +++ b/src/fontra/core/instancer.py @@ -283,7 +283,10 @@ def instantiate( if self.fontInstancer.variableGlyphAxisRanges is not None: self.fontInstancer.updateVariableGlyphAxisRanges( - self.glyph.name, subsetLocationKeep(location, self.glyphAxisNames) + self.glyph.name, + subsetLocationKeep( + self.defaultSourceLocation | location, self.glyphAxisNames + ), ) try: diff --git a/src/fontra/workflow/actions/glyph.py b/src/fontra/workflow/actions/glyph.py index c0269ccf1..4d527e83c 100644 --- a/src/fontra/workflow/actions/glyph.py +++ b/src/fontra/workflow/actions/glyph.py @@ -409,6 +409,8 @@ def trimGlyphByAxisRanges(fontInstancer, instancer, axisRanges): newAxes = [] for axis in glyph.axes: axisRange = axisRanges.get(axis.name) + # Ensure the range is actually within the original axis' range + axisRange.clipRange(axis.minValue, axis.maxValue) if axisRange is None: axisRanges[axis.name] = AxisRange(axis.defaultValue, axis.defaultValue) elif axisRange.isEmpty():