CropArea class abstract

An abstract class representing different types of crop areas for image manipulation. This class includes properties like isEditable, isCircle, and keepAspectRatio, and provides factory constructors for creating different crop area types.

Implementers

Constructors

CropArea({required bool isEditable, required bool isCircle, required bool keepAspectRatio})
Creates an instance of CropArea.
const
CropArea.aspectRatio(double aspectRatio, {required bool isEditable, required double margin})
Factory constructor that creates an AspectRatioCropArea with a specific aspect ratio.
factory
CropArea.circle(Size size, {required bool keepAspectRatio, required bool isEditable, Offset? origin})
Factory constructor that creates a CircleCropArea with a specified size.
factory
CropArea.free(Size size, {required bool isEditable, Offset? origin})
Factory constructor that creates a FreeCropArea with a specified size.
factory

Properties

hashCode int
The hash code for this object.
no setterinherited
isCircle bool
A boolean flag indicating whether the crop area is circular.
final
isEditable bool
A boolean flag indicating whether the crop area is editable.
final
keepAspectRatio bool
A boolean flag indicating whether the aspect ratio should be maintained.
final
runtimeType Type
A representation of the runtime type of the object.
no setterinherited

Methods

getArea(Size size) Rect
Abstract method to calculate and return the crop area as a Rect. The method uses the provided size to calculate the area.
noSuchMethod(Invocation invocation) → dynamic
Invoked when a nonexistent method or property is accessed.
inherited
toString() String
A string representation of this object.
inherited

Operators

operator ==(Object other) bool
The equality operator.
inherited