private void popUntilTopBlockStartsNewLine() {
    popUntilTopBlockStartOffsetGreaterOrEqual(myCurrentLineStartOffset);
    if (myStack.isEmpty()) return;

    Block block = myStack.peek();
    while (block != null && !isStartingNewLine(block)) {
      checkCancelled();
      myCurrentDocumentLine++;
      if (myCurrentDocumentLine >= myTotalLines) {
        myStack.clear();
        break;
      }
      myCurrentLineStartOffset = myDocument.getLineStartOffset(myCurrentDocumentLine);
      popUntilTopBlockStartOffsetGreaterOrEqual(myCurrentLineStartOffset);
      block = myStack.isEmpty() ? null : myStack.peek();
    }
  }
private void popUntilTopBlockStartsNewLine()