symbolRunStyle function
The style of a symbol run inside a span styled style: CalseeSymbols at
style's weight (its wght variation, else its fontWeight); size,
colour and the rest are inherited from the span.
Implementation
TextStyle symbolRunStyle(TextStyle style) {
final weight =
style.fontVariations
?.where((v) => v.axis == symbolsFontWeight.tag)
.firstOrNull
?.value ??
(style.fontWeight ?? FontWeight.w400).value.toDouble();
return TextStyle(
fontFamily: symbolsFontFamily,
fontWeight: nearestFontWeight(weight),
fontVariations: [symbolsFontWeight.variation(weight)],
);
}