TextSetting<T> class

A textfield setting

When tapped, this widget shows a dialog with a textbox.

Inheritance

Constructors

TextSetting({Key? key, required dynamic settingsKey, required dynamic title, dynamic defaultValue, dynamic subtitle, Widget? leading, TextInputType? keyboardType, bool enabled = true, bool? obscureText, String? obscuringCharacter, List<TextInputFormatter>? inputFormatters, FormFieldValidator<T>? validator, String okText = 'OK', String cancelText = 'Cancel', bool? autocorrect, SmartDashesType? smartDashesType, SmartQuotesType? smartQuotesType, bool? enableSuggestions, int? maxLines, int? minLines, bool? expands, int? maxLength, double? cursorHeight, Color? cursorColor, Brightness? keyboardAppearance, EdgeInsets? scrollPadding, bool? enableInteractiveSelection, TextSelectionControls? selectionControls, SettingChangedCallback<T>? onChanged})

Properties

autocorrect bool?
Inherited from TextFormField
final
cancelText String
The text for the 'cancel' action in the dialog
final
cursorColor Color?
Inherited from TextFormField
final
cursorHeight double?
Inherited from TextFormField
final
cursorWidth double
Inherited from TextFormField
final
defaultValue → T?
The default value that is used if no value is stored
finalinherited
enabled bool
Whether this setting is enabled or not
finalinherited
enableInteractiveSelection bool?
Inherited from TextFormField
final
enableSuggestions bool?
Inherited from TextFormField
final
expands bool?
Inherited from TextFormField
final
hashCode int
The hash code for this object.
no setterinherited
inputFormatters List<TextInputFormatter>?
A list of TextInputFormatter that can be used to restrict or allow certain characters
final
key Key?
Controls how one widget replaces another widget in the tree.
finalinherited
keyboardAppearance Brightness?
Inherited from TextFormField
final
keyboardType TextInputType?
The keyboard type to be used in the dialog
final
leading Widget?
The leading widget for the settings tile
finalinherited
maxLength int?
Inherited from TextFormField
final
maxLines int?
Inherited from TextFormField
final
minLines int?
Inherited from TextFormField
final
obscureText bool?
Whether or not to obscure the text
final
obscuringCharacter String?
the character used to obscure the text
final
okText String
The text for the 'confirm' action in the dialog
final
onChanged SettingChangedCallback<T>?
A callback that is triggered when the value changes
finalinherited
runtimeType Type
A representation of the runtime type of the object.
no setterinherited
scrollPadding EdgeInsets?
Inherited from TextFormField
final
selectionControls TextSelectionControls?
Inherited from TextFormField
final
settingsKey String?
The key used to store via shared_preferences
finalinherited
smartDashesType SmartDashesType?
Inherited from TextFormField
final
smartQuotesType SmartQuotesType?
Inherited from TextFormField
final
subtitle String?
The settings tile's subtitle
finalinherited
title String
The settings tile's title
finalinherited
validator FormFieldValidator<T>?
This callback is triggered for validation. Useful e.g. to make sure the user only entered numbers in a certain range
final

Methods

createElement() StatefulElement
Creates a StatefulElement to manage this widget's location in the tree.
inherited
createState() State<StatefulWidget>
Creates the mutable state for this widget at a given location in the tree.
override
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}) 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