copyWith method

InputDecorationTheme copyWith({
  1. TextStyle? labelStyle,
  2. TextStyle? floatingLabelStyle,
  3. TextStyle? helperStyle,
  4. int? helperMaxLines,
  5. TextStyle? hintStyle,
  6. Duration? hintFadeDuration,
  7. TextStyle? errorStyle,
  8. int? errorMaxLines,
  9. FloatingLabelBehavior? floatingLabelBehavior,
  10. FloatingLabelAlignment? floatingLabelAlignment,
  11. bool? isDense,
  12. EdgeInsetsGeometry? contentPadding,
  13. bool? isCollapsed,
  14. Color? iconColor,
  15. TextStyle? prefixStyle,
  16. Color? prefixIconColor,
  17. BoxConstraints? prefixIconConstraints,
  18. TextStyle? suffixStyle,
  19. Color? suffixIconColor,
  20. BoxConstraints? suffixIconConstraints,
  21. TextStyle? counterStyle,
  22. bool? filled,
  23. Color? fillColor,
  24. BorderSide? activeIndicatorBorder,
  25. BorderSide? outlineBorder,
  26. Color? focusColor,
  27. Color? hoverColor,
  28. InputBorder? errorBorder,
  29. InputBorder? focusedBorder,
  30. InputBorder? focusedErrorBorder,
  31. InputBorder? disabledBorder,
  32. InputBorder? enabledBorder,
  33. InputBorder? border,
  34. bool? alignLabelWithHint,
  35. BoxConstraints? constraints,
})

Creates a copy of this object but with the given fields replaced with the new values.

Implementation

InputDecorationTheme copyWith({
  TextStyle? labelStyle,
  TextStyle? floatingLabelStyle,
  TextStyle? helperStyle,
  int? helperMaxLines,
  TextStyle? hintStyle,
  Duration? hintFadeDuration,
  TextStyle? errorStyle,
  int? errorMaxLines,
  FloatingLabelBehavior? floatingLabelBehavior,
  FloatingLabelAlignment? floatingLabelAlignment,
  bool? isDense,
  EdgeInsetsGeometry? contentPadding,
  bool? isCollapsed,
  Color? iconColor,
  TextStyle? prefixStyle,
  Color? prefixIconColor,
  BoxConstraints? prefixIconConstraints,
  TextStyle? suffixStyle,
  Color? suffixIconColor,
  BoxConstraints? suffixIconConstraints,
  TextStyle? counterStyle,
  bool? filled,
  Color? fillColor,
  BorderSide? activeIndicatorBorder,
  BorderSide? outlineBorder,
  Color? focusColor,
  Color? hoverColor,
  InputBorder? errorBorder,
  InputBorder? focusedBorder,
  InputBorder? focusedErrorBorder,
  InputBorder? disabledBorder,
  InputBorder? enabledBorder,
  InputBorder? border,
  bool? alignLabelWithHint,
  BoxConstraints? constraints,
}) {
  return InputDecorationTheme(
    labelStyle: labelStyle ?? this.labelStyle,
    floatingLabelStyle: floatingLabelStyle ?? this.floatingLabelStyle,
    helperStyle: helperStyle ?? this.helperStyle,
    helperMaxLines: helperMaxLines ?? this.helperMaxLines,
    hintStyle: hintStyle ?? this.hintStyle,
    hintFadeDuration: hintFadeDuration ?? this.hintFadeDuration,
    errorStyle: errorStyle ?? this.errorStyle,
    errorMaxLines: errorMaxLines ?? this.errorMaxLines,
    floatingLabelBehavior: floatingLabelBehavior ?? this.floatingLabelBehavior,
    floatingLabelAlignment: floatingLabelAlignment ?? this.floatingLabelAlignment,
    isDense: isDense ?? this.isDense,
    contentPadding: contentPadding ?? this.contentPadding,
    iconColor: iconColor ?? this.iconColor,
    isCollapsed: isCollapsed ?? this.isCollapsed,
    prefixStyle: prefixStyle ?? this.prefixStyle,
    prefixIconColor: prefixIconColor ?? this.prefixIconColor,
    prefixIconConstraints: prefixIconConstraints ?? this.prefixIconConstraints,
    suffixStyle: suffixStyle ?? this.suffixStyle,
    suffixIconColor: suffixIconColor ?? this.suffixIconColor,
    suffixIconConstraints: suffixIconConstraints ?? this.suffixIconConstraints,
    counterStyle: counterStyle ?? this.counterStyle,
    filled: filled ?? this.filled,
    fillColor: fillColor ?? this.fillColor,
    activeIndicatorBorder: activeIndicatorBorder ?? this.activeIndicatorBorder,
    outlineBorder: outlineBorder ?? this.outlineBorder,
    focusColor: focusColor ?? this.focusColor,
    hoverColor: hoverColor ?? this.hoverColor,
    errorBorder: errorBorder ?? this.errorBorder,
    focusedBorder: focusedBorder ?? this.focusedBorder,
    focusedErrorBorder: focusedErrorBorder ?? this.focusedErrorBorder,
    disabledBorder: disabledBorder ?? this.disabledBorder,
    enabledBorder: enabledBorder ?? this.enabledBorder,
    border: border ?? this.border,
    alignLabelWithHint: alignLabelWithHint ?? this.alignLabelWithHint,
    constraints: constraints ?? this.constraints,
  );
}