width property Null safety

double width

The horizontal space required to paint this text.

Valid only after layout has been called.

Implementation

double get width {
  assert(_debugAssertTextLayoutIsValid);
  return _applyFloatingPointHack(
    textWidthBasis == TextWidthBasis.longestLine ? _paragraph!.longestLine : _paragraph!.width,
  );
}