@Override
      public void caretPositionChanged(@NotNull CaretEvent e) {
        if (myState.isStickySelection()) {
          int selectionStart = Math.min(myStickySelectionStart, getDocument().getTextLength());
          mySelectionModel.setSelection(selectionStart, myCaretModel.getVisualPosition(), myCaretModel.getOffset());
        }
      }
@Override
      public void caretPositionChanged(@NotNull CaretEvent e)