parseSize method

void parseSize(
  1. String style
)

Implementation

void parseSize(String style) {
  try {
    final size = style.split("-")[1];
    if (style.startsWith("w")) {
      width = spacingMetrics.fromString(size);
    } else if (style.startsWith("h")) {
      height = spacingMetrics.fromString(size);
    }
  } on RangeError catch (_) {
    return;
  }
}