encodeTextBaseline static method
Encodes the given value
to the String representation. Supported values
are:
alphabetic
ideographic
All other values, including null
, will result in null
.
Implementation
static String? encodeTextBaseline(TextBaseline? value) {
String? result;
if (value != null) {
switch (value) {
case TextBaseline.alphabetic:
result = 'alphabetic';
break;
case TextBaseline.ideographic:
result = 'ideographic';
break;
}
}
return _stripDynamicNull(result);
}