flutter_layout_grid library

Classes

AutoPlacement
Controls how the auto-placement algorithm works, specifying exactly how auto-placed items get flowed into the grid.
FixedTrackSize
Sizes the track to a specific number of pixels.
FlexibleTrackSize
Sizes the track by taking a part of the remaining space once all the other tracks have been laid out on the same axis.
GridArea
Represents a rectangular region on the grid.
GridPlacement
A widget that controls where a child of a LayoutGrid is placed. If a grid item is not wrapped by a GridPlacement, it will be placed in the first available space, spanning one row and one column.
IntrinsicContentTrackSize
Sizes the track according to the intrinsic dimensions of all its cells.
LayoutGrid
Lays out its children using a approximation of the CSS Grid Layout algorithm, as described here:
NamedAreaGridPlacement
Grid placement based on the name of an area provided to the grid via LayoutGrid.areas.
NamedAreaGridPlacementBuilder
Dumb little helper class for slightly cleaner grid child placement
TrackSize
Base class to describe the width (for columns) or height (for rows) of a track in a RenderLayoutGrid.

Enums

AutoPlacementPacking
Packing strategies used by the auto-placement algorithm.
GridFit
Determines the constraints available to the grid layout algorithm.
TrackType
Passed to TrackSize functions to indicate the type of track whose cross-axis is being measured.

Extensions

GridPlacementExtensions on Widget
Extension methods for terse placement syntax
TrackUnitsNumExtension on num
Defines a set of extension methods on num for creating tracks

Constants

auto → const IntrinsicContentTrackSize
An IntrinsicContentTrackSize, mirroring CSS's name for the track sizing function.

Functions

fixed(double sizeInPx, {String? debugLabel}) FixedTrackSize
Returns a new track size that is exactly sizeInPx wide.
flex(double flexFactor, {String? debugLabel}) FlexibleTrackSize
Returns a new track size that expands to fill available space.
gridArea(String name) NamedAreaGridPlacementBuilder
Convenience function for pretty grid definitions, ala:
intrinsic({String? debugLabel}) IntrinsicContentTrackSize
Returns a track size that is sized based on its contents.
mainAxisForTrackType(TrackType type) Axis
Returns the direction of cell layout for the provided type.
measurementAxisForTrackType(TrackType type) Axis
Returns the axis measured by a TrackSize associated with a particular TrackType.
repeat(int times, List<TrackSize> tracks) List<TrackSize>
Returns this list repeated times times.