FlexibleGridOptions class
FlexibleGridOptions
- Configuration options for the FlexibleGrid
widget.
Properties:
customWidth
(double?
): Optional width of each grid item. Ifnull
, a default aspect ratio of 1.0 is used.customHeight
(double?
): Optional height of each grid item. Ifnull
, a default aspect ratio of 1.0 is used.rows
(int
): The number of rows in the grid layout. Must be greater than 0.columns
(int
): The number of columns in the grid layout. Must be greater than 0.componentsToRender
(List<Widget>
): A list of widgets (e.g., video streams or images) to render in the grid cells. If fewer components are provided than cells in the grid, the components are repeated.backgroundColor
(Color
): The background color of each grid cell. Defaults toColors.transparent
.showAspect
(bool
): Controls the visibility of the entire grid. Iffalse
, the grid is hidden. Defaults totrue
.
Example Usage:
FlexibleGridOptions(
customWidth: 100.0,
customHeight: 100.0,
rows: 3,
columns: 3,
componentsToRender: [
Text("Item 1"),
Text("Item 2"),
Icon(Icons.star),
],
backgroundColor: Colors.blueAccent,
showAspect: true,
);
Constructors
Properties
- backgroundColor → Color
-
final
- columns → int
-
final
-
componentsToRender
→ List<
Widget> -
final
- customHeight → double?
-
final
- customWidth → double?
-
final
- hashCode → int
-
The hash code for this object.
no setterinherited
- rows → int
-
final
- runtimeType → Type
-
A representation of the runtime type of the object.
no setterinherited
- showAspect → bool
-
final
Methods
-
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