copyWith method

InputOptions copyWith({
  1. TextEditingController? textController,
  2. TextStyle? textStyle,
  3. InputDecoration? decoration,
  4. int? maxLines,
  5. int? minLines,
  6. bool? sendOnEnter,
  7. bool? readOnly,
  8. bool? autocorrect,
  9. EdgeInsets? margin,
  10. BoxDecoration? containerDecoration,
  11. Color? containerBackgroundColor,
  12. EdgeInsets? padding,
  13. EdgeInsets? containerPadding,
  14. double? inputHeight,
  15. double? inputContainerHeight,
  16. BoxConstraints? inputContainerConstraints,
  17. InputContainerWidth? inputContainerWidth,
  18. bool? useOuterContainer,
  19. bool? useOuterMaterial,
  20. double? materialElevation,
  21. Color? materialColor,
  22. ShapeBorder? materialShape,
  23. EdgeInsets? materialPadding,
  24. bool? useScaffoldBackground,
  25. TextDirection? textDirection,
  26. double? positionedLeft,
  27. double? positionedRight,
  28. double? positionedBottom,
  29. double? positionedTop,
  30. double? blurStrength,
  31. bool? clipBehavior,
  32. Widget sendButtonBuilder(
    1. VoidCallback onSend
    )?,
  33. Color? sendButtonColor,
  34. Color? sendButtonDisableColor,
  35. IconData? sendButtonIcon,
  36. double? sendButtonIconSize,
  37. EdgeInsets? sendButtonPadding,
  38. TextInputType? keyboardType,
  39. TextCapitalization? textCapitalization,
  40. TextInputAction? textInputAction,
  41. List<TextInputFormatter>? inputFormatters,
  42. bool? enableSuggestions,
  43. bool? enableIMEPersonalizedLearning,
  44. Color? cursorColor,
  45. double? cursorHeight,
  46. double? cursorWidth,
  47. Radius? cursorRadius,
  48. bool? showCursor,
  49. VoidCallback? onEditingComplete,
  50. ValueChanged<String>? onSubmitted,
  51. ValueChanged<String>? onChanged,
  52. GestureTapCallback? onTap,
  53. bool? unfocusOnTapOutside,
  54. MouseCursor? mouseCursor,
  55. EditableTextContextMenuBuilder? contextMenuBuilder,
  56. UndoHistoryController? undoController,
  57. SpellCheckConfiguration? spellCheckConfiguration,
  58. TextMagnifierConfiguration? magnifierConfiguration,
  59. SmartDashesType? smartDashesType,
  60. SmartQuotesType? smartQuotesType,
  61. TextSelectionControls? selectionControls,
})

Creates a copy with the given fields replaced with new values.

Implementation

InputOptions copyWith({
  TextEditingController? textController,
  TextStyle? textStyle,
  InputDecoration? decoration,
  int? maxLines,
  int? minLines,
  bool? sendOnEnter,
  bool? readOnly,
  bool? autocorrect,
  EdgeInsets? margin,
  BoxDecoration? containerDecoration,
  Color? containerBackgroundColor,
  EdgeInsets? padding,
  EdgeInsets? containerPadding,
  double? inputHeight,
  double? inputContainerHeight,
  BoxConstraints? inputContainerConstraints,
  InputContainerWidth? inputContainerWidth,
  bool? useOuterContainer,
  bool? useOuterMaterial,
  double? materialElevation,
  Color? materialColor,
  ShapeBorder? materialShape,
  EdgeInsets? materialPadding,
  bool? useScaffoldBackground,
  TextDirection? textDirection,
  double? positionedLeft,
  double? positionedRight,
  double? positionedBottom,
  double? positionedTop,
  double? blurStrength,
  bool? clipBehavior,
  Widget Function(VoidCallback onSend)? sendButtonBuilder,
  Color? sendButtonColor,
  Color? sendButtonDisableColor,
  IconData? sendButtonIcon,
  double? sendButtonIconSize,
  EdgeInsets? sendButtonPadding,
  TextInputType? keyboardType,
  TextCapitalization? textCapitalization,
  TextInputAction? textInputAction,
  List<TextInputFormatter>? inputFormatters,
  bool? enableSuggestions,
  bool? enableIMEPersonalizedLearning,
  Color? cursorColor,
  double? cursorHeight,
  double? cursorWidth,
  Radius? cursorRadius,
  bool? showCursor,
  VoidCallback? onEditingComplete,
  ValueChanged<String>? onSubmitted,
  ValueChanged<String>? onChanged,
  GestureTapCallback? onTap,
  bool? unfocusOnTapOutside,
  MouseCursor? mouseCursor,
  EditableTextContextMenuBuilder? contextMenuBuilder,
  UndoHistoryController? undoController,
  SpellCheckConfiguration? spellCheckConfiguration,
  TextMagnifierConfiguration? magnifierConfiguration,
  SmartDashesType? smartDashesType,
  SmartQuotesType? smartQuotesType,
  TextSelectionControls? selectionControls,
}) {
  return InputOptions(
    textController: textController ?? this.textController,
    textStyle: textStyle ?? this.textStyle,
    decoration: decoration ?? this.decoration,
    maxLines: maxLines ?? this.maxLines,
    minLines: minLines ?? this.minLines,
    sendOnEnter: sendOnEnter ?? this.sendOnEnter,
    readOnly: readOnly ?? this.readOnly,
    autocorrect: autocorrect ?? this.autocorrect,
    margin: margin ?? this.margin,
    containerDecoration: containerDecoration ?? this.containerDecoration,
    containerBackgroundColor: containerBackgroundColor ?? this.containerBackgroundColor,
    padding: padding ?? this.padding,
    containerPadding: containerPadding ?? this.containerPadding,
    inputHeight: inputHeight ?? this.inputHeight,
    inputContainerHeight: inputContainerHeight ?? this.inputContainerHeight,
    inputContainerConstraints: inputContainerConstraints ?? this.inputContainerConstraints,
    inputContainerWidth: inputContainerWidth ?? this.inputContainerWidth,
    useOuterContainer: useOuterContainer ?? this.useOuterContainer,
    useOuterMaterial: useOuterMaterial ?? this.useOuterMaterial,
    materialElevation: materialElevation ?? this.materialElevation,
    materialColor: materialColor ?? this.materialColor,
    materialShape: materialShape ?? this.materialShape,
    materialPadding: materialPadding ?? this.materialPadding,
    useScaffoldBackground: useScaffoldBackground ?? this.useScaffoldBackground,
    inputTextDirection: textDirection ?? inputTextDirection,
    positionedLeft: positionedLeft ?? this.positionedLeft,
    positionedRight: positionedRight ?? this.positionedRight,
    positionedBottom: positionedBottom ?? this.positionedBottom,
    positionedTop: positionedTop ?? this.positionedTop,
    blurStrength: blurStrength ?? this.blurStrength,
    clipBehavior: clipBehavior ?? this.clipBehavior,
    sendButtonBuilder: sendButtonBuilder ?? this.sendButtonBuilder,
    sendButtonColor: sendButtonColor ?? this.sendButtonColor,
    sendButtonDisableColor: sendButtonDisableColor ?? this.sendButtonDisableColor,
    sendButtonIcon: sendButtonIcon ?? this.sendButtonIcon,
    sendButtonIconSize: sendButtonIconSize ?? this.sendButtonIconSize,
    sendButtonPadding: sendButtonPadding ?? this.sendButtonPadding,
    keyboardType: keyboardType ?? this.keyboardType,
    textCapitalization: textCapitalization ?? this.textCapitalization,
    textInputAction: textInputAction ?? this.textInputAction,
    textDirection: textDirection ?? this.textDirection,
    inputFormatters: inputFormatters ?? this.inputFormatters,
    enableSuggestions: enableSuggestions ?? this.enableSuggestions,
    enableIMEPersonalizedLearning:
        enableIMEPersonalizedLearning ?? this.enableIMEPersonalizedLearning,
    cursorColor: cursorColor ?? this.cursorColor,
    cursorHeight: cursorHeight ?? this.cursorHeight,
    cursorWidth: cursorWidth ?? this.cursorWidth,
    cursorRadius: cursorRadius ?? this.cursorRadius,
    showCursor: showCursor ?? this.showCursor,
    onEditingComplete: onEditingComplete ?? this.onEditingComplete,
    onSubmitted: onSubmitted ?? this.onSubmitted,
    onChanged: onChanged ?? this.onChanged,
    onTap: onTap ?? this.onTap,
    unfocusOnTapOutside: unfocusOnTapOutside ?? this.unfocusOnTapOutside,
    mouseCursor: mouseCursor ?? this.mouseCursor,
    contextMenuBuilder: contextMenuBuilder ?? this.contextMenuBuilder,
    undoController: undoController ?? this.undoController,
    spellCheckConfiguration: spellCheckConfiguration ?? this.spellCheckConfiguration,
    magnifierConfiguration: magnifierConfiguration ?? this.magnifierConfiguration,
    smartDashesType: smartDashesType ?? this.smartDashesType,
    smartQuotesType: smartQuotesType ?? this.smartQuotesType,
    selectionControls: selectionControls ?? this.selectionControls,
  );
}