OudsCodeText.rich constructor

const OudsCodeText.rich({
  1. Key? key,
  2. Color? color,
  3. required OudsAnnotatedText text,
  4. int? maxLines,
  5. TextAlign? textAlign,
  6. TextOverflow? overflow,
  7. bool? softWrap,
})

Creates an OudsCodeText whose content is composed of multiple spans, some of which can be colored independently of the others. Build text with buildOudsAnnotatedText to color part of the text, e.g. to highlight a word or phrase.

Implementation

const OudsCodeText.rich({
  super.key,
  this.color,
  required OudsAnnotatedText text,
  this.maxLines,
  this.textAlign,
  this.overflow,
  this.softWrap,
}) : text = '',
     _annotatedText = text;