copyWith method

CupertinoTextFieldConfiguration copyWith({
  1. TextEditingController? controller,
  2. FocusNode? focusNode,
  3. BoxDecoration? decoration,
  4. EdgeInsetsGeometry? padding,
  5. String? placeholder,
  6. Widget? prefix,
  7. OverlayVisibilityMode? prefixMode,
  8. Widget? suffix,
  9. OverlayVisibilityMode? suffixMode,
  10. OverlayVisibilityMode? clearButtonMode,
  11. TextInputType? keyboardType,
  12. TextInputAction? textInputAction,
  13. TextCapitalization? textCapitalization,
  14. TextStyle? style,
  15. TextAlign? textAlign,
  16. bool? autofocus,
  17. bool? obscureText,
  18. bool? autocorrect,
  19. int? maxLines,
  20. int? minLines,
  21. int? maxLength,
  22. MaxLengthEnforcement? maxLengthEnforcement,
  23. ValueChanged<String>? onChanged,
  24. VoidCallback? onEditingComplete,
  25. GestureTapCallback? onTap,
  26. ValueChanged<String>? onSubmitted,
  27. List<TextInputFormatter>? inputFormatters,
  28. bool? enabled,
  29. bool? enableSuggestions,
  30. double? cursorWidth,
  31. Radius? cursorRadius,
  32. Color? cursorColor,
  33. Brightness? keyboardAppearance,
  34. EdgeInsets? scrollPadding,
  35. bool? enableInteractiveSelection,
})

Copies the CupertinoTextFieldConfiguration and only changes the specified properties

Implementation

CupertinoTextFieldConfiguration copyWith({
  TextEditingController? controller,
  FocusNode? focusNode,
  BoxDecoration? decoration,
  EdgeInsetsGeometry? padding,
  String? placeholder,
  Widget? prefix,
  OverlayVisibilityMode? prefixMode,
  Widget? suffix,
  OverlayVisibilityMode? suffixMode,
  OverlayVisibilityMode? clearButtonMode,
  TextInputType? keyboardType,
  TextInputAction? textInputAction,
  TextCapitalization? textCapitalization,
  TextStyle? style,
  TextAlign? textAlign,
  bool? autofocus,
  bool? obscureText,
  bool? autocorrect,
  int? maxLines,
  int? minLines,
  int? maxLength,
  MaxLengthEnforcement? maxLengthEnforcement,
  ValueChanged<String>? onChanged,
  VoidCallback? onEditingComplete,
  GestureTapCallback? onTap,
  ValueChanged<String>? onSubmitted,
  List<TextInputFormatter>? inputFormatters,
  bool? enabled,
  bool? enableSuggestions,
  double? cursorWidth,
  Radius? cursorRadius,
  Color? cursorColor,
  Brightness? keyboardAppearance,
  EdgeInsets? scrollPadding,
  bool? enableInteractiveSelection,
}) {
  return CupertinoTextFieldConfiguration(
    controller: controller ?? this.controller,
    focusNode: focusNode ?? this.focusNode,
    decoration: decoration ?? this.decoration,
    padding: padding ?? this.padding,
    placeholder: placeholder ?? this.placeholder,
    prefix: prefix ?? this.prefix,
    prefixMode: prefixMode ?? this.prefixMode,
    suffix: suffix ?? this.suffix,
    suffixMode: suffixMode ?? this.suffixMode,
    clearButtonMode: clearButtonMode ?? this.clearButtonMode,
    keyboardType: keyboardType ?? this.keyboardType,
    textInputAction: textInputAction ?? this.textInputAction,
    textCapitalization: textCapitalization ?? this.textCapitalization,
    style: style ?? this.style,
    textAlign: textAlign ?? this.textAlign,
    autofocus: autofocus ?? this.autofocus,
    obscureText: obscureText ?? this.obscureText,
    autocorrect: autocorrect ?? this.autocorrect,
    maxLines: maxLines ?? this.maxLines,
    minLines: minLines ?? this.minLines,
    maxLength: maxLength ?? this.maxLength,
    maxLengthEnforcement: maxLengthEnforcement ?? this.maxLengthEnforcement,
    onChanged: onChanged ?? this.onChanged,
    onEditingComplete: onEditingComplete ?? this.onEditingComplete,
    onTap: onTap ?? this.onTap,
    onSubmitted: onSubmitted ?? this.onSubmitted,
    inputFormatters: inputFormatters ?? this.inputFormatters,
    enabled: enabled ?? this.enabled,
    enableSuggestions: enableSuggestions ?? this.enableSuggestions,
    cursorWidth: cursorWidth ?? this.cursorWidth,
    cursorRadius: cursorRadius ?? this.cursorRadius,
    cursorColor: cursorColor ?? this.cursorColor,
    keyboardAppearance: keyboardAppearance ?? this.keyboardAppearance,
    scrollPadding: scrollPadding ?? this.scrollPadding,
    enableInteractiveSelection:
        enableInteractiveSelection ?? this.enableInteractiveSelection,
  );
}