decode static method
Implementation
static NapaTextStyle? decode(dynamic data) {
if (data == null) {
return null;
}
return NapaTextStyle(
inherit: data['inherit'],
color: decodeColor(data['color']),
backgroundColor: decodeColor(data['backgroundColor']),
fontSize: data['fontSize'],
fontWeight: decodeFontWeight(data['fontWeight']),
fontStyle: decodeFontStyle(data['fontStyle']),
letterSpacing: data['letterSpacing'],
wordSpacing: data['wordSpacing'],
textBaseline: decodeTextBaseline(data['textBaseline']),
height: data['height'],
leadingDistribution: decodeTextLeadingDistribution(data['leadingDistribution']),
locale: decodeLocale(data['locale']),
foreground: NapaPaint.decode(data['foreground']),
background: NapaPaint.decode(data['background']),
shadows: decodeShadows(data['shadows']),
fontFeatures: decodeFontFeatures(data['fontFeatures']),
fontVariations: decodeFontVariations(data['fontVariations']),
decoration: decodeNapaTextDecorationList(data['decoration']),
decorationColor: decodeColor(data['decorationColor']),
decorationStyle: decodeTextDecorationStyle(data['decorationStyle']),
decorationThickness: data['decorationThickness'],
debugLabel: data['debugLabel'],
fontFamily: data['fontFamily'],
fontFamilyFallback: data['fontFamilyFallback'],
package: data['package'],
overflow: decodeTextOverflow(data['overflow'])
);
}