Unnamed: 0
int64
0
305k
body
stringlengths
7
52.9k
name
stringlengths
1
185
271,900
void () { initText("text"); addBlockInlay(0, true, 10 * TEST_CHAR_WIDTH); EditorTestUtil.setEditorVisibleSize(getEditor(), 100, 100); mouse().pressAtXY(2 * TEST_CHAR_WIDTH, 0).dragToXY(4 * TEST_CHAR_WIDTH, 0).release(); checkResultByText("<caret>text"); }
testDragInBlockInlayDoesNotCreateSelection
271,901
void () { initText("text"); addBlockInlay(0, true); EditorTestUtil.setEditorVisibleSize(getEditor(), 100, 100); mouse().pressAtXY(2 * TEST_CHAR_WIDTH, (int)(getEditor().getLineHeight() * 1.5)).dragToXY(-1, -1).release(); checkResultByText("<selection><caret>te</selection>xt"); }
testDragBeyondEditorTopWithBlockInlay
271,902
void () { initText("<caret>abc"); addCollapsedFoldRegion(1, 2, ""); right(); Caret caret = getEditor().getCaretModel().getPrimaryCaret(); assertEquals(2, caret.getOffset()); assertEquals(new LogicalPosition(0, 2), caret.getLogicalPosition()); assertEquals(new VisualPosition(0, 1), caret.getVisualPosition()); right(); a...
testCaretMovementAtFoldRegionWithEmptyPlaceholder
271,903
void () { initText("abc<caret>"); addBlockInlay(0, true, 10); EditorTestUtil.setEditorVisibleSize(getEditor(), 100, 100); mouse().pressAtXY(0, 0).dragToXY(0, getEditor().getLineHeight()).release(); checkResultByText("abc<caret>"); }
testDragStartingAtBlockInlay
271,904
void () { boolean savedOption = EditorSettingsExternalizable.getInstance().isCamelWords(); try { EditorSettingsExternalizable.getInstance().setCamelWords(true); initText("AbcDefGhi"); EditorTestUtil.setEditorVisibleSize(getEditor(), 100, 100); getEditor().getSettings().setMouseClickSelectionHonorsCamelWords(false); mou...
testMouseDraggingWithCamelHumpsDisabledForMouse
271,905
void () { initText(""); EditorColorsScheme colorsScheme = getEditor().getColorsScheme(); FontPreferencesImpl preferences = new FontPreferencesImpl(); preferences.register("CustomFont", 32); preferences.setUseLigatures(true); colorsScheme.setFontPreferences(preferences); FontPreferences p = colorsScheme.getFontPreferenc...
testSettingFontPreferences
271,906
void () { initText("Some long line of text"); configureSoftWraps(15); // emulate adding editor to a wide component SoftWrapApplianceManager.VisibleAreaWidthProvider widthProvider = ((SoftWrapModelImpl)getEditor().getSoftWrapModel()).getApplianceManager().getWidthProvider(); ((EditorTestUtil.TestWidthProvider)widthProvi...
testDocumentChangeAfterWidthChange
271,907
void () { initText("<selection>text<caret></selection>"); addBlockInlay(0, true, 100); mouse().clickAtXY(50, getEditor().getLineHeight() / 2); checkResultByText("<selection>text<caret></selection>"); }
testClickOnBlockInlayDoesNotRemoveSelection
271,908
void () { initText("((some (text)))"); EditorTestUtil.setEditorVisibleSize(getEditor(), 100, 100); mouse().doubleClickNoReleaseAt(0, 4).dragTo(0, 12).release(); checkResultByText("((<selection>some (text)<caret></selection>))"); }
testWordSelectionOnMouseDragAroundPunctuation
271,909
void () { initText("ab<caret>cd"); ((EditorEx)getEditor()).setInsertMode(false); JComponent component = getEditor().getContentComponent(); component.dispatchEvent(new InputMethodEvent(component, InputMethodEvent.INPUT_METHOD_TEXT_CHANGED, new AttributedString("\uD83D\uDE00" /* 'GRINNING FACE' emoji (U+1F600) */).getIte...
testSurrogatePairInputInOverwriteMode
271,910
void () { initText("hello<caret>"); JComponent component = getEditor().getContentComponent(); component.dispatchEvent(new InputMethodEvent(component, InputMethodEvent.INPUT_METHOD_TEXT_CHANGED, new AttributedString("\u3145" /* ㅅ */).getIterator(), 0, TextHitInfo.afterOffset(0), TextHitInfo.afterOffset(-1))); component....
testInputMethodComposing
271,911
void () { initText("hello<caret>"); JComponent component = getEditor().getContentComponent(); component.dispatchEvent(new InputMethodEvent(component, InputMethodEvent.INPUT_METHOD_TEXT_CHANGED, new AttributedString("\u3145" /* ㅅ */).getIterator(), 0, null, null)); component.dispatchEvent(new InputMethodEvent(component,...
testInputMethodCaretMove
271,912
void () { FontLayoutService.setInstance(new MockFontLayoutService(cp -> cp == 'Z' ? 2 * TEST_CHAR_WIDTH : TEST_CHAR_WIDTH, TEST_LINE_HEIGHT, TEST_DESCENT)); initText(StringUtil.repeatSymbol('Z', 500) + "<caret>"); setEditorVisibleSize(100, 100); type(' '); Rectangle visibleArea = getEditor().getScrollingModel().getVisi...
testScrollingToCaretWithWideCharacters
271,913
void () { Registry.get("editor.block.caret.selection.vim-like").setValue(true, getTestRootDisposable()); initText("abcdef"); EditorTestUtil.setEditorVisibleSize(getEditor(), 1000, 1000); // enable drag testing getEditor().getSettings().setBlockCursor(true); int y = getEditor().getLineHeight() / 2; mouse().pressAtXY(3 *...
testMouseSelectionWithBlockCaret
271,914
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 = g...
testMouseSelectionAtLineEndWithBlockCaret
271,915
void () { if (!SystemInfo.isMac) return; // macOS-specific test initText("<caret>b"); JComponent component = getEditor().getContentComponent(); // 'A' key pressed dispatchEventToEditor(new KeyEvent(component, KeyEvent.KEY_PRESSED, 0, 0, KeyEvent.VK_A, 'a', KeyEvent.KEY_LOCATION_STANDARD)); dispatchEventToEditor(new Key...
testPressAndHoldInputMethodOnMac
271,916
void (AWTEvent event) { // this method ensures key events are dispatched to editor component, even if it's not focused KeyboardFocusManager.getCurrentKeyboardFocusManager().redispatchEvent(getEditor().getContentComponent(), event); }
dispatchEventToEditor
271,917
void () { getEditor().getContentComponent().getInputMethodRequests().getSelectedText(null); }
requestSelectedTextFromEditorViaImeApi
271,918
RangeMarker (final int start, final int end) { final Document document = myFixture.getEditor().getDocument(); return document.createGuardedBlock(start, end); }
createGuard
271,919
void () { myFixture.configureByText("x.txt", "xxxx"); RangeMarker guard = createGuard(0, 0); guard.setGreedyToLeft(true); guard.setGreedyToRight(true); checkUnableToTypeIn(0); checkCanTypeIn(1); }
testZero
271,920
void () { myFixture.configureByText("x.txt", "xxxxxxxx"); createGuard(1, 4); checkUnableToTypeIn(2); checkCanTypeIn(0); }
testInTheMiddle
271,921
void () { myFixture.configureByText("x.txt", "012345678"); { RangeMarker guard = createGuard(0, 5); guard.setGreedyToLeft(true); guard.setGreedyToRight(false); } { RangeMarker guard = createGuard(5, 6); guard.setGreedyToLeft(false); guard.setGreedyToRight(true); } checkCanTypeIn(5); checkUnableToTypeIn(0); }
testGreedy
271,922
void () { myFixture.configureByText("x.txt", "012345678"); { RangeMarker guard = createGuard(0, 5); guard.setGreedyToLeft(true); guard.setGreedyToRight(true); } checkUnableToTypeIn(5); }
testGreedyEnd
271,923
void (int offset) { String text = myFixture.getEditor().getDocument().getText(); try { myFixture.getEditor().getCaretModel().moveToOffset(offset); myFixture.type("y"); } catch (RuntimeException e) { assertEquals("Unable to perform an action since it changes read-only fragments of the current document",e.getMessage()); ...
checkUnableToTypeIn
271,924
void (int offset) { myFixture.getEditor().getCaretModel().moveToOffset(offset); myFixture.type("yy"); }
checkCanTypeIn
271,925
void () { String text = "abc abd a<caret> abx"; myFixture.configureByText("x.txt", text); int offset = myFixture.getEditor().getCaretModel().getOffset(); createGuard(offset - 1, myFixture.getFile().getTextLength()).setGreedyToRight(true); assertNull(myFixture.completeBasic()); myFixture.checkResult(text); //no hippie c...
testNoCompletion
271,926
void () { String text = "a\n#%%\nc"; // ^^^^^^^ <- guarded // com.intellij.openapi.editor.actions.DocumentGuardedTextUtil.insertString handles this case and inserts "\na" after first "a" myFixture.configureByText("x.txt", text); RangeMarker guard = createGuard(1, 6); myFixture.performEditorAction(IdeActions.ACTION_EDIT...
testDocumentGuardedTextUtilDuplicateLine
271,927
void () { String text = "a\n<caret>b\n#%%\nc"; // ^^^^^^^ <- guarded // com.intellij.openapi.editor.actions.DocumentGuardedTextUtil.deleteString handles this case and removes \n before caret myFixture.configureByText("x.txt", text); RangeMarker guard = createGuard(3, 8); myFixture.performEditorAction(IdeActions.ACTION_...
testDocumentGuardedTextUtilDeleteLine
271,928
void () { String text = "a\n#%%\nc"; // ^^^^^^^ <- guarded myFixture.configureByText("x.txt", text); createGuard(1, 6).setGreedyToLeft(true); try { myFixture.performEditorAction(IdeActions.ACTION_EDITOR_DUPLICATE_LINES); } catch (RuntimeException e) { assertEquals("Unable to perform an action since it changes read-only...
testDocumentGuardedTextUtilDuplicateLineWithGreedy
271,929
void () { String text = "a\n<caret>b\n#%%\nc"; // ^^^^^^^ <- guarded myFixture.configureByText("x.txt", text); createGuard(3, 8).setGreedyToLeft(true); try { myFixture.performEditorAction(IdeActions.ACTION_EDITOR_DELETE_LINE); } catch (RuntimeException e) { assertEquals("Unable to perform an action since it changes rea...
testDocumentGuardedTextUtilDeleteLineWithGreedy
271,930
boolean () { // Otherwise undoing doesn't work return false; }
isRunInCommand
271,931
void () { @SuppressWarnings("SpellCheckingInspection") /* * ( 0th) Lorem ipsum dolor sit amet, consectetur adipiscing elit, sed do eiusmod tempor incididunt ut labore et dolore magna aliqua. * ( 1st) Lorem ipsum dolor sit amet, consectetur adipiscing elit, sed do eiusmod tempor incididunt ut labore et dolore magna aliq...
testCaretNotificationsDuringTyping
271,932
void () { @SuppressWarnings("SpellCheckingInspection") /* * caret * (initial pos) * v * (0th) |Lorem ipsum dolor sit amet, consectetur adipiscing elit, sed do eiusmod tempor incididunt ut labore et dolore magna aliqua. * ^ * Actions from here: * 1. Caret left x 2 (no notifications are expected) * 2. Caret up x 2 (no no...
testCaretNotificationsOfCaretMovementsWithoutTextModifications
271,933
void () { // Any attempts to move the caret within an empty editor aren't supposed to cause caret movements => no caret updates are expected. final EditorImpl editor = initEditor("", 0, 0, 0); doTestCaretNotifications( editor.getContentComponent(), new CaretAction(() -> left(), null), new CaretAction(() -> right(), nul...
testCaretNotificationsWithinEmptyEditor
271,934
void () { // Undoing a modifying operation near the caret has to cause a caret update notification // The initial configuration is the same as the testCaretNotificationsDuringTyping's one final int caretInitialLineIndex = 10; final int caretInitialColumnIndex = 28; final int caretInitialDot = caretInitialLineIndex * (L...
testCaretNotificationsCausedByUndo
271,935
void () { @SuppressWarnings("SpellCheckingInspection") /* * dot and mark * (initial pos and after step 15) * v * (0th) |$Lorem ipsum dolor sit amet, consectetur adipiscing elit, sed do eiusmod tempor incididunt ut labore et dolore magna aliqua. * ^ * Actions from here: * 1. Left with selection x 2 (no notifications are...
testCaretNotificationsOfSelectionMovementsWithoutTextModificationsFromTopLeft
271,936
void () { @SuppressWarnings("SpellCheckingInspection") /* * (0th) Lorem ipsum dolor sit amet, consectetur adipiscing elit, sed do eiusmod tempor incididunt ut labore et dolore magna aliqua. * (1st) Lorem ipsum dolor sit amet, consectetur adipiscing elit, sed do eiusmod tempor incididunt ut labore et dolore magna aliqua...
testCaretNotificationsOfSelectionMovementsWithoutTextModificationsFromCenter
271,937
void () { // the "reflection" of the testCaretNotificationsOfSelectionMovementsWithoutTextModificationsFromTopLeft // Bottom right final int initialCaretLine = 5; final int initialCaretColumn = LOREM_IPSUM.length(); final int initialCaretOffset = initialCaretLine * (LOREM_IPSUM.length() + 1) + initialCaretColumn; final...
testCaretNotificationsOfSelectionMovementsWithoutTextModificationsFromBottomRight
271,938
void () { // Similar to testCaretNotificationsWithinEmptyEditor: // any attempts to move the selection within an empty editor aren't supposed to cause caret movements => no caret updates are expected. final EditorImpl editor = initEditor("", 0, 0, 0); doTestCaretNotifications( editor.getContentComponent(), new CaretAct...
testCaretNotificationsOfSelectionMovementsWithinEmptyEditor
271,939
void () { // Similar to testCaretNotificationsDuringTyping, but for multiple carets /* * caret #1 * v * (0th) |Lorem ipsum dolor sit amet, consectetur adipiscing elit, sed do eiusmod tempor incididunt ut labore et dolore magna aliqua. * ... * caret #5 * v * (2nd) Lorem ipsum dolor sit amet, consectetur adipisci|ng elit...
testMultiCaretNotificationsDuringTyping
271,940
void () { /* * (0th) Lorem ipsum dolor sit amet, consectetur adipiscing elit, sed do eiusmod tempor incididunt ut labore et dolore magna aliqua. * (1st) Lorem ipsum dolor sit amet, consectetur adipiscing elit, sed do eiusmod tempor incididunt ut labore et dolore magna aliqua. * * caret #1 * v * (2nd) Lorem ipsum dolor ...
testMultiCaretNotificationsOfSelectionMovementsWithoutTextModifications
271,941
EditorImpl (@NotNull String text, int caretLineIndex, int caretColumnIndex, int expectedCaretPosition) { initText(text); final EditorImpl editor = (EditorImpl)getEditor(); editor.getCaretModel().getPrimaryCaret().moveToVisualPosition(new VisualPosition(caretLineIndex, caretColumnIndex)); assertEquals("unexpected positi...
initEditor
271,942
Caret (@NotNull EditorImpl editor, boolean makePrimary, int caretLineIndex, int caretColumnIndex, int expectedCaretPosition) { final var result = editor.getCaretModel().addCaret(new VisualPosition(caretLineIndex, caretColumnIndex), makePrimary); assertNotNull("failed to add a caret", result); assertEquals("unexpected o...
addCaret
271,943
void (@NotNull JTextComponent editorComponent, CaretAction @NotNull ... caretActions) { /* * The implementation expects the following flow: * action.run() => caretUpdate() => returning control to the caller of action.run() */ final Ref<@Nullable CaretPos> caretUpdateNotification = new Ref<>(null); final int[] i = {0}; ...
doTestCaretNotifications
271,944
record (@NotNull Runnable action, @Nullable CaretPos caretUpdateNotification) {}
CaretAction
271,945
record (int dot, int mark) {}
CaretPos
271,946
void () { executeAction(IdeActions.ACTION_UNDO); }
undo
271,947
void () { initText("line1\nline2\n\n"); checkOverlapWithNormalRegion(0, 5, 1, 1, true); checkOverlapWithNormalRegion(12, 13, 1, 1, true); checkOverlapWithNormalRegion(6, 11, 1, 1, true); checkOverlapWithNormalRegion(6, 7, 1, 1, true); checkOverlapWithNormalRegion(10, 11, 1, 1, true); checkOverlapWithNormalRegion(7, 10,...
testAllowedOverlapping
271,948
void () { initText("line1\nline2\nline3\n"); addCustomFoldRegion(1, 2, 30); assertEquals(new VisualPosition(0, 2), getEditor().logicalToVisualPosition(new LogicalPosition(0, 2))); assertEquals(new VisualPosition(1, 0), getEditor().logicalToVisualPosition(new LogicalPosition(1, 2))); assertEquals(new VisualPosition(1, 0...
testCoordinateTransformations
271,949
void () { initText("line1\nline2\nline3\n"); getEditor().getSettings().setAdditionalLinesCount(0); getEditor().getSettings().setAdditionalColumnsCount(0); assertEquals(new Dimension(50, 48), getEditor().getContentComponent().getPreferredSize()); getEditor().getFoldingModel().runBatchFoldingOperation(() -> { assertNotNu...
testEditorSize
271,950
int (@NotNull CustomFoldRegion region) { return 75; }
calcWidthInPixels
271,951
int (@NotNull CustomFoldRegion region) { return 30; }
calcHeightInPixels
271,952
void (@NotNull CustomFoldRegion region, @NotNull Graphics2D g, @NotNull Rectangle2D targetRegion, @NotNull TextAttributes textAttributes) {}
paint
271,953
void () { initText("<caret>line1\nline2\nline3\n "); addCustomFoldRegion(1, 2, 2); assertEquals(new VisualPosition(0, 0), getEditor().getCaretModel().getVisualPosition()); right(); right(); right(); right(); right(); assertEquals(new VisualPosition(0, 5), getEditor().getCaretModel().getVisualPosition()); right(); asser...
testCaretMovement
271,954
void () { initText("text"); getEditor().getSettings().setAdditionalLinesCount(0); getEditor().getSettings().setAdditionalColumnsCount(0); FoldingModel foldingModel = getEditor().getFoldingModel(); int[] size = new int[] {35, 25}; CustomFoldRegion[] region = new CustomFoldRegion[1]; foldingModel.runBatchFoldingOperation...
testSizeUpdate
271,955
int (@NotNull CustomFoldRegion region) { return size[0]; }
calcWidthInPixels
271,956
int (@NotNull CustomFoldRegion region) { return size[1]; }
calcHeightInPixels
271,957
void (@NotNull CustomFoldRegion region, @NotNull Graphics2D g, @NotNull Rectangle2D targetRegion, @NotNull TextAttributes textAttributes) {}
paint
271,958
void () { initText("line1\nline2\nline3"); FoldingModelEx model = (FoldingModelEx)getEditor().getFoldingModel(); AtomicInteger invocationCount = new AtomicInteger(); model.addListener(new FoldingListener() { @Override public void beforeFoldRegionDisposed(@NotNull FoldRegion region) { invocationCount.incrementAndGet(); ...
testInvalidationDueToRelationToAnotherFoldRegion
271,959
void (@NotNull FoldRegion region) { invocationCount.incrementAndGet(); }
beforeFoldRegionDisposed
271,960
void () { initText("text"); getEditor().getSettings().setAdditionalLinesCount(0); getEditor().getSettings().setAdditionalColumnsCount(0); addInlay(4, 15); addCustomFoldRegion(0, 0, 40, 30); assertEquals(new Dimension(40, 30), getEditor().getContentComponent().getPreferredSize()); }
testInlineInlayAtLineEndDoesNotHaveImpact
271,961
void () { initText("line1\n<caret>line2\nline3"); assertNotNull(addCustomFoldRegion(1, 1)); delete(); checkResultByText("line1\n<caret>\nline3"); }
testDelete
271,962
void () { initText("line1\nline2\n<caret>\nline4"); assertNotNull(addCustomFoldRegion(1, 1)); backspace(); checkResultByText("line1\n<caret>\nline4"); }
testBackspace
271,963
void () { initText("text"); assertNotNull(addCustomFoldRegion(0, 0, 321, 123)); List<Boolean> results = new ArrayList<>(); getEditor().addEditorMouseMotionListener(new EditorMouseMotionListener() { @Override public void mouseMoved(@NotNull EditorMouseEvent e) { results.add(e.isOverText()); } }); mouse().moveToXY(400, 1...
testOverText
271,964
void (@NotNull EditorMouseEvent e) { results.add(e.isOverText()); }
mouseMoved
271,965
void () { initText("line1\nline2"); assertNotNull(addCustomFoldRegion(0, 0)); assertNotNull(addCollapsedFoldRegion(6, 11, "...")); runWriteCommand(() -> getEditor().getDocument().deleteString(5, 6)); verifyFoldingState("[FoldRegion +(5:10), placeholder='...']"); }
testOverlappingAfterDocumentChange
271,966
void () { initText(""); ((DocumentImpl)getEditor().getDocument()).setAcceptSlashR(true); runWriteCommand(() -> getEditor().getDocument().insertString(0, "a\rb\nc")); assertNotNull(addCustomFoldRegion(0, 0)); addCollapsedFoldRegion(3, 5, "..."); runWriteCommand(() -> getEditor().getDocument().deleteString(2, 3)); verify...
testOverlappingAfterDocumentChangeComplexLineBreaks
271,967
void (int regionStartOffset, int regionEndOffset, int customRegionStartLine, int customRegionEndLine, boolean allowed) { try { assertNotNull(addFoldRegion(regionStartOffset, regionEndOffset, ".")); CustomFoldRegion customRegion = addCustomFoldRegion(customRegionStartLine, customRegionEndLine); assertEquals(allowed, cus...
checkOverlapWithNormalRegion
271,968
void (int customRegionStartLine1, int customRegionEndLine1, int customRegionStartLine2, int customRegionEndLine2, boolean allowed) { try { assertNotNull(addCustomFoldRegion(customRegionStartLine1, customRegionEndLine1)); CustomFoldRegion customRegion2 = addCustomFoldRegion(customRegionStartLine2, customRegionEndLine2);...
checkOverlapWithCustomRegion
271,969
EditorView (@NotNull Editor editor) { return ((EditorImpl)editor).myView; }
getView
271,970
void (String text) { prepare(text, PlainTextFileType.INSTANCE); }
prepareText
271,971
void (String text, FileType fileType) { init(text.replace(RTL_CHAR_REPRESENTATION, RTL_CHAR), fileType); }
prepare
271,972
void (String text) { checkResultByText(text.replace(RTL_CHAR_REPRESENTATION, RTL_CHAR)); }
checkResult
271,973
void (int offset, LogicalPosition logicalPosition, VisualPosition visualPositionTowardsSmallerOffsets, VisualPosition visualPositionTowardsLargerOffsets, Point xy) { checkOffsetConversions(offset, logicalPosition, visualPositionTowardsSmallerOffsets, visualPositionTowardsLargerOffsets, xy, xy); }
checkOffsetConversions
271,974
void (int offset, LogicalPosition logicalPosition, VisualPosition visualPositionTowardsSmallerOffsets, VisualPosition visualPositionTowardsLargerOffsets, Point xyTowardsSmallerOffsets, Point xyTowardsLargerOffsets) { assertLogicalPositionsEqual("Wrong offset->logicalPosition calculation", logicalPosition, getEditor().o...
checkOffsetConversions
271,975
void (int logicalColumn, int offset, VisualPosition visualPositionForPrecedingLp, VisualPosition visualPositionForSucceedingLp) { checkLPConversions(lB(logicalColumn), offset, visualPositionForPrecedingLp); checkLPConversions(lF(logicalColumn), offset, visualPositionForSucceedingLp); }
checkLPConversions
271,976
void (LogicalPosition logicalPosition, int offset, VisualPosition visualPosition) { assertEquals("Wrong logicalPosition->offset calculation", offset, getEditor().logicalPositionToOffset(logicalPosition)); assertVisualPositionsEqual("Wrong logicalPosition->visualPosition calculation", visualPosition, getEditor().logical...
checkLPConversions
271,977
void (int visualColumn, LogicalPosition logicalPositionForLeftLeaningVp, LogicalPosition logicalPositionForRightLeaningVp, Point xy) { checkVPConversions(vL(visualColumn), logicalPositionForLeftLeaningVp, xy); checkVPConversions(vR(visualColumn), logicalPositionForRightLeaningVp, xy); }
checkVPConversions
271,978
void (VisualPosition visualPosition, LogicalPosition logicalPosition, Point xy) { assertLogicalPositionsEqual("Wrong visualPosition->logicalPosition calculation", logicalPosition, getEditor().visualToLogicalPosition(visualPosition)); assertEquals("Wrong visualPosition->xy calculation", xy, getEditor().visualPositionToX...
checkVPConversions
271,979
void (Point xy, VisualPosition visualPosition) { assertVisualPositionsEqual("Wrong xy->visualPosition calculation", visualPosition, getEditor().xyToVisualPosition(xy)); }
checkXYConversion
271,980
void (String message, LogicalPosition expectedPosition, LogicalPosition actualPosition) { assertEquals(message, expectedPosition, actualPosition); assertEquals(message + " (direction flag)", expectedPosition.leansForward, actualPosition.leansForward); }
assertLogicalPositionsEqual
271,981
void (String message, VisualPosition expectedPosition, VisualPosition actualPosition) { assertEquals(message, expectedPosition, actualPosition); assertEquals(message + " (direction flag)", expectedPosition.leansRight, actualPosition.leansRight); }
assertVisualPositionsEqual
271,982
void (VisualPosition visualPosition) { assertVisualPositionsEqual("Wrong caret position", visualPosition, getEditor().getCaretModel().getVisualPosition()); }
assertCaretPosition
271,983
void (int visualColumn, boolean reversedDirection) { assertVisualCaretLocation(0, visualColumn, reversedDirection); }
assertVisualCaretLocation
271,984
void (int visualLine, int visualColumn, boolean reversedDirection) { assertEquals(1, getEditor().getCaretModel().getCaretCount()); Caret caret = getEditor().getCaretModel().getPrimaryCaret(); assertEquals(visualLine, caret.getVisualPosition().line); assertEquals(visualColumn, caret.getVisualPosition().column); assertEq...
assertVisualCaretLocation
271,985
void (String textWithBoundaryMarkers, String fileExtension) { java.util.List<Integer> expectedBoundaryPositions = new ArrayList<>(); StringBuilder rawTextBuilder = new StringBuilder(); for (int i = 0; i < textWithBoundaryMarkers.length(); i++) { char c = textWithBoundaryMarkers.charAt(i); if (c == BIDI_BOUNDARY_MARKER)...
checkBidiRunBoundaries
271,986
LogicalPosition (int column) { return new LogicalPosition(0, column); }
lB
271,987
LogicalPosition (int line, int column) { return new LogicalPosition(line, column); }
lB
271,988
LogicalPosition (int column) { return new LogicalPosition(0, column, true); }
lF
271,989
LogicalPosition (int line, int column) { return new LogicalPosition(line, column, true); }
lF
271,990
VisualPosition (int column) { return new VisualPosition(0, column); }
vL
271,991
VisualPosition (int line, int column) { return new VisualPosition(line, column); }
vL
271,992
VisualPosition (int column) { return new VisualPosition(0, column, true); }
vR
271,993
VisualPosition (int line, int column) { return new VisualPosition(line, column, true); }
vR
271,994
Point (int x) { return new Point(x, 0); }
xy
271,995
Point (int x, int y) { return new Point(x, y); }
xy
271,996
int (int h) { return (int)(FontPreferences.DEFAULT_LINE_SPACING * h); }
ls
271,997
Component () { return myFocusOwner; }
getFocusOwner
271,998
BufferedImage (BufferedImage image) { //noinspection UndesirableClassUsage return new BufferedImage(image.getColorModel(), image.copyData(null), image.getColorModel().isAlphaPremultiplied(), null); }
copy
271,999
void (String text) { init(text, PlainTextFileType.INSTANCE); getEditor().getSettings().setAdditionalLinesCount(0); getEditor().getSettings().setAdditionalColumnsCount(3); getEditor().getSettings().setCaretRowShown(false); }
init