ScrollViewport

data class ScrollViewport(val height: Double, val scrollTop: Double, val maxScrollTop: Double, val linePositions: List<Double>, val lineHeights: List<Double>, val insets: ScrollInsets = NO_SCROLL_INSETS, val credits: ScrollItem? = null, val targetScrollRatio: Double = targetScrollRatio())(source)

Where the renderer has laid the lines out, in the scroll content's coordinates. Pixels.

Constructors

Link copied to clipboard
constructor(height: Double, scrollTop: Double, maxScrollTop: Double, linePositions: List<Double>, lineHeights: List<Double>, insets: ScrollInsets = NO_SCROLL_INSETS, credits: ScrollItem? = null, targetScrollRatio: Double = targetScrollRatio())

Properties

Link copied to clipboard

The credits after the last line, when there are any laid out.

Link copied to clipboard

The view's height.

Link copied to clipboard

Space at the top and bottom the lines keep clear of.

Link copied to clipboard

Each line's height, by line index.

Link copied to clipboard

Each line's top, by line index.

Link copied to clipboard

How far it can be scrolled.

Link copied to clipboard

How far it is scrolled.

Link copied to clipboard

0 puts the active lines at the top, 0.5 in the middle.