ChipInput<T> constructor
const
ChipInput<T> ({
- Key? key,
- Object groupId = EditableText,
- ChipEditingController<
T> ? controller, - FocusNode? focusNode,
- BoxDecoration? decoration,
- EdgeInsetsGeometry? padding,
- Widget? placeholder,
- CrossAxisAlignment crossAxisAlignment = CrossAxisAlignment.center,
- String? clearButtonSemanticLabel,
- TextInputType? keyboardType,
- TextInputAction? textInputAction,
- TextCapitalization textCapitalization = TextCapitalization.none,
- TextStyle? style,
- StrutStyle? strutStyle,
- TextAlign textAlign = TextAlign.start,
- TextAlignVertical? textAlignVertical,
- TextDirection? textDirection,
- bool readOnly = false,
- bool? showCursor,
- bool autofocus = false,
- String obscuringCharacter = '•',
- bool obscureText = false,
- bool autocorrect = true,
- SmartDashesType smartDashesType = SmartDashesType.enabled,
- SmartQuotesType smartQuotesType = SmartQuotesType.enabled,
- bool enableSuggestions = true,
- int? maxLines = 1,
- int? minLines,
- bool expands = false,
- int? maxLength,
- MaxLengthEnforcement? maxLengthEnforcement,
- ValueChanged<
String> ? onChanged, - VoidCallback? onEditingComplete,
- ValueChanged<
String> ? onSubmitted, - TapRegionCallback? onTapOutside,
- TapRegionCallback? onTapUpOutside,
- List<
TextInputFormatter> ? inputFormatters, - bool enabled = true,
- double cursorWidth = 2.0,
- double? cursorHeight,
- Radius cursorRadius = const Radius.circular(2.0),
- bool cursorOpacityAnimates = true,
- Color? cursorColor,
- BoxHeightStyle selectionHeightStyle = ui.BoxHeightStyle.tight,
- BoxWidthStyle selectionWidthStyle = ui.BoxWidthStyle.tight,
- Brightness? keyboardAppearance,
- EdgeInsets scrollPadding = const EdgeInsets.all(20.0),
- bool enableInteractiveSelection = true,
- TextSelectionControls? selectionControls,
- DragStartBehavior dragStartBehavior = DragStartBehavior.start,
- ScrollController? scrollController,
- ScrollPhysics? scrollPhysics,
- GestureTapCallback? onTap,
- Iterable<
String> ? autofillHints = const [], - Clip clipBehavior = Clip.hardEdge,
- String? restorationId,
- bool stylusHandwritingEnabled = EditableText.defaultStylusHandwritingEnabled,
- bool enableIMEPersonalizedLearning = true,
- ContentInsertionConfiguration? contentInsertionConfiguration,
- EditableTextContextMenuBuilder? contextMenuBuilder,
- String? initialValue,
- String? hintText,
- Border? border,
- BorderRadiusGeometry? borderRadius,
- bool? filled,
- WidgetStatesController? statesController,
- TextMagnifierConfiguration? magnifierConfiguration,
- SpellCheckConfiguration? spellCheckConfiguration,
- UndoHistoryController? undoController,
- List<
InputFeature> features = const [], - List<
TextInputFormatter> ? submitFormatters = const [], - bool skipInputFeatureFocusTraversal = false,
- required ChipWidgetBuilder<
T> chipBuilder, - required ChipSubmissionCallback<
T> onChipSubmitted, - bool autoInsertSuggestion = true,
- ValueChanged<
List< ? onChipsChanged,T> > - bool? useChips,
- List<
T> ? initialChips, - ClipboardHandler<
T> ? clipboardHandler,
Creates a chip input widget.
Implementation
const ChipInput({
super.key,
super.groupId,
ChipEditingController<T>? super.controller,
super.focusNode,
super.decoration,
super.padding,
super.placeholder,
super.crossAxisAlignment,
super.clearButtonSemanticLabel,
super.keyboardType,
super.textInputAction,
super.textCapitalization,
super.style,
super.strutStyle,
super.textAlign,
super.textAlignVertical,
super.textDirection,
super.readOnly,
super.showCursor,
super.autofocus,
super.obscuringCharacter,
super.obscureText,
super.autocorrect,
super.smartDashesType,
super.smartQuotesType,
super.enableSuggestions,
super.maxLines,
super.minLines,
super.expands,
super.maxLength,
super.maxLengthEnforcement,
super.onChanged,
super.onEditingComplete,
super.onSubmitted,
super.onTapOutside,
super.onTapUpOutside,
super.inputFormatters,
super.enabled,
super.cursorWidth,
super.cursorHeight,
super.cursorRadius,
super.cursorOpacityAnimates,
super.cursorColor,
super.selectionHeightStyle,
super.selectionWidthStyle,
super.keyboardAppearance,
super.scrollPadding,
super.enableInteractiveSelection,
super.selectionControls,
super.dragStartBehavior,
super.scrollController,
super.scrollPhysics,
super.onTap,
super.autofillHints,
super.clipBehavior,
super.restorationId,
super.stylusHandwritingEnabled,
super.enableIMEPersonalizedLearning,
super.contentInsertionConfiguration,
super.contextMenuBuilder,
super.initialValue,
super.hintText,
super.border,
super.borderRadius,
super.filled,
super.statesController,
super.magnifierConfiguration,
super.spellCheckConfiguration,
super.undoController,
super.features,
super.submitFormatters,
super.skipInputFeatureFocusTraversal,
required this.chipBuilder,
required this.onChipSubmitted,
this.autoInsertSuggestion = true,
this.onChipsChanged,
this.useChips,
this.initialChips,
this.clipboardHandler,
});