AspectRatioModifier constructor

const AspectRatioModifier({
  1. Key? key,
  2. Widget? child,
  3. Key? modifierKey,
  4. required double aspectRatio,
})

Creates a widget with a specific aspect ratio.

The aspectRatio argument must be a finite number greater than zero.

Implementation

const AspectRatioModifier({
  super.key,
  super.child,
  super.modifierKey,
  required this.aspectRatio,
}) : assert(aspectRatio > 0.0);