RoundedBackgroundText.rich constructor

const RoundedBackgroundText.rich({
  1. Key? key,
  2. required InlineSpan text,
  3. TextDirection? textDirection,
  4. Color? backgroundColor,
  5. TextAlign? textAlign,
  6. TextWidthBasis? textWidthBasis,
  7. String? ellipsis,
  8. Locale? locale,
  9. StrutStyle? strutStyle,
  10. TextScaler textScaler = TextScaler.noScaling,
  11. int? maxLines,
  12. TextHeightBehavior? textHeightBehavior,
  13. double innerRadius = kDefaultInnerRadius,
  14. double outerRadius = kDefaultOuterRadius,
})

Creates a rounded background text based on an InlineSpan, that can have multiple styles

Implementation

const RoundedBackgroundText.rich({
  super.key,
  required this.text,
  this.textDirection,
  this.backgroundColor,
  this.textAlign,
  this.textWidthBasis,
  this.ellipsis,
  this.locale,
  this.strutStyle,
  this.textScaler = TextScaler.noScaling,
  this.maxLines,
  this.textHeightBehavior,
  this.innerRadius = kDefaultInnerRadius,
  this.outerRadius = kDefaultOuterRadius,
})  : assert(innerRadius >= 0.0 && innerRadius <= 20.0),
      assert(outerRadius >= 0.0 && outerRadius <= 20.0);