addPart method

void addPart(
  1. String label, {
  2. TextDirection? textDirection,
})

Adds a text part.

If textDirection is specified, it will be used for this specific part. Empty parts are ignored.

Implementation

void addPart(String label, {TextDirection? textDirection}) {
  if (label.isNotEmpty) {
    _parts.add((label, textDirection));
  }
}