DVKeyboardScroll class
Scrolls the page beneath it when the keys a reader expects are pressed.
Sits above the page body, so a control that wants a key gets it first: Flutter dispatches from whatever holds focus upwards, and this is an ancestor of everything on the page. A text field keeps its arrows, a slider keeps its arrows, a menu keeps its arrows, and what is left over reaches here.
The arrows are the one set that is shared. When a control has focus they belong to it, or to moving focus between controls on a remote; when nothing does they scroll, which is what a browser does with them. The others belong to the page whatever has focus, because no control uses them for anything else.
- Inheritance
-
- Object
- DiagnosticableTree
- Widget
- StatefulWidget
- DVKeyboardScroll
Constructors
- DVKeyboardScroll({Key? key, required Widget child, FocusNode? takesFocusFrom})
-
const
Properties
- child → Widget
-
final
- hashCode → int
-
The hash code for this object.
no setterinherited
- key → Key?
-
Controls how one widget replaces another widget in the tree.
finalinherited
- runtimeType → Type
-
A representation of the runtime type of the object.
no setterinherited
- takesFocusFrom → FocusNode?
-
A node above the page that takes focus without wanting the keys: the
page shell's selection area, which takes focus on every click into the
text. Focus on it passes here, beneath it, so a click into a paragraph
leaves the page as it was before the click -- Page Down scrolls, Esc is
the page's to answer -- and the selection stays, because focus is still
inside the area that holds it.
final
Methods
-
createElement(
) → StatefulElement -
Creates a StatefulElement to manage this widget's location in the tree.
inherited
-
createState(
) → State< DVKeyboardScroll> -
Creates the mutable state for this widget at a given location in the tree.
override
-
debugDescribeChildren(
) → List< DiagnosticsNode> -
Returns a list of DiagnosticsNode objects describing this node's
children.
inherited
-
debugFillProperties(
DiagnosticPropertiesBuilder properties) → void -
Add additional properties associated with the node.
inherited
-
noSuchMethod(
Invocation invocation) → dynamic -
Invoked when a nonexistent 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 DiagnosticsNode.toStringDeep.
inherited
-
toString(
{DiagnosticLevel minLevel = DiagnosticLevel.info}) → String -
A string representation of this object.
inherited
-
toStringDeep(
{String prefixLineOne = '', String? prefixOtherLines, DiagnosticLevel minLevel = DiagnosticLevel.debug, int wrapWidth = 65}) → String -
Returns a string representation of this node and its descendants.
inherited
-
toStringShallow(
{String joiner = ', ', DiagnosticLevel minLevel = DiagnosticLevel.debug}) → String -
Returns a one-line detailed description of the object.
inherited
-
toStringShort(
) → String -
A short, textual description of this widget.
inherited
Operators
-
operator ==(
Object other) → bool -
The equality operator.
inherited
Constants
- lineStep → const double
- How far one arrow press moves: about three lines of body text, which is what a browser scrolls and slow enough to read past.
- pageOverlap → const double
- How much of the old screen a page turn keeps. A turn that shows no line twice loses the reader's place.