clearScrollback method

void clearScrollback()

Remove all lines above the top of the viewport.

Implementation

void clearScrollback() {
  if (height <= viewHeight) {
    return;
  }

  lines.trimStart(scrollBack);
}