getBounds method

Box? getBounds({
  1. PositionScheme scheme = Position.scheme,
})

Returns the current bounds if it's populated and conforms to scheme, or otherwise returns one calculated by calculateBounds.

Implementation

Box? getBounds({PositionScheme scheme = Position.scheme}) {
  final b = bounds;
  return b != null && b.conforming.conformsWith(scheme)
      ? b
      : calculateBounds(scheme: scheme);
}