Scroll view
ScrollView
is a base class for line api widgets.
ScrollView
class
¶
Bases: ScrollableContainer
A base class for a Widget that handles its own scrolling (i.e. doesn't rely on the compositor to render children).
refresh_line
method
¶
refresh_lines
method
¶
scroll_to
method
¶
def scroll_to(
self,
x=None,
y=None,
*,
animate=True,
speed=None,
duration=None,
easing=None,
force=False,
on_complete=None,
level="basic"
):
Scroll to a given (absolute) coordinate, optionally animating.
Parameters
Parameter | Default | Description |
---|---|---|
x
float | None
|
None
|
X coordinate (column) to scroll to, or |
y
float | None
|
None
|
Y coordinate (row) to scroll to, or |
animate
bool
|
True
|
Animate to new scroll position. |
speed
float | None
|
None
|
Speed of scroll if |
duration
float | None
|
None
|
Duration of animation, if |
easing
EasingFunction | str | None
|
None
|
An easing method for the scrolling animation. |
force
bool
|
False
|
Force scrolling even when prohibited by overflow styling. |
on_complete
CallbackType | None
|
None
|
A callable to invoke when the animation is finished. |
level
AnimationLevel
|
'basic'
|
Minimum level required for the animation to take place (inclusive). |