PasswordTextField constructor

const PasswordTextField({
  1. Key? key,
  2. IconData visibleIcon = Icons.visibility,
  3. IconData inVisibleIcon = Icons.visibility_off,
  4. bool initialObscurity = false,
  5. TextEditingController? controller,
  6. FocusNode? focusNode,
  7. UndoHistoryController? undoController,
  8. InputDecoration decoration = const InputDecoration(),
  9. TextInputType? keyboardType,
  10. TextInputAction? textInputAction,
  11. TextCapitalization textCapitalization = TextCapitalization.none,
  12. TextStyle? style,
  13. StrutStyle? strutStyle,
  14. TextAlign textAlign = TextAlign.start,
  15. TextAlignVertical? textAlignVertical,
  16. TextDirection? textDirection,
  17. bool readOnly = false,
  18. bool? showCursor,
  19. bool autofocus = false,
  20. String obscuringCharacter = '•',
  21. bool autocorrect = true,
  22. bool enableSuggestions = true,
  23. int? maxLines = 1,
  24. int? minLines,
  25. bool expands = false,
  26. int? maxLength,
  27. MaxLengthEnforcement? maxLengthEnforcement,
  28. ValueChanged<String>? onChanged,
  29. VoidCallback? onEditingComplete,
  30. ValueChanged<String>? onSubmitted,
  31. AppPrivateCommandCallback? onAppPrivateCommand,
  32. List<TextInputFormatter>? inputFormatters,
  33. bool? enabled,
  34. double cursorWidth = 2.0,
  35. double? cursorHeight,
  36. Radius? cursorRadius,
  37. bool? cursorOpacityAnimates,
  38. Color? cursorColor,
  39. BoxHeightStyle selectionHeightStyle = ui.BoxHeightStyle.tight,
  40. BoxWidthStyle selectionWidthStyle = ui.BoxWidthStyle.tight,
  41. Brightness? keyboardAppearance,
  42. EdgeInsets scrollPadding = const EdgeInsets.all(20.0),
  43. DragStartBehavior dragStartBehavior = DragStartBehavior.start,
  44. bool enableInteractiveSelection = true,
  45. TextSelectionControls? selectionControls,
  46. GestureTapCallback? onTap,
  47. TapRegionCallback? onTapOutside,
  48. MouseCursor? mouseCursor,
  49. InputCounterWidgetBuilder? buildCounter,
  50. ScrollController? scrollController,
  51. ScrollPhysics? scrollPhysics,
  52. Iterable<String>? autofillHints = const <String>[],
  53. ContentInsertionConfiguration? contentInsertionConfiguration,
  54. Clip clipBehavior = Clip.hardEdge,
  55. String? restorationId,
  56. bool scribbleEnabled = true,
  57. bool enableIMEPersonalizedLearning = true,
  58. EditableTextContextMenuBuilder? contextMenuBuilder,
  59. bool canRequestFocus = true,
  60. SpellCheckConfiguration? spellCheckConfiguration,
  61. TextMagnifierConfiguration? magnifierConfiguration,
})

Creates a Material Design text field that manages visible/inVisible icon.

Implementation

const PasswordTextField({
  super.key,
  this.visibleIcon = Icons.visibility,
  this.inVisibleIcon = Icons.visibility_off,
  this.initialObscurity = false,
  this.controller,
  this.focusNode,
  this.undoController,
  this.decoration = const InputDecoration(),
  this.keyboardType,
  this.textInputAction,
  this.textCapitalization = TextCapitalization.none,
  this.style,
  this.strutStyle,
  this.textAlign = TextAlign.start,
  this.textAlignVertical,
  this.textDirection,
  this.readOnly = false,
  this.showCursor,
  this.autofocus = false,
  this.obscuringCharacter = '•',
  this.autocorrect = true,
  this.enableSuggestions = true,
  this.maxLines = 1,
  this.minLines,
  this.expands = false,
  this.maxLength,
  this.maxLengthEnforcement,
  this.onChanged,
  this.onEditingComplete,
  this.onSubmitted,
  this.onAppPrivateCommand,
  this.inputFormatters,
  this.enabled,
  this.cursorWidth = 2.0,
  this.cursorHeight,
  this.cursorRadius,
  this.cursorOpacityAnimates,
  this.cursorColor,
  this.selectionHeightStyle = ui.BoxHeightStyle.tight,
  this.selectionWidthStyle = ui.BoxWidthStyle.tight,
  this.keyboardAppearance,
  this.scrollPadding = const EdgeInsets.all(20.0),
  this.dragStartBehavior = DragStartBehavior.start,
  this.enableInteractiveSelection = true,
  this.selectionControls,
  this.onTap,
  this.onTapOutside,
  this.mouseCursor,
  this.buildCounter,
  this.scrollController,
  this.scrollPhysics,
  this.autofillHints = const <String>[],
  this.contentInsertionConfiguration,
  this.clipBehavior = Clip.hardEdge,
  this.restorationId,
  this.scribbleEnabled = true,
  this.enableIMEPersonalizedLearning = true,
  this.contextMenuBuilder,
  this.canRequestFocus = true,
  this.spellCheckConfiguration,
  this.magnifierConfiguration,
});