CustomTextInput class
A customizable text input widget with various options
- Inheritance
-
- Object
- DiagnosticableTree
- Widget
- StatelessWidget
- CustomTextInput
Constructors
-
CustomTextInput({Key? key, required TextEditingController controller, String? labelText, String? hintText, String? helperText, String? errorText, IconData? prefixIcon, IconData? suffixIcon, VoidCallback? onSuffixIconPressed, TextInputType keyboardType = TextInputType.text, bool obscureText = false, bool enabled = true, List<
TextInputFormatter> ? inputFormatters, int? maxLength, int? maxLines = 1, int? minLines, String? counterText, AutovalidateMode? autovalidateMode, String? validator(String?)?, void onChanged(String)?, void onSubmitted(String)?, double borderRadius = 8.0, EdgeInsetsGeometry contentPadding = const EdgeInsets.symmetric(horizontal: 16, vertical: 16), Color? fillColor, Color? borderColor, FocusNode? focusNode, bool autocorrect = false, TextCapitalization textCapitalization = TextCapitalization.none, TextInputAction? textInputAction, TextStyle? textStyle, String fontFamily = 'Roboto'}) -
const
Properties
- autocorrect → bool
-
Optional autocorrect setting
final
- autovalidateMode → AutovalidateMode?
-
Optional auto-validation mode
final
- borderColor → Color?
-
Optional border color
final
- borderRadius → double
-
Optional border radius
final
- contentPadding → EdgeInsetsGeometry
-
Optional padding
final
- controller → TextEditingController
-
Controller for the text input
final
- counterText → String?
-
Optional text to show in a counter below the input
final
- enabled → bool
-
Whether the input is enabled
final
- errorText → String?
-
Optional error text displayed below the input
final
- fillColor → Color?
-
Optional fill color
final
- focusNode → FocusNode?
-
Optional focus node
final
- fontFamily → String
-
Optional text font family
final
- hashCode → int
-
The hash code for this object.
no setterinherited
- helperText → String?
-
Optional helper text displayed below the input
final
- hintText → String?
-
Optional hint text
final
-
inputFormatters
→ List<
TextInputFormatter> ? -
Optional input formatters
final
- key → Key?
-
Controls how one widget replaces another widget in the tree.
finalinherited
- keyboardType → TextInputType
-
Optional keyboard type
final
- labelText → String?
-
Optional label text
final
- maxLength → int?
-
Maximum number of characters allowed
final
- maxLines → int?
-
Maximum number of lines
final
- minLines → int?
-
Minimum number of lines
final
- obscureText → bool
-
Whether the input should be obscured (for passwords)
final
- onChanged → void Function(String)?
-
Optional function to call when the text changes
final
- onSubmitted → void Function(String)?
-
Optional function to call when the user submits the input
final
- onSuffixIconPressed → VoidCallback?
-
Optional function to call when suffix icon is pressed
final
- prefixIcon → IconData?
-
Optional prefix icon
final
- runtimeType → Type
-
A representation of the runtime type of the object.
no setterinherited
- suffixIcon → IconData?
-
Optional suffix icon
final
- textCapitalization → TextCapitalization
-
Optional text capitalization setting
final
- textInputAction → TextInputAction?
-
Optional text input action
final
- textStyle → TextStyle?
-
Optional text style
final
- validator → String? Function(String?)?
-
Optional validator function
final
Methods
-
build(
BuildContext context) → Widget -
Describes the part of the user interface represented by this widget.
override
-
createElement(
) → StatelessElement -
Creates a StatelessElement to manage this widget's location in the tree.
inherited
-
debugDescribeChildren(
) → List< DiagnosticsNode> -
Returns a list of DiagnosticsNode objects describing this node's
children.
inherited
-
debugFillProperties(
DiagnosticPropertiesBuilder properties) → void -
Add additional properties associated with the node.
inherited
-
noSuchMethod(
Invocation invocation) → dynamic -
Invoked when a nonexistent method or property is accessed.
inherited
-
toDiagnosticsNode(
{String? name, DiagnosticsTreeStyle? style}) → DiagnosticsNode -
Returns a debug representation of the object that is used by debugging
tools and by DiagnosticsNode.toStringDeep.
inherited
-
toString(
{DiagnosticLevel minLevel = DiagnosticLevel.info}) → String -
A string representation of this object.
inherited
-
toStringDeep(
{String prefixLineOne = '', String? prefixOtherLines, DiagnosticLevel minLevel = DiagnosticLevel.debug, int wrapWidth = 65}) → String -
Returns a string representation of this node and its descendants.
inherited
-
toStringShallow(
{String joiner = ', ', DiagnosticLevel minLevel = DiagnosticLevel.debug}) → String -
Returns a one-line detailed description of the object.
inherited
-
toStringShort(
) → String -
A short, textual description of this widget.
inherited
Operators
-
operator ==(
Object other) → bool -
The equality operator.
inherited