clear method
void
clear()
Clears the viewport and scrollback buffer. Then fill with empty lines.
Writes ED 2 and ED 3; the cursor does not move. Anchors created in this buffer are no longer attached afterwards, as in xterm.
Implementation
void clear() {
final terminal = _active;
terminal.eraseDisplay();
terminal.eraseScrollbackOnly();
_lines.detachAnchors();
}