maybeTextScaleFactorOf static method

double? maybeTextScaleFactorOf(
  1. BuildContext context
)

Returns textScaleFactor for the nearest MediaQuery ancestor or null, if no such ancestor exists.

Use of this method will cause the given context to rebuild any time that the MediaQueryData.textScaleFactor property of the ancestor MediaQuery changes.

Implementation

static double? maybeTextScaleFactorOf(BuildContext context) => _maybeOf(context, _MediaQueryAspect.textScaleFactor)?.textScaleFactor;