SearchBar class
- Inheritance
-
- Object
- DiagnosticableTree
- Widget
- StatefulWidget
- SearchBar
- Implemented types
Constructors
- SearchBar({Key? key, double height = 46, Color? backgroundColor, double underlineHeight = 0, Color underlineColor = const Color(0xFFeeeeee), bool visibilityUnderline = false, double borderWidth = 1, Color borderColor = const Color(0xffe5e5e5), Color color = const Color(0xffffffff), EdgeInsetsGeometry margin = const EdgeInsets.only(left: 20, top: 4, right: 20, bottom: 6), double borderRadius = 4, double textFontSize = 14.0, Color textColor = const Color(0xff1A1A1A), String hint = "点击这里开始搜索吧", Icon searchIcon = const Icon(Icons.search, color: Color(0xffA6A6A6)), SearchBarClick? click})
-
const
Properties
- backgroundColor → Color?
-
导航栏背景颜色
final
- borderColor → Color
-
搜索条边框颜色
final
- borderRadius → double
-
搜索条边框圆角(默认4)
final
- borderWidth → double
-
搜索条边框宽度(默认1)
final
- click → SearchBarClick?
-
单击事件回调
final
- color → Color
-
搜索条背景色
final
- hashCode → int
-
The hash code for this object.
no setterinherited
- height → double
-
搜索条高度
final
- hint → String
-
搜索文本提示内容
final
- key → Key?
-
Controls how one widget replaces another widget in the tree.
finalinherited
- margin → EdgeInsetsGeometry
-
搜索条外边距
final
- preferredSize → Size
-
The size this widget would prefer if it were otherwise unconstrained.
no setteroverride
- runtimeType → Type
-
A representation of the runtime type of the object.
no setterinherited
- searchIcon → Icon
-
搜索图标
final
- textColor → Color
-
搜索文本颜色
final
- textFontSize → double
-
搜索文本字号(默认14)
final
- underlineColor → Color
-
搜索条下方分割线颜色
final
- underlineHeight → double
-
搜索条下方分割线高度
final
- visibilityUnderline → bool
-
是否显示搜索条下方分割线(默认隐藏)
final
Methods
-
createElement(
) → StatefulElement -
Creates a StatefulElement to manage this widget's location in the tree.
inherited
-
createState(
) → _SearchBarState -
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