TextEditorStyle class
The TextEditorStyle
class defines the style for the text editor in the
image editor.
It includes properties such as colors for the app bar, background, text
input, and more.
Usage:
TextEditorStyle TextEditorStyle = TextEditorStyle(
appBarBackgroundColor: Colors.black,
appBarForegroundColor: Colors.white,
background: Colors.grey.withOpacity(0.6),
inputHintColor: Colors.grey,
inputCursorColor: Colors.blue,
);
Properties:
-
appBarBackgroundColor
: Background color of the app bar in the text editor. -
appBarForegroundColor
: Foreground color (text and icons) of the app bar. -
background
: Background color of the text editor. -
inputHintColor
: Color of input hints in the text editor. -
inputCursorColor
: Color of the input cursor in the text editor.
Example Usage:
TextEditorStyle TextEditorStyle = TextEditorStyle(
appBarBackgroundColor: Colors.black,
appBarForegroundColor: Colors.white,
background: Colors.grey.withOpacity(0.6),
inputHintColor: Colors.grey,
inputCursorColor: Colors.blue,
);
Color appBarBackgroundColor = TextEditorStyle.appBarBackgroundColor;
Color background = TextEditorStyle.background;
// Access other style properties...
Constructors
- TextEditorStyle({TextStyle? fontSizeBottomSheetTitle, EdgeInsets textFieldMargin = const EdgeInsets.only(bottom: kBottomNavigationBarHeight), Color appBarBackground = kImageEditorAppBarBackground, Color appBarColor = kImageEditorAppBarColor, Color bottomBarBackground = kImageEditorBottomBarBackground, Color background = const Color(0x9B000000), MainAxisAlignment bottomBarMainAxisAlignment = MainAxisAlignment.spaceEvenly, Color inputHintColor = const Color(0xFFBDBDBD), Color inputCursorColor = kImageEditorPrimaryColor, Color fontScaleBottomSheetBackground = const Color(0xFF252728)})
-
Creates an instance of the
TextEditorStyle
class with the specified style properties.const
Properties
- appBarBackground → Color
-
Background color of the app bar in the text editor.
final
- appBarColor → Color
-
Foreground color (text and icons) of the app bar.
final
- background → Color
-
Background color of the text editor.
final
- bottomBarBackground → Color
-
Background color of the bottom bar in the text editor.
final
- bottomBarMainAxisAlignment → MainAxisAlignment
-
How the children should be placed along the main axis.
final
- fontScaleBottomSheetBackground → Color
-
Background color for the font scale bottom sheet.
final
- fontSizeBottomSheetTitle → TextStyle?
-
Title of the bottom sheet used to select the font-size.
final
- hashCode → int
-
The hash code for this object.
no setterinherited
- inputCursorColor → Color
-
Color of the input cursor in the text editor.
final
- inputHintColor → Color
-
Color of input hints in the text editor.
final
- runtimeType → Type
-
A representation of the runtime type of the object.
no setterinherited
- textFieldMargin → EdgeInsets
-
Margin value around the textField.
final
Methods
-
copyWith(
{Color? appBarBackground, Color? appBarColor, Color? bottomBarBackground, Color? background, Color? inputHintColor, Color? inputCursorColor, Color? fontScaleBottomSheetBackground, MainAxisAlignment? bottomBarMainAxisAlignment, EdgeInsets? textFieldMargin, TextStyle? fontSizeBottomSheetTitle}) → TextEditorStyle -
Creates a copy of this
TextEditorStyle
object with the given fields replaced with new values. -
noSuchMethod(
Invocation invocation) → dynamic -
Invoked when a nonexistent method or property is accessed.
inherited
-
toString(
) → String -
A string representation of this object.
inherited
Operators
-
operator ==(
Object other) → bool -
The equality operator.
inherited