getBaseline static method

double? getBaseline(
  1. RenderBox child,
  2. BoxConstraints constraints,
  3. TextBaseline baseline
)

Convenience function that calls RenderBox.getDistanceToBaseline.

The given child must be already laid out with constraints.

Implementation

static double? getBaseline(RenderBox child, BoxConstraints constraints, TextBaseline baseline) {
  assert(!child.debugNeedsLayout);
  assert(child.constraints == constraints);
  return child.getDistanceToBaseline(baseline, onlyReal: true);
}