TimePicker class

Returns a widget which displays a circle to be used as a picker.

Required arguments are init and end to set the initial selection. onSelectionChange is a callback function which returns new values as the user changes the interval. The rest of the params are used to change the look and feel.

Inheritance

Constructors

TimePicker({required PickedTime initTime, required PickedTime endTime, required SelectionChanged<PickedTime> onSelectionChange, required SelectionChanged<PickedTime> onSelectionEnd, Widget? child, TimePickerDecoration? decoration, double? height, double? width, int? primarySectors, int? secondarySectors, bool isInitHandlerSelectable = true, bool isEndHandlerSelectable = true, bool isSelectableHandlerMoveAble = true, DisabledRange? disabledRange, bool drawInitHandlerOnTop = false})
Creates a TimePicker.

Properties

child Widget?
an optional widget that would be mounted inside the circle
final
decoration TimePickerDecoration?
used to decorate the our widget
final
disabledRange DisabledRange?
used to disable Selection range, If null so there is no time range
final
drawInitHandlerOnTop bool
used to set priority to draw init or end handler on the top default value: false
final
endTime PickedTime
the end time
final
hashCode int
The hash code for this object.
no setterinherited
height double?
height of the canvas, default at 220
final
initTime PickedTime
the initial time
final
isEndHandlerSelectable bool
used to enabled or disabled Selection of End Handler
final
isInitHandlerSelectable bool
used to enabled or disabled Selection of Init Handler
final
isSelectableHandlerMoveAble bool
used to enabled or disabled the Movement of Init and End Handler when its not Selectable disable the dragging of both handlers
final
key Key?
Controls how one widget replaces another widget in the tree.
finalinherited
onSelectionChange SelectionChanged<PickedTime>
callback function when init and end change
final
onSelectionEnd SelectionChanged<PickedTime>
callback function when init and end finish
final
primarySectors int?
the number of primary sectors to be painted will be painted using selectionColor
final
runtimeType Type
A representation of the runtime type of the object.
no setterinherited
secondarySectors int?
the number of secondary sectors to be painted will be painted using baseColor
final
width double?
width of the canvas, default at 220
final

Methods

createElement() StatefulElement
Creates a StatefulElement to manage this widget's location in the tree.
inherited
createState() → _TimePickerState
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}) 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