@Override
    public String getText(final int offset, final int length) {
      return ReadAction
        .compute(() -> editor.getDocument().getText(new TextRange(offset, offset + length)));
    }
@Override
    public String getText(final int offset, final int length)