code: public void removeTrailingEmptyLines()
      {
          Line line = this.lineTail;
          while (line != null && line.isEmpty)
          {
              this.removeLine(line);
              line = this.lineTail;
          }
      }
docs: Removes trailing empty lines.