ListTileThemeData class
Used with ListTileTheme to define default property values for descendant ListTile widgets, as well as classes that build ListTiles, like CheckboxListTile, RadioListTile, and SwitchListTile.
Descendant widgets obtain the current ListTileThemeData object
using ListTileTheme.of(context)
. Instances of
ListTileThemeData can be customized with
ListTileThemeData.copyWith.
A ListTileThemeData is often specified as part of the overall Theme with ThemeData.listTileTheme.
All ListTileThemeData properties are null
by default.
When a theme property is null, the ListTile will provide its own
default based on the overall Theme's textTheme and
colorScheme. See the individual ListTile properties for details.
The Drawer widget specifies a list tile theme for its children that defines style to be ListTileStyle.drawer.
See also:
- ThemeData, which describes the overall theme information for the application.
- Mixed in types
- Annotations
Constructors
-
ListTileThemeData({bool? dense, ShapeBorder? shape, ListTileStyle? style, Color? selectedColor, Color? iconColor, Color? textColor, TextStyle? titleTextStyle, TextStyle? subtitleTextStyle, TextStyle? leadingAndTrailingTextStyle, EdgeInsetsGeometry? contentPadding, Color? tileColor, Color? selectedTileColor, double? horizontalTitleGap, double? minVerticalPadding, double? minLeadingWidth, bool? enableFeedback, MaterialStateProperty<
MouseCursor?> ? mouseCursor, VisualDensity? visualDensity, double? minTileHeight, ListTileTitleAlignment? titleAlignment}) -
Creates a ListTileThemeData.
const
Properties
- contentPadding → EdgeInsetsGeometry?
-
Overrides the default value of ListTile.contentPadding.
final
- dense → bool?
-
Overrides the default value of ListTile.dense.
final
- enableFeedback → bool?
-
Overrides the default value of ListTile.enableFeedback.
final
- hashCode → int
-
The hash code for this object.
no setteroverride
- horizontalTitleGap → double?
-
Overrides the default value of ListTile.horizontalTitleGap.
final
- iconColor → Color?
-
Overrides the default value of ListTile.iconColor.
final
- leadingAndTrailingTextStyle → TextStyle?
-
Overrides the default value of ListTile.leadingAndTrailingTextStyle.
final
- minLeadingWidth → double?
-
Overrides the default value of ListTile.minLeadingWidth.
final
- minTileHeight → double?
-
Overrides the default value of ListTile.minTileHeight.
final
- minVerticalPadding → double?
-
Overrides the default value of ListTile.minVerticalPadding.
final
-
mouseCursor
→ MaterialStateProperty<
MouseCursor?> ? -
If specified, overrides the default value of ListTile.mouseCursor.
final
- runtimeType → Type
-
A representation of the runtime type of the object.
no setterinherited
- selectedColor → Color?
-
Overrides the default value of ListTile.selectedColor.
final
- selectedTileColor → Color?
-
Overrides the default value of ListTile.selectedTileColor.
final
- shape → ShapeBorder?
-
Overrides the default value of ListTile.shape.
final
- style → ListTileStyle?
-
Overrides the default value of ListTile.style.
final
- subtitleTextStyle → TextStyle?
-
Overrides the default value of ListTile.subtitleTextStyle.
final
- textColor → Color?
-
Overrides the default value of ListTile.textColor.
final
- tileColor → Color?
-
Overrides the default value of ListTile.tileColor.
final
- titleAlignment → ListTileTitleAlignment?
-
If specified, overrides the default value of ListTile.titleAlignment.
final
- titleTextStyle → TextStyle?
-
Overrides the default value of ListTile.titleTextStyle.
final
- visualDensity → VisualDensity?
-
If specified, overrides the default value of ListTile.visualDensity.
final
Methods
-
copyWith(
{bool? dense, ShapeBorder? shape, ListTileStyle? style, Color? selectedColor, Color? iconColor, Color? textColor, TextStyle? titleTextStyle, TextStyle? subtitleTextStyle, TextStyle? leadingAndTrailingTextStyle, EdgeInsetsGeometry? contentPadding, Color? tileColor, Color? selectedTileColor, double? horizontalTitleGap, double? minVerticalPadding, double? minLeadingWidth, double? minTileHeight, bool? enableFeedback, MaterialStateProperty< MouseCursor?> ? mouseCursor, bool? isThreeLine, VisualDensity? visualDensity, ListTileTitleAlignment? titleAlignment}) → ListTileThemeData - Creates a copy of this object 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(
ListTileThemeData? a, ListTileThemeData? b, double t) → ListTileThemeData? - Linearly interpolate between ListTileThemeData objects.