GridOptions class abstract
Base options for grid-like widgets (GridView, SliverGrid).
- Inheritance
-
- Object
- CollectionOptions
- GridOptions
- Implementers
Constructors
- GridOptions({ScrollBehavior? scrollBehavior, bool reverse = false, AlwaysScrollableScrollPhysics? scrollPhysics, bool shrinkWrap = false, Axis scrollDirection = Axis.vertical, int loadMoreTriggerItemDistance = 2, required int crossAxisCount, double childAspectRatio = 1.0, double mainAxisSpacing = 0.0, double crossAxisSpacing = 0.0})
-
const
Properties
- childAspectRatio → double
-
final
- crossAxisCount → int
-
Used to build the grid delegate (or consumed by sliver grid).
final
- crossAxisSpacing → double
-
final
- hashCode → int
-
The hash code for this object.
no setterinherited
- loadMoreTriggerItemDistance → int
-
finalinherited
- mainAxisSpacing → double
-
final
- reverse → bool
-
Shared across all collection widgets.
finalinherited
- runtimeType → Type
-
A representation of the runtime type of the object.
no setterinherited
- scrollBehavior → ScrollBehavior?
-
finalinherited
- scrollDirection → Axis
-
finalinherited
- scrollPhysics → AlwaysScrollableScrollPhysics?
-
finalinherited
- shrinkWrap → bool
-
finalinherited
Methods
-
asOrThrow<
T extends CollectionOptions> () → T -
inherited
-
assertCorrectType(
CollectionWidgetStateType type) → void -
Runtime safety: ensure the options instance matches the widget state type.
inherited
-
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