ScrollTarget class

A target position to scroll to.

Created by effects like EditorView.scrollIntoView.

Annotations

Constructors

ScrollTarget(Object range, {String y = 'nearest', String x = 'nearest', double yMargin = 5, double xMargin = 5, bool isSnapshot = false})
const
ScrollTarget.fromPos(int pos, {String y = 'nearest'})
Create a scroll target from a single position.
factory

Properties

hashCode → int
The hash code for this object.
no setterinherited
isSnapshot → bool
Whether this is a snapshot restoration (absolute position).
final
range → Object
The range to scroll into view.
final
runtimeType → Type
A representation of the runtime type of the object.
no setterinherited
x → String
Horizontal scroll strategy.
final
xMargin → double
Extra horizontal margin.
final
y → String
Vertical scroll strategy ('nearest', 'start', 'end', 'center').
final
yMargin → double
Extra vertical margin.
final

Methods

clip(Object state) → ScrollTarget
Clip this scroll target to valid positions in the given state.
map(Object changes) → ScrollTarget
Map this scroll target through document changes.
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