Text.rich constructor

const Text.rich(InlineSpan textSpan, { Key key, TextStyle style, StrutStyle strutStyle, TextAlign textAlign, TextDirection textDirection, Locale locale, bool softWrap, TextOverflow overflow, double textScaleFactor, int maxLines, String semanticsLabel, TextWidthBasis textWidthBasis })

Creates a text widget with a InlineSpan.

The following subclasses of InlineSpan may be used to build rich text:

The textSpan parameter must not be null.

See RichText which provides a lower-level way to draw text.

Implementation

const Text.rich(
  this.textSpan, {
  Key key,
  this.style,
  this.strutStyle,
  this.textAlign,
  this.textDirection,
  this.locale,
  this.softWrap,
  this.overflow,
  this.textScaleFactor,
  this.maxLines,
  this.semanticsLabel,
  this.textWidthBasis,
}) : assert(
       textSpan != null,
       'A non-null TextSpan must be provided to a Text.rich widget.',
     ),
     data = null,
     super(key: key);