visitTextSpan method
Walks this text span and its descendants in pre-order and calls visitor
for each span that has text.
Implementation
bool visitTextSpan(bool visitor(TextSpan span)) {
if (text != null) {
if (!visitor(this))
return false;
}
if (children != null) {
for (TextSpan child in children) {
if (!child.visitTextSpan(visitor))
return false;
}
}
return true;
}