void () { Registry.get("editor.block.caret.selection.vim-like").setValue(true, getTestRootDisposable()); initText("abc\ndef"); EditorTestUtil.setEditorVisibleSize(getEditor(), 1000, 1000); // enable drag testing getEditor().getSettings().setBlockCursor(true); int line1Y = getEditor().getLineHeight() / 2; int line2Y = getEditor().getLineHeight() * 3 / 2; mouse().pressAtXY(3 * TEST_CHAR_WIDTH + 1, line1Y); checkResultByText("abc<caret>\ndef"); mouse().dragToXY(3 * TEST_CHAR_WIDTH + 1, line1Y); checkResultByText("abc<caret>\ndef"); mouse().dragToXY(2 * TEST_CHAR_WIDTH + 1, line1Y); checkResultByText("ab<selection><caret>c\n</selection>def"); mouse().dragToXY(TEST_CHAR_WIDTH + 1, line1Y); checkResultByText("a<selection><caret>bc\n</selection>def"); mouse().dragToXY(2 * TEST_CHAR_WIDTH + 1, line1Y); checkResultByText("ab<selection><caret>c\n</selection>def"); mouse().dragToXY(3 * TEST_CHAR_WIDTH + 1, line1Y); checkResultByText("abc<selection><caret>\n</selection>def"); mouse().dragToXY(3 * TEST_CHAR_WIDTH + 1, line2Y); checkResultByText("abc<selection>\ndef<caret></selection>"); mouse().dragToXY(1, line2Y); checkResultByText("abc<selection>\n<caret>d</selection>ef"); mouse().dragToXY(1, line1Y); checkResultByText("<selection><caret>abc\n</selection>def"); }