clear method
void
clear()
Resets all cells in the buffer to transparent empty cells.
Implementation
void clear() {
Tracer.record(_traceClearId, Phase.begin);
try {
for (var i = 0; i < cells.length; i++) {
final cell = cells[i];
if (cell.char != ' ' || cell.style != Style.transparent) {
cell.char = ' ';
cell.style = Style.transparent;
}
}
} finally {
Tracer.record(_traceClearId, Phase.end);
}
}