SearchTextField class

Inheritance

Constructors

SearchTextField({Key? key, TextEditingController? controller, ValueChanged<String>? onChanged, ValueChanged<String>? onSubmitted, TextStyle? style, String? placeholder, TextStyle? placeholderStyle, BoxDecoration? decoration, Color? backgroundColor, TextInputType? keyboardType = TextInputType.text, EdgeInsetsGeometry padding = EdgeInsets.zero, Color? itemColor, double itemSize = 20.0, EdgeInsetsGeometry prefixInsets = const EdgeInsetsDirectional.only(start: 4.0), Widget prefixIcon = const Icon(Icons.search), OverlayVisibilityMode suffixMode = OverlayVisibilityMode.editing, EdgeInsetsGeometry suffixInsets = const EdgeInsetsDirectional.only(end: 4.0), Icon suffixIcon = const Icon(Icons.clear), VoidCallback? onPrefixTap, VoidCallback? onSuffixTap, FocusNode? focusNode, bool enableIMEPersonalizedLearning = true, bool autofocus = false, VoidCallback? onTap, bool autocorrect = true, bool? enabled})
Creates a SearchTextField.
const

Properties

autocorrect bool
Whether to enable autocorrection.
final
autofocus bool
Whether this text field should focus itself if nothing else is already focused.
final
backgroundColor Color?
Set the decoration property's background color.
final
controller TextEditingController?
Controls the text being edited.
final
decoration BoxDecoration?
Sets the decoration for the text field.
final
enabled bool?
Disables the text field when false.
final
enableIMEPersonalizedLearning bool
Whether to enable that the IME update personalized data such as typing history and user dictionary data.
final
focusNode FocusNode?
An optional focus node to use as the focus node for this widget.
final
hashCode int
The hash code for this object.
no setterinherited
itemColor Color?
Sets the color for the suffix and prefix icons.
final
itemSize double
Sets the base icon size for the suffix and prefix icons.
final
key Key?
Controls how one widget replaces another widget in the tree.
finalinherited
keyboardType TextInputType?
The keyboard type for this search field.
final
onChanged ValueChanged<String>?
Invoked upon user input.
final
onPrefixTap VoidCallback?
Sets the prefix action.
final
onSubmitted ValueChanged<String>?
Invoked upon keyboard submission.
final
onSuffixTap VoidCallback?
Sets the suffix action.
final
onTap VoidCallback?
Called for the first tap in a series of taps.
final
padding EdgeInsetsGeometry
Sets the padding insets for the text and placeholder.
final
placeholder String?
A hint placeholder text that appears when the text entry is empty.
final
placeholderStyle TextStyle?
Sets the style of the placeholder of the text field.
final
prefixIcon Widget
Sets a prefix widget.
final
prefixInsets EdgeInsetsGeometry
Sets the padding insets for the suffix.
final
runtimeType Type
A representation of the runtime type of the object.
no setterinherited
style TextStyle?
Allows changing the style of the text.
final
suffixIcon Icon
Sets the suffix widget's icon.
final
suffixInsets EdgeInsetsGeometry
Sets the padding insets for the prefix.
final
suffixMode OverlayVisibilityMode
Whether the clear button should be visible.
final

Methods

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