cacheOrigin property
Where the cache area starts relative to the scrollOffset.
Slivers that fall into the cache area located before the leading edge and after the trailing edge of the viewport should still render content because they are about to become visible when the user scrolls.
The cacheOrigin describes where the remainingCacheExtent starts relative to the scrollOffset. A cache origin of 0 means that the sliver does not have to provide any content before the current scrollOffset. A cacheOrigin of -250.0 means that even though the first visible part of the sliver will be at the provided scrollOffset, the sliver should render content starting 250.0 before the scrollOffset to fill the cache area of the viewport.
The cacheOrigin is always negative or zero and will never exceed -scrollOffset. In other words, a sliver is never asked to provide content before its zero scrollOffset.
See also:
- RenderViewport.cacheExtent for a description of a viewport's cache area.
Implementation
final double cacheOrigin;