DatePicker class

Inheritance

Constructors

DatePicker({Key? key, bool allowClear = true, bool autoFocus = false, bool bordered = true, Widget dateBuilder(DateTime currentDate, DateTime today)?, bool disabled = false, bool disabledDate(DateTime currentDate)?, Widget getPopupContainer()?, bool inputReadOnly = false, DatePickerMode? mode, Widget? nextIcon, bool? open, Widget panelBuilder()?, Picker picker = Picker.date, String? placeholder, Alignment placement = Alignment.bottomLeft, Widget? prevIcon, DatePickerSize size = DatePickerSize.middle, DatePickerStatus? status, Widget? suffixIcon, Widget? superNextIcon, Widget? superPrevIcon, void onOpenChange(bool open)?, void onPanelChange(DateTime value, DatePickerMode mode)?, DateTime? defaultPickerValue, DateTime? defaultValue, bool disabledTime(DateTime date)?, String format = 'YYYY-MM-DD', Widget extraFooterBuilder(DatePickerMode mode)?, bool? showNow, bool? showTime, bool showToday = true, DateTime? value, void onChange(DateTime date, String dateString)?, void onOk()?})
const
DatePicker.month({Key? key, bool allowClear = true, bool autoFocus = false, bool bordered = true, Widget dateBuilder(DateTime currentDate, DateTime today)?, bool disabled = false, bool disabledDate(DateTime currentDate)?, Widget getPopupContainer()?, bool inputReadOnly = false, DatePickerMode? mode, Widget? nextIcon, bool? open, Widget panelBuilder()?, Picker picker = Picker.date, String? placeholder, Alignment placement = Alignment.bottomLeft, Widget? prevIcon, DatePickerSize size = DatePickerSize.middle, DatePickerStatus? status, Widget? suffixIcon, Widget? superNextIcon, Widget? superPrevIcon, void onOpenChange(bool open)?, void onPanelChange(DateTime value, DatePickerMode mode)?, DateTime? defaultPickerValue, DateTime? defaultValue, String format = 'YYYY-MM', void monthCellBuilder(DateTime date)?, Widget extraFooterBuilder(DatePickerMode mode)?, DateTime? value, void onChange(DateTime date, String dateString)?})
const
DatePicker.quarter({Key? key, bool allowClear = true, bool autoFocus = false, bool bordered = true, Widget dateBuilder(DateTime currentDate, DateTime today)?, bool disabled = false, bool disabledDate(DateTime currentDate)?, Widget getPopupContainer()?, bool inputReadOnly = false, DatePickerMode? mode, Widget? nextIcon, bool? open, Widget panelBuilder()?, Picker picker = Picker.date, String? placeholder, Alignment placement = Alignment.bottomLeft, Widget? prevIcon, DatePickerSize size = DatePickerSize.middle, DatePickerStatus? status, Widget? suffixIcon, Widget? superNextIcon, Widget? superPrevIcon, void onOpenChange(bool open)?, void onPanelChange(DateTime value, DatePickerMode mode)?, DateTime? defaultPickerValue, DateTime? defaultValue, String format = 'YYYY-QQ', Widget extraFooterBuilder(DatePickerMode mode)?, DateTime? value, void onChange(DateTime date, String dateString)?})
const
DatePicker.week({Key? key, bool allowClear = true, bool autoFocus = false, bool bordered = true, Widget dateBuilder(DateTime currentDate, DateTime today)?, bool disabled = false, bool disabledDate(DateTime currentDate)?, Widget getPopupContainer()?, bool inputReadOnly = false, DatePickerMode? mode, Widget? nextIcon, bool? open, Widget panelBuilder()?, Picker picker = Picker.date, String? placeholder, Alignment placement = Alignment.bottomLeft, Widget? prevIcon, DatePickerSize size = DatePickerSize.middle, DatePickerStatus? status, Widget? suffixIcon, Widget? superNextIcon, Widget? superPrevIcon, void onOpenChange(bool open)?, void onPanelChange(DateTime value, DatePickerMode mode)?, DateTime? defaultPickerValue, DateTime? defaultValue, String format = 'YYYY-WW', Widget extraFooterBuilder(DatePickerMode mode)?, DateTime? value, void onChange(DateTime date, String dateString)?})
const
DatePicker.year({Key? key, bool allowClear = true, bool autoFocus = false, bool bordered = true, Widget dateBuilder(DateTime currentDate, DateTime today)?, bool disabled = false, bool disabledDate(DateTime currentDate)?, Widget getPopupContainer()?, bool inputReadOnly = false, DatePickerMode? mode, Widget? nextIcon, bool? open, Widget panelBuilder()?, Picker picker = Picker.date, String? placeholder, Alignment placement = Alignment.bottomLeft, Widget? prevIcon, DatePickerSize size = DatePickerSize.middle, DatePickerStatus? status, Widget? suffixIcon, Widget? superNextIcon, Widget? superPrevIcon, void onOpenChange(bool open)?, void onPanelChange(DateTime value, DatePickerMode mode)?, DateTime? defaultPickerValue, DateTime? defaultValue, String format = 'YYYY', Widget extraFooterBuilder(DatePickerMode mode)?, DateTime? value, void onChange(DateTime date, String dateString)?})
const

Properties

allowClear bool
final
autoFocus bool
final
bordered bool
final
dateBuilder → (Widget Function(DateTime currentDate, DateTime today)?)
final
defaultPickerValue DateTime?
final
defaultValue DateTime?
final
disabled bool
final
disabledDate → (bool Function(DateTime currentDate)?)
final
disabledTime → (bool Function(DateTime date)?)
final
extraFooterBuilder → (Widget Function(DatePickerMode mode)?)
final
format String
final
getPopupContainer → (Widget Function()?)
final
hashCode int
The hash code for this object.
no setterinherited
inputReadOnly bool
final
key Key?
Controls how one widget replaces another widget in the tree.
finalinherited
mode DatePickerMode?
final
monthCellBuilder → (void Function(DateTime date)?)
final
nextIcon Widget?
final
onChange → (void Function(DateTime date, String dateString)?)
final
onOk → (void Function()?)
final
onOpenChange → (void Function(bool open)?)
final
onPanelChange → (void Function(DateTime value, DatePickerMode mode)?)
final
open bool?
final
panelBuilder → (Widget Function()?)
final
picker Picker
final
placeholder String?
final
placement Alignment
final
prevIcon Widget?
final
runtimeType Type
A representation of the runtime type of the object.
no setterinherited
showNow bool?
final
showTime bool?
final
showToday bool
final
size DatePickerSize
final
status DatePickerStatus?
final
suffixIcon Widget?
final
superNextIcon Widget?
final
superPrevIcon Widget?
final
value DateTime?
final

Methods

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