SliverGeometry class

Describes the amount of space occupied by a RenderSliver.

A sliver can occupy space in several different ways, which is why this class contains multiple values.

Inheritance
Annotations
  • @immutable

Constructors

SliverGeometry({double scrollExtent: 0.0, double paintExtent: 0.0, double paintOrigin: 0.0, double layoutExtent, double maxPaintExtent: 0.0, double maxScrollObstructionExtent: 0.0, double hitTestExtent, bool visible, bool hasVisualOverflow: false, double scrollOffsetCorrection, double cacheExtent })
Creates an object that describes the amount of space occupied by a sliver. [...]
const

Properties

cacheExtent double
How many pixels the sliver has consumed in the SliverConstraints.remainingCacheExtent. [...]
final
hasVisualOverflow bool
Whether this sliver has visual overflow. [...]
final
hitTestExtent double
The distance from where this sliver started painting to the bottom of where it should accept hits. [...]
final
layoutExtent double
The distance from the first visible part of this sliver to the first visible part of the next sliver, assuming the next sliver's SliverConstraints.scrollOffset is zero. [...]
final
maxPaintExtent double
The (estimated) total paint extent that this sliver would be able to provide if the SliverConstraints.remainingPaintExtent was infinite. [...]
final
maxScrollObstructionExtent double
The maximum extent by which this sliver can reduce the area in which content can scroll if the sliver were pinned at the edge. [...]
final
paintExtent double
The amount of currently visible visual space that was taken by the sliver to render the subset of the sliver that covers all or part of the SliverConstraints.remainingPaintExtent in the current viewport. [...]
final
paintOrigin double
The visual location of the first visible part of this sliver relative to its layout position. [...]
final
scrollExtent double
The (estimated) total scrollable extent that this sliver has content for. [...]
final
scrollOffsetCorrection double
If this is non-zero after RenderSliver.performLayout returns, the scroll offset will be adjusted by the parent and then the entire layout of the parent will be rerun. [...]
final
visible bool
Whether this sliver should be painted. [...]
final
hashCode int
The hash code for this object. [...]
read-only, inherited
runtimeType Type
A representation of the runtime type of the object.
read-only, inherited

Methods

debugAssertIsValid({InformationCollector informationCollector }) bool
Asserts that this geometry is internally consistent. [...]
debugFillProperties(DiagnosticPropertiesBuilder properties) → void
Add additional properties associated with the node. [...]
override
toStringShort() String
A brief description of this object, usually just the runtimeType and the hashCode. [...]
override
noSuchMethod(Invocation invocation) → dynamic
Invoked when a non-existent method or property is accessed. [...]
inherited
toDiagnosticsNode({String name, DiagnosticsTreeStyle style }) DiagnosticsNode
Returns a debug representation of the object that is used by debugging tools and by toStringDeep. [...]
inherited
toString({DiagnosticLevel minLevel: DiagnosticLevel.debug }) String
Returns a string representation of this object.
inherited

Operators

operator ==(dynamic other) bool
The equality operator. [...]
inherited

Constants

zero → const SliverGeometry
A sliver that occupies no space at all.
const SliverGeometry()