SearchViewThemeData class
Defines the configuration of the search views created by the SearchAnchor widget.
Descendant widgets obtain the current SearchViewThemeData object using
SearchViewTheme.of(context)
.
Typically, a SearchViewThemeData is specified as part of the overall Theme with ThemeData.searchViewTheme. Otherwise, SearchViewTheme can be used to configure its own widget subtree.
All SearchViewThemeData properties are null
by default. If any of these
properties are null, the search view will provide its own defaults.
See also:
- ThemeData, which describes the overall theme for the application.
- SearchBarThemeData, which describes the theme for the search bar itself in a SearchBar widget.
- SearchAnchor, which is used to open a search view route.
- Mixed-in types
- Annotations
Constructors
- SearchViewThemeData({Color? backgroundColor, double? elevation, Color? surfaceTintColor, BoxConstraints? constraints, BorderSide? side, OutlinedBorder? shape, double? headerHeight, TextStyle? headerTextStyle, TextStyle? headerHintStyle, Color? dividerColor})
-
Creates a theme that can be used for ThemeData.searchViewTheme.
const
Properties
- backgroundColor → Color?
-
Overrides the default value of the SearchAnchor.viewBackgroundColor.
final
- constraints → BoxConstraints?
-
Overrides the value of size constraints for SearchAnchor.viewConstraints.
final
- dividerColor → Color?
-
Overrides the value of the divider color for SearchAnchor.dividerColor.
final
- elevation → double?
-
Overrides the default value of the SearchAnchor.viewElevation.
final
- hashCode → int
-
The hash code for this object.
no setteroverride
- headerHeight → double?
-
Overrides the default value of the SearchAnchor.headerHeight.
final
- headerHintStyle → TextStyle?
-
Overrides the default value for SearchAnchor.headerHintStyle.
final
- headerTextStyle → TextStyle?
-
Overrides the default value for SearchAnchor.headerTextStyle.
final
- runtimeType → Type
-
A representation of the runtime type of the object.
no setterinherited
- shape → OutlinedBorder?
-
Overrides the default value of the SearchAnchor.viewShape.
final
- side → BorderSide?
-
Overrides the default value of the SearchAnchor.viewSide.
final
- surfaceTintColor → Color?
-
Overrides the default value of the SearchAnchor.viewSurfaceTintColor.
final
Methods
-
copyWith(
{Color? backgroundColor, double? elevation, Color? surfaceTintColor, BorderSide? side, OutlinedBorder? shape, double? headerHeight, TextStyle? headerTextStyle, TextStyle? headerHintStyle, BoxConstraints? constraints, Color? dividerColor}) → SearchViewThemeData - Creates a copy of this object but with the given fields replaced with the new values.
-
debugFillProperties(
DiagnosticPropertiesBuilder properties) → void -
Add additional properties associated with the node.
override
-
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
-
toStringShort(
) → String -
A brief description of this object, usually just the runtimeType and the
hashCode.
inherited
Operators
-
operator ==(
Object other) → bool -
The equality operator.
override
Static Methods
-
lerp(
SearchViewThemeData? a, SearchViewThemeData? b, double t) → SearchViewThemeData? - Linearly interpolate between two SearchViewThemeDatas.