perHeight static method

double perHeight(
  1. BuildContext context,
  2. int percentage
)

Retorna percentual da altura total. percentage vai de 0 à 100

Implementation

static double perHeight(BuildContext context, int percentage) {
  return (MediaQuery.of(context).size.height * percentage) / 100;
}