TxExpansionPanelThemeData class
与 TxExpansionPanelTheme 一起用于定义后代 TxExpansionPanel 小组件的默认属性值。
后代小组件使用“TxExpansionPanelTheme.of(context)”获取当前 TxExpansionPanelThemeData 对象。可以使用 TxExpansionPanelThemeData.copyWith 自定义 TxExpansionPanelThemeData 的实例。
TxExpansionPanelThemeData 通常使用 ThemeData.extensions 指定为整体 Theme 的一部分。
默认情况下,所有 TxExpansionPanelThemeData 属性都为“null”。当主题属性为 null 时, TxExpansionPanel 将根据整体 Theme 的 textTheme 和 colorScheme 提供自己的默认值。 有关详细信息,请参阅各个 TxExpansionPanel 属性。
- Inheritance
-
- Object
- ThemeExtension<
TxExpansionPanelThemeData> - TxExpansionPanelThemeData
- Mixed-in types
- Annotations
Constructors
- TxExpansionPanelThemeData.new({Color? backgroundColor, Color? collapsedBackgroundColor, EdgeInsetsGeometry? panelPadding, AlignmentGeometry? expandedAlignment, EdgeInsetsGeometry? childrenPadding, Color? iconColor, Color? collapsedIconColor, Color? textColor, Color? collapsedTextColor, ShapeBorder? shape, ShapeBorder? collapsedShape, Clip? clipBehavior, AnimationStyle? expansionAnimationStyle, ExpansionPanelControlAffinity? controlAffinity, Decoration? childrenDecoration})
-
创建一个 TxExpansionPanelThemeData。
const
Properties
- backgroundColor → Color?
-
覆盖 TxExpansionPanel.backgroundColor 的默认值。
final
- childrenDecoration → Decoration?
-
覆盖 TxExpansionPanel.childrenDecoration 的默认值。
final
- childrenPadding → EdgeInsetsGeometry?
-
覆盖 TxExpansionPanel.childrenPadding 的默认值。
final
- clipBehavior → Clip?
-
覆盖 TxExpansionPanel.clipBehavior 的默认值。
final
- collapsedBackgroundColor → Color?
-
覆盖 TxExpansionPanel.collapsedBackgroundColor 的默认值。
final
- collapsedIconColor → Color?
-
覆盖 TxExpansionPanel.collapsedIconColor 的默认值。
final
- collapsedShape → ShapeBorder?
-
覆盖 TxExpansionPanel.collapsedShape 的默认值。
final
- collapsedTextColor → Color?
-
覆盖 TxExpansionPanel.collapsedTextColor 的默认值。
final
- controlAffinity → ExpansionPanelControlAffinity?
-
覆盖 TxExpansionPanel.controlAffinity 的默认值。
final
- expandedAlignment → AlignmentGeometry?
-
覆盖 TxExpansionPanel.expandedAlignment 的默认值。
final
- expansionAnimationStyle → AnimationStyle?
-
覆盖 TxExpansionPanel.expansionAnimationStyle 的默认值。
final
- hashCode → int
-
The hash code for this object.
no setteroverride
- iconColor → Color?
-
覆盖 TxExpansionPanel.iconColor 的默认值。
final
- panelPadding → EdgeInsetsGeometry?
-
覆盖 TxExpansionPanel.panelPadding 的默认值。
final
- runtimeType → Type
-
A representation of the runtime type of the object.
no setterinherited
- shape → ShapeBorder?
-
重写 TxExpansionPanel.shape 的默认值。
final
- textColor → Color?
-
重写 TxExpansionPanel.textColor 的默认值。
final
- type → Object
-
The extension's type.
no setterinherited
Methods
-
copyWith(
{Color? backgroundColor, Color? collapsedBackgroundColor, EdgeInsetsGeometry? panelPadding, AlignmentGeometry? expandedAlignment, EdgeInsetsGeometry? childrenPadding, Color? iconColor, Color? collapsedIconColor, Color? textColor, Color? collapsedTextColor, ShapeBorder? shape, ShapeBorder? collapsedShape, Clip? clipBehavior, AnimationStyle? expansionAnimationStyle, ExpansionPanelControlAffinity? controlAffinity, Decoration? childrenDecoration}) → TxExpansionPanelThemeData -
创建此对象的副本,并将给定字段替换为新值。
override
-
debugFillProperties(
DiagnosticPropertiesBuilder properties) → void -
Add additional properties associated with the node.
override
-
lerp(
covariant ThemeExtension< TxExpansionPanelThemeData> ? other, double t) → ThemeExtension<TxExpansionPanelThemeData> -
Linearly interpolate with another ThemeExtension object.
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