NomoText constructor
const
NomoText(
- String text, {
- Key? key,
- TextStyle? style,
- TextAlign? textAlign,
- TextDirection? textDirection,
- Color? color,
- FontWeight? fontWeight,
- TextOverflow? overflow,
- int? maxLines,
- bool? fitHeight,
- List<
double> ? fontSizes, - double decreaseBy = 1,
- double minFontSize = 6,
- double? opacity,
- bool translate = true,
- double? fontSize,
- bool fit = false,
- bool useInheritedTheme = false,
- String textShortener()?,
Implementation
const NomoText(
this.text, {
super.key,
this.style,
this.textAlign,
this.textDirection,
this.color,
this.fontWeight,
this.overflow,
this.maxLines,
this.fitHeight,
this.fontSizes,
this.decreaseBy = 1,
this.minFontSize = 6,
this.opacity,
this.translate = true,
this.fontSize,
this.fit = false,
this.useInheritedTheme = false,
this.textShortener,
}) : assert(
fontSizes == null || fontSizes.length > 0,
'fontSizes must be a list of at least one value',
),
assert(
(fitHeight != null && fontSizes == null && maxLines == null) ||
fitHeight == null,
'Cant use FontSizes || maxLines with fitHeight',
);