FontFeature.alternative constructor
const
FontFeature.alternative(
- int value
Access alternative glyphs. (aalt
)
This feature selects the given glyph variant for glyphs in the span.
{@tool sample}
The Raleway font supports several alternate glyphs. The code
below shows how specific glyphs can be selected. With aalt
set
to zero, the default, the normal glyphs are used. With a
non-zero value, Raleway substitutes small caps for lower case
letters. With value 2, the lowercase "a" changes to a stemless
"a", whereas the lowercase "t" changes to a vertical bar instead
of having a curve. By targeting specific letters in the text
(using widgets.Text.rich
), the desired rendering for each glyph can be
achieved.
** See code in examples/api/lib/ui/text/font_feature.font_feature_alternative.0.dart ** {@end-tool}
See also:
Implementation
const FontFeature.alternative(this.value) : feature = 'aalt';