FontWeightValue class
https://tr.designtokens.org/format/#font-weight
Represents a font weight. The $type property MUST be set to the string fontWeight.
The value must either be a number value in the range 1, 1000
or one of the pre-defined string values defined in the table below.
Lower numbers represent lighter weights, and higher numbers represent thicker weights, as per the OpenType wght tag specification. The pre-defined string values are aliases for specific numeric values. For example 100, "thin" and "hairline" are all the exact same value.
| numeric value | string value aliases | 100 thin, hairline 200 extra-light, ultra-light 300 light 400 normal, regular, book 500 medium 600 semi-bold, demi-bold 700 bold 800 extra-bold, ultra-bold 900 black, heavy 950 extra-black, ultra-black (not widely supported, mapped to 900)
Note: As flutter supports 900 as a maximum font weight, the 950 value is mapped to 900.
Constructors
- FontWeightValue(int value)
Properties
Methods
-
noSuchMethod(
Invocation invocation) → dynamic -
Invoked when a nonexistent method or property is accessed.
inherited
-
toString(
) → String -
A string representation of this object.
override
Operators
-
operator ==(
Object other) → bool -
The equality operator.
inherited
Static Methods
-
maybeParse(
dynamic value) → FontWeightValue? -
Returns a FontWeightValue if the
value
is a valid font weight. Otherwise returns null.