TextOption constructor
const
TextOption({
- List<
String> fontFamilies = const ['Roboto', 'Arial', 'Times New Roman', 'Courier', 'Georgia', 'Verdana', 'Helvetica'], - List<
Color> textColors = const [Colors.white, Colors.black, Colors.red, Colors.blue, Colors.green, Colors.yellow, Colors.purple, Colors.orange, Colors.pink, Colors.teal, Colors.indigo, Colors.cyan], - List<
Gradient> textGradients = const [LinearGradient(colors: [Colors.purple, Colors.blue], begin: Alignment.topLeft, end: Alignment.bottomRight), LinearGradient(colors: [Colors.orange, Colors.pink], begin: Alignment.topLeft, end: Alignment.bottomRight), LinearGradient(colors: [Colors.green, Colors.teal], begin: Alignment.topLeft, end: Alignment.bottomRight), LinearGradient(colors: [Colors.red, Colors.yellow], begin: Alignment.topLeft, end: Alignment.bottomRight), LinearGradient(colors: [Colors.indigo, Colors.cyan], begin: Alignment.topCenter, end: Alignment.bottomCenter)], - List<
Gradient> backgroundGradients = const [LinearGradient(colors: [Colors.black54, Colors.transparent], begin: Alignment.centerLeft, end: Alignment.centerRight), LinearGradient(colors: [Colors.purple, Colors.blue], begin: Alignment.topLeft, end: Alignment.bottomRight), LinearGradient(colors: [Colors.orange, Colors.pink], begin: Alignment.topLeft, end: Alignment.bottomRight), RadialGradient(colors: [Colors.yellow, Colors.red], center: Alignment.center, radius: 0.8), LinearGradient(colors: [Colors.green, Colors.teal], begin: Alignment.topLeft, end: Alignment.bottomRight)], - List<
TextAnimation> animations = const [TextAnimation.fade, TextAnimation.slide, TextAnimation.bounce, TextAnimation.rotate, TextAnimation.scale, TextAnimation.pulse], - bool enableFontFamily = true,
- bool enableTextGradient = true,
- bool enableBackgroundGradient = true,
- bool enableAnimations = true,
Implementation
const TextOption({
this.fontFamilies = const [
'Roboto',
'Arial',
'Times New Roman',
'Courier',
'Georgia',
'Verdana',
'Helvetica',
],
this.textColors = const [
Colors.white,
Colors.black,
Colors.red,
Colors.blue,
Colors.green,
Colors.yellow,
Colors.purple,
Colors.orange,
Colors.pink,
Colors.teal,
Colors.indigo,
Colors.cyan,
],
this.textGradients = const [
LinearGradient(
colors: [Colors.purple, Colors.blue],
begin: Alignment.topLeft,
end: Alignment.bottomRight,
),
LinearGradient(
colors: [Colors.orange, Colors.pink],
begin: Alignment.topLeft,
end: Alignment.bottomRight,
),
LinearGradient(
colors: [Colors.green, Colors.teal],
begin: Alignment.topLeft,
end: Alignment.bottomRight,
),
LinearGradient(
colors: [Colors.red, Colors.yellow],
begin: Alignment.topLeft,
end: Alignment.bottomRight,
),
LinearGradient(
colors: [Colors.indigo, Colors.cyan],
begin: Alignment.topCenter,
end: Alignment.bottomCenter,
),
],
this.backgroundGradients = const [
LinearGradient(
colors: [Colors.black54, Colors.transparent],
begin: Alignment.centerLeft,
end: Alignment.centerRight,
),
LinearGradient(
colors: [Colors.purple, Colors.blue],
begin: Alignment.topLeft,
end: Alignment.bottomRight,
),
LinearGradient(
colors: [Colors.orange, Colors.pink],
begin: Alignment.topLeft,
end: Alignment.bottomRight,
),
RadialGradient(
colors: [Colors.yellow, Colors.red],
center: Alignment.center,
radius: 0.8,
),
LinearGradient(
colors: [Colors.green, Colors.teal],
begin: Alignment.topLeft,
end: Alignment.bottomRight,
),
],
this.animations = const [
TextAnimation.fade,
TextAnimation.slide,
TextAnimation.bounce,
TextAnimation.rotate,
TextAnimation.scale,
TextAnimation.pulse,
],
this.enableFontFamily = true,
this.enableTextGradient = true,
this.enableBackgroundGradient = true,
this.enableAnimations = true,
});