ButtonThemeData constructor
- ButtonTextTheme textTheme = ButtonTextTheme.normal,
- double minWidth = 88.0,
- double height = 36.0,
- EdgeInsetsGeometry? padding,
- ShapeBorder? shape,
- ButtonBarLayoutBehavior layoutBehavior = ButtonBarLayoutBehavior.padded,
- bool alignedDropdown = false,
- Color? buttonColor,
- Color? disabledColor,
- Color? focusColor,
- Color? hoverColor,
- Color? highlightColor,
- Color? splashColor,
- ColorScheme? colorScheme,
- MaterialTapTargetSize? materialTapTargetSize,
Create a button theme object that can be used with ButtonTheme or ThemeData.
The minWidth and height parameters must greater than or equal to zero.
The ButtonTheme's methods that have a MaterialButton parameter and
have a name with a get
prefix are used to configure a
RawMaterialButton.
Implementation
const ButtonThemeData({
this.textTheme = ButtonTextTheme.normal,
this.minWidth = 88.0,
this.height = 36.0,
EdgeInsetsGeometry? padding,
ShapeBorder? shape,
this.layoutBehavior = ButtonBarLayoutBehavior.padded,
this.alignedDropdown = false,
Color? buttonColor,
Color? disabledColor,
Color? focusColor,
Color? hoverColor,
Color? highlightColor,
Color? splashColor,
this.colorScheme,
MaterialTapTargetSize? materialTapTargetSize,
}) : assert(minWidth >= 0.0),
assert(height >= 0.0),
_buttonColor = buttonColor,
_disabledColor = disabledColor,
_focusColor = focusColor,
_hoverColor = hoverColor,
_highlightColor = highlightColor,
_splashColor = splashColor,
_padding = padding,
_shape = shape,
_materialTapTargetSize = materialTapTargetSize;