DateTimeField class
Shows an _InputDropdown
that'll trigger DateTimeField._handleTap
whenever the user
clicks on it ! The date picker is platform responsive (ios date picker style for ios, ...)
- Inheritance
-
- Object
- DiagnosticableTree
- Widget
- StatefulWidget
- DateTimeField
- Available extensions
Constructors
-
DateTimeField({required ValueChanged<
DateTime?> ? onChanged, Key? key, DateTime? value, VoidCallback? onTap, TextStyle? style, FocusNode? focusNode, bool autofocus = false, bool? enableFeedback, EdgeInsetsGeometry? padding, bool hideDefaultSuffixIcon = false, InputDecoration? decoration, DateTime? initialPickerDateTime, CupertinoDatePickerOptions cupertinoDatePickerOptions = const CupertinoDatePickerOptions(), MaterialDatePickerOptions materialDatePickerOptions = const MaterialDatePickerOptions(), MaterialTimePickerOptions materialTimePickerOptions = const MaterialTimePickerOptions(), DateTimeFieldPickerMode mode = DateTimeFieldPickerMode.dateAndTime, DateTimeFieldPickerPlatform pickerPlatform = DateTimeFieldPickerPlatform.adaptive, DateTime? firstDate, DateTime? lastDate, DateFormat? dateFormat}) -
DateTimeField.time({Key? key, required ValueChanged<
DateTime?> ? onChanged, DateTime? value, InputDecoration? decoration, DateTime? firstDate, DateTime? lastDate, DateTime? initialPickerDateTime, TextStyle? style, CupertinoDatePickerOptions cupertinoDatePickerOptions = const CupertinoDatePickerOptions(), MaterialTimePickerOptions materialTimePickerOptions = const MaterialTimePickerOptions(), bool autofocus = false, DateFormat? dateFormat, EdgeInsetsGeometry? padding, VoidCallback? onTap, FocusNode? focusNode, bool hideDefaultSuffixIcon = false, bool? enableFeedback, DateTimeFieldPickerPlatform pickerPlatform = DateTimeFieldPickerPlatform.adaptive}) -
factory
Properties
- autofocus → bool
-
See Focus.autofocus.
final
- cupertinoDatePickerOptions → CupertinoDatePickerOptions
-
Options to customize the CupertinoDatePicker.
final
- dateFormat → DateFormat
-
The format of the shown DateTime.
final
- decoration → InputDecoration?
-
The decoration to show around the formatted DateTime.
final
- enableFeedback → bool?
-
See InkWell.enableFeedback.
final
- firstDate → DateTime
-
The first DateTime the user can select.
final
- focusNode → FocusNode?
-
See Focus.autofocus.
final
- hashCode → int
-
The hash code for this object.
no setterinherited
- hideDefaultSuffixIcon → bool
-
Hides the default suffix icon.
final
- initialPickerDateTime → DateTime?
-
The initial DateTime in the pickers, when no DateTime is selected.
final
- key → Key?
-
Controls how one widget replaces another widget in the tree.
finalinherited
- lastDate → DateTime
-
The last DateTime the user can select.
final
- materialDatePickerOptions → MaterialDatePickerOptions
-
Options to customize the
MaterialDatePicker
.final - materialTimePickerOptions → MaterialTimePickerOptions
-
Options to customize the
MaterialTimePicker
.final - mode → DateTimeFieldPickerMode
-
The mode of the DateTimeField.
final
-
onChanged
→ ValueChanged<
DateTime?> ? -
A callback that gets executed when the user changes the DateTime in the DateTimeField.
final
- onTap → VoidCallback?
-
A callback that gets executed when the user taps on the DateTimeField and before the
pickers are shown.
final
- padding → EdgeInsetsGeometry?
-
Padding around the visible portion of the DateTimeField widget.
final
- pickerPlatform → DateTimeFieldPickerPlatform
-
The platform to use for the pickers.
final
- runtimeType → Type
-
A representation of the runtime type of the object.
no setterinherited
- style → TextStyle?
-
The text style to use for text in the DateTimeField.
final
- value → DateTime?
-
The DateTime that represents the currently selected date.
final
Methods
-
createElement(
) → StatefulElement -
Creates a StatefulElement to manage this widget's location in the tree.
inherited
-
createState(
) → State< DateTimeField> -
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