Unnamed: 0 int64 0 305k | body stringlengths 7 52.9k | name stringlengths 1 185 |
|---|---|---|
243,200 | void (@NotNull Disposable disposable, int widthInPixels) { if (widthInPixels < 0 || widthInPixels > Short.MAX_VALUE) throw new IllegalArgumentException(); myLeftFreePaintersAreaReserveWidth += widthInPixels; updateSize(); Disposer.register(disposable, () -> { myLeftFreePaintersAreaReserveWidth -= widthInPixels; updateS... | reserveLeftFreePaintersAreaWidth |
243,201 | void (@NotNull Disposable disposable, int widthInPixels) { if (widthInPixels < 0 || widthInPixels > Short.MAX_VALUE) throw new IllegalArgumentException(); myRightFreePaintersAreaReserveWidth += widthInPixels; updateSize(); Disposer.register(disposable, () -> { myRightFreePaintersAreaReserveWidth -= widthInPixels; updat... | reserveRightFreePaintersAreaWidth |
243,202 | void (int width) { myStartIconAreaWidth = width; } | setInitialIconAreaWidth |
243,203 | void (MouseEvent e) { int logicalLineAtCursor = EditorUtil.yPositionToLogicalLine(myEditor, e); Point point = e.getPoint(); PointInfo info = getPointInfo(point); if (info != null) { logGutterIconClick(info.renderer); } myLastActionableClick = new ClickInfo(logicalLineAtCursor, info == null ? point : info.iconCenterPosi... | invokePopup |
243,204 | void (@NotNull ActionGroup group, MouseEvent e) { e.consume(); ActionPopupMenu popupMenu = ActionManager.getInstance().createActionPopupMenu(ActionPlaces.EDITOR_GUTTER_POPUP, group); putClientProperty(EDITOR_GUTTER_CONTEXT_MENU_KEY, popupMenu); popupMenu.getComponent().addPopupMenuListener(new PopupMenuListenerAdapter(... | showGutterContextMenu |
243,205 | void (PopupMenuEvent e) { EditorGutterComponentImpl.this.putClientProperty(EDITOR_GUTTER_CONTEXT_MENU_KEY, null); } | popupMenuWillBecomeInvisible |
243,206 | boolean () { return getClientProperty(EDITOR_GUTTER_CONTEXT_MENU_KEY) != null; } | isGutterContextMenuShown |
243,207 | List<AnAction> (int logicalLine) { final List<AnAction> addActions = new ArrayList<>(); if (myCanCloseAnnotations) addActions.add(new CloseAnnotationsAction()); //if (line >= myEditor.getDocument().getLineCount()) return; for (TextAnnotationGutterProvider gutterProvider : myTextAnnotationGutters) { final List<AnAction>... | getTextAnnotationPopupActions |
243,208 | void (@NotNull PointInfo info) { ClickInfo clickInfo = myLastActionableClick; if (clickInfo == null) return; boolean[] removed = {false}; EdtScheduledExecutorService.getInstance().schedule(() -> { if (myLastActionableClick != clickInfo || removed[0]) return; clickInfo.myProgressVisualLine = info.visualLine; clickInfo.m... | addLoadingIconForGutterMark |
243,209 | void () { Runnable remover = myLastActionableClick == null ? null : myLastActionableClick.myProgressRemover; if (remover == null) return; myLastActionableClick.myProgressRemover = null; remover.run(); } | removeLoadingIconForGutterMark |
243,210 | void (MouseEvent e) { } | mouseEntered |
243,211 | void (MouseEvent e) { TooltipController.getInstance().cancelTooltip(GUTTER_TOOLTIP_GROUP, e, false); updateFreePainters(e); updateHover(null); } | mouseExited |
243,212 | int (final Point p) { DocumentEx document = myEditor.getDocument(); int line = EditorUtil.yPositionToLogicalLine(myEditor, p); if (!DocumentUtil.isValidLine(line, document)) return -1; int startOffset = document.getLineStartOffset(line); final FoldRegion region = myEditor.getFoldingModel().getCollapsedRegionAtOffset(st... | convertPointToLineNumber |
243,213 | void () { for (TextAnnotationGutterProvider gutterProvider : myTextAnnotationGutters) { gutterProvider.gutterClosed(); } myProviderToListener.clear(); } | dispose |
243,214 | boolean () { return ScreenReader.isActive(); } | isFocusable |
243,215 | AccessibleContext () { if (accessibleContext == null) { accessibleContext = new AccessibleJComponent() { }; } return accessibleContext; } | getAccessibleContext |
243,216 | int () { if (ExperimentalUI.isNewUI()) { //have a placeholder for breakpoints return 12; } return 0; } | getInitialLineNumberWidth |
243,217 | void (@NotNull Component component, boolean hovered) { if (component instanceof EditorGutterComponentImpl gutter && ExperimentalUI.isNewUI()) { gutter.myHovered = hovered; gutter.updateFoldingOutlineVisibility(); } } | hoverChanged |
243,218 | EventLogGroup () { return GROUP; } | getGroup |
243,219 | int () { return myHoveredFreeMarkersLine; } | getHoveredFreeMarkersLine |
243,220 | void (@NotNull CaretEvent event) { if (event.getOldPosition().line != event.getNewPosition().line && event.getCaret() == event.getEditor().getCaretModel().getPrimaryCaret() && getPrimaryLineNumberConverter().shouldRepaintOnCaretMovement()) { repaint(); } } | caretPositionChanged |
243,221 | String (@NotNull Editor editor, @NotNull Collection<? super TextBlockTransferableData> extraDataCollector) { return getSelectedTextForClipboard(editor, CopyPasteOptions.DEFAULT, extraDataCollector); } | getSelectedTextForClipboard |
243,222 | String (@NotNull Editor editor, @NotNull CopyPasteOptions options, @NotNull Collection<? super TextBlockTransferableData> extraDataCollector) { final StringBuilder buf = new StringBuilder(); String separator = ""; List<Caret> carets = editor.getCaretModel().getAllCarets(); int[] startOffsets = new int[carets.size()]; i... | getSelectedTextForClipboard |
243,223 | record ( @NotNull Caret caret, @NotNull VisualPosition position, int lineStartOffset, @NotNull VisualPosition lineStartPosition ) { static @NotNull CaretLineState create(@NotNull Caret caret) { Editor editor = caret.getEditor(); int lineStartOffset = EditorUtil.getNotFoldedLineStartOffset(editor, caret.getOffset()); Vi... | CaretLineState |
243,224 | CaretLineState (@NotNull Caret caret) { Editor editor = caret.getEditor(); int lineStartOffset = EditorUtil.getNotFoldedLineStartOffset(editor, caret.getOffset()); VisualPosition lineStartPosition = editor.offsetToVisualPosition(lineStartOffset); return new CaretLineState(caret, caret.getVisualPosition(), lineStartOffs... | create |
243,225 | TextRange (@NotNull StringBuilder sb, @NotNull String line) { int startOffset = sb.length(); sb.append(line); if (!line.endsWith("\n")) { sb.append("\n"); } int endOffset = sb.length(); return TextRange.create(startOffset, endOffset); } | appendEntireLine |
243,226 | TextRange (@NotNull Editor editor, @NotNull String text) { Caret caret = editor.getCaretModel().getCurrentCaret(); CaretLineState caretLineState = CaretLineState.create(caret); int lineStartOffset = caretLineState.lineStartOffset; if (!text.endsWith("\n")) text += "\n"; editor.getDocument().insertString(lineStartOffset... | insertEntireLineAboveCaret |
243,227 | TextRange (@NotNull Editor editor, @NotNull String text) { return insertStringAtCaret(editor, text, false); } | insertStringAtCaret |
243,228 | TextRange (@NotNull Editor editor, @NotNull String text, boolean trimIfMiddleLine) { int selectionStart = editor.getSelectionModel().getSelectionStart(); if (trimIfMiddleLine) { int selectionEnd = editor.getSelectionModel().getSelectionEnd(); if (!DocumentUtil.isAtLineStart(selectionEnd, editor.getDocument())) { text =... | insertStringAtCaret |
243,229 | String (@NotNull Editor editor, @NotNull String text) { text = TextBlockTransferable.convertLineSeparators(editor, text); text = trimTextIfNeeded(editor, text); return text; } | normalizeText |
243,230 | String (Editor editor, String text) { JComponent contentComponent = editor.getContentComponent(); if (contentComponent instanceof JTextComponent) { Document document = ((JTextComponent)contentComponent).getDocument(); if (document != null && document.getProperty(TRIM_TEXT_ON_PASTE_KEY) == Boolean.TRUE) { return text.tr... | trimTextIfNeeded |
243,231 | CopiedFromEmptySelectionPasteMode () { return AdvancedSettings.getEnum(COPIED_FROM_EMPTY_SELECTION_PASTE_MODE, CopiedFromEmptySelectionPasteMode.class); } | getCopiedFromEmptySelectionPasteMode |
243,232 | DataFlavor () { return FLAVOR; } | getFlavor |
243,233 | CopyPasteOptions (@NotNull Transferable transferable) { CopyPasteOptionsTransferableData transferableData = fromTransferable(transferable); return transferableData == null ? CopyPasteOptions.DEFAULT : transferableData.options; } | valueFromTransferable |
243,234 | int () { return myHeightInPixels; } | getHeightInPixels |
243,235 | Placement () { return myShowAbove ? Placement.ABOVE_LINE : Placement.BELOW_LINE; } | getPlacement |
243,236 | VisualPosition () { return myEditor.offsetToVisualPosition(getOffset()); } | getVisualPosition |
243,237 | int () { return myHeightInPixels; } | getAsInt |
243,238 | InlayProperties () { return new InlayProperties() .relatesToPrecedingText(isRelatedToPrecedingText()) .showAbove(myShowAbove) .showWhenFolded(myShowWhenFolded) .priority(myPriority); } | getProperties |
243,239 | String () { return "[Block inlay, offset=" + getOffset() + ", width=" + myWidthInPixels + ", height=" + myHeightInPixels + ", renderer=" + myRenderer + "]" + (isValid() ? "" : "(invalid)"); } | toString |
243,240 | boolean () { return myEditor.getCaretModel().getCurrentCaret().isUnknownDirection(); } | isUnknownDirection |
243,241 | void (boolean unknownDirection) { myEditor.getCaretModel().getCurrentCaret().setUnknownDirection(unknownDirection); } | setUnknownDirection |
243,242 | Editor () { return myEditor; } | getEditor |
243,243 | void (SelectionEvent event) { for (SelectionListener listener : mySelectionListeners) { try { listener.selectionChanged(event); } catch (Exception e) { LOG.error(e); } } } | broadcastSelectionEvent |
243,244 | void (@NotNull LogicalPosition blockStart, @NotNull LogicalPosition blockEnd) { List<CaretState> caretStates = EditorModificationUtil.calcBlockSelectionState(myEditor, blockStart, blockEnd); myEditor.getCaretModel().setCaretsAndSelections(caretStates); } | setBlockSelection |
243,245 | void (@NotNull SelectionListener listener) { mySelectionListeners.add(listener); } | addSelectionListener |
243,246 | void (@NotNull SelectionListener listener) { boolean success = mySelectionListeners.remove(listener); LOG.assertTrue(success); } | removeSelectionListener |
243,247 | void () { EditorCopyPasteHelper.getInstance().copySelectionToClipboard(myEditor); } | copySelectionToClipboard |
243,248 | TextAttributes () { if (myTextAttributes == null) { TextAttributes textAttributes = new TextAttributes(); EditorColorsScheme scheme = myEditor.getColorsScheme(); textAttributes.setForegroundColor(scheme.getColor(EditorColors.SELECTION_FOREGROUND_COLOR)); textAttributes.setBackgroundColor(scheme.getColor(EditorColors.SE... | getTextAttributes |
243,249 | void () { myTextAttributes = null; } | reinitSettings |
243,250 | int (@NotNull IntervalNode<ErrorStripeMarkerImpl> i1, @NotNull IntervalNode<ErrorStripeMarkerImpl> i2) { Node o1 = (Node)i1; Node o2 = (Node)i2; int d = o2.myLayer - o1.myLayer; if (d != 0) { return d; } int result = super.compareEqualStartIntervals(i1, i2); if (result != 0) { return result; } boolean persistent1 = o1.... | compareEqualStartIntervals |
243,251 | Node (@NotNull ErrorStripeMarkerImpl key, int start, int end, boolean greedyToLeft, boolean greedyToRight, boolean stickingToRight, int layer) { return new Node(this, key, start, end, greedyToLeft, greedyToRight, stickingToRight, layer); } | createNewNode |
243,252 | CustomFoldRegionRenderer () { return myRenderer; } | getRenderer |
243,253 | int () { return myWidthInPixels; } | getWidthInPixels |
243,254 | int () { return myHeightInPixels; } | getHeightInPixels |
243,255 | void () { ThreadingAssertions.assertEventDispatchThread(); if (myEditor.isDisposed() || !isValid()) return; if (myEditor.myDocumentChangeInProgress) { throw new IllegalStateException("Custom fold region shouldn't be updated during document change"); } int oldWidth = myWidthInPixels; int oldHeight = myHeightInPixels; Gu... | update |
243,256 | void () { if (isValid() && !myEditor.isDisposed()) { if (myEditor.getFoldingModel().isInBatchFoldingOperation()) { myEditor.getFoldingModel().myRepaintRequested = true; } else { JComponent component = myEditor.getContentComponent(); if (component.isShowing()) { Point location = getLocation(); if (location != null) { co... | repaint |
243,257 | void () { myWidthInPixels = Math.max(0, myRenderer.calcWidthInPixels(this)); myHeightInPixels = Math.max(myEditor.getLineHeight(), myRenderer.calcHeightInPixels(this)); myGutterIconRenderer = myRenderer.calcGutterIconRenderer(this); } | doUpdate |
243,258 | Point () { int startOffset = getStartOffset(); FoldRegion visibleRegion = myEditor.getFoldingModel().getCollapsedRegionAtOffset(startOffset); return visibleRegion == this ? new Point(myEditor.getContentComponent().getInsets().left, myEditor.visualLineToY(myEditor.offsetToVisualLine(startOffset))) : null; } | getLocation |
243,259 | String () { return super.toString() + ", renderer: " + myRenderer + ", size: " + myWidthInPixels + "x" + myHeightInPixels; } | toString |
243,260 | void (Component component, Graphics2D g) { if (!nrp.get()) return; long currentTimeMillis = System.currentTimeMillis(); float alpha = 1 - (float)frameIndex / TOTAL_FRAMES; g.setComposite(AlphaComposite.getInstance(AlphaComposite.SRC_OVER, alpha)); Image scaledImage = ImageUtil.scaleImage(myImage, alpha); int x = myExpl... | executePaint |
243,261 | boolean () { return nrp.get(); } | needsRepaint |
243,262 | void (@NotNull Editor editor) { editor.putUserData(DISABLED, Boolean.TRUE); TooltipController.getInstance().cancelTooltip(FOLDING_TOOLTIP_GROUP, null, true); } | disableForEditor |
243,263 | void (@NotNull Editor editor) { editor.putUserData(DISABLED, null); } | enableForEditor |
243,264 | void (@NotNull EditorMouseEvent e) { myAlarm.cancelAllRequests(); Editor editor = e.getEditor(); if (editor.getUserData(DISABLED) != null) return; if (e.getArea() == EditorMouseEventArea.EDITING_AREA) { MouseEvent mouseEvent = e.getMouseEvent(); Point point = mouseEvent.getPoint(); FoldRegion fold = e.getCollapsedFoldR... | mouseMoved |
243,265 | DocumentFragment (@NotNull FoldRegion fold) { EditorImpl editor = (EditorImpl)fold.getEditor(); Document document = editor.getDocument(); FoldingGroup group = fold.getGroup(); int startOffset = fold.getStartOffset(); int endOffset = fold.getEndOffset(); if (group != null) { int groupEndOffset = editor.getFoldingModel()... | createDocumentFragment |
243,266 | void (@NotNull EditorMouseEvent e) { myAlarm.cancelAllRequests(); if (e.getEditor().getUserData(DISABLED) != null) return; TooltipController.getInstance().cancelTooltip(FOLDING_TOOLTIP_GROUP, e.getMouseEvent(), true); } | mouseExited |
243,267 | void (AncestorEvent event) { hidePopup(); } | ancestorMoved |
243,268 | void (MouseEvent event) { insidePopup = true; } | mouseEntered |
243,269 | void (MouseEvent event) { Point point = event.getPoint(); if (!myContent.getBounds().contains(point) || point.x == 0 || point.y == 0) { insidePopup = false; if (canClose()) { hidePopup(); } } } | mouseExited |
243,270 | boolean () { return !insidePopup && !StackingPopupDispatcher.getInstance().isPopupFocused(); } | canClose |
243,271 | void (@NotNull InputEvent event, @NotNull AnalyzerStatus analyzerStatus) { hidePopup(); if (analyzerStatus.isEmpty()) return; // do not show new popup updateContentPanel(analyzerStatus); ComponentPopupBuilder myPopupBuilder = JBPopupFactory.getInstance().createComponentPopupBuilder(myContent, null). setCancelOnClickOut... | showPopup |
243,272 | void (@NotNull LightweightWindowEvent event) { analyzerStatus.getController().onClosePopup(); myEditor.getComponent().removeAncestorListener(myAncestorListener); } | onClosed |
243,273 | void (@NotNull AnalyzerStatus analyzerStatus) { UIController controller = analyzerStatus.getController(); java.util.List<PassWrapper> passes = analyzerStatus.getPasses(); Set<String> presentableNames = ContainerUtil.map2Set(passes, p -> p.getPresentableName()); if (!presentableNames.isEmpty() && myProgressBarMap.keySet... | updateContentPanel |
243,274 | DataContext () { return ((EditorEx)myEditor).getDataContext(); } | getDataContext |
243,275 | JComponent (@NotNull AnalyzerStatus analyzerStatus) { @Nls StringBuilder text = new StringBuilder(); List<StatusItem> expandedStatus = analyzerStatus.getExpandedStatus(); for (int i = 0; i < expandedStatus.size(); i++) { boolean last = i == expandedStatus.size() - 1; StatusItem item = expandedStatus.get(i); String deta... | createDetailsPanel |
243,276 | JPanel (@NotNull UIController controller) { JPanel panel = new JPanel(new GridBagLayout()); GridBag gc = new GridBag().nextLine(); if (PowerSaveMode.isEnabled()) { panel.add(new TrackableLinkLabel(EditorBundle.message("iw.disable.powersave"), () ->{ PowerSaveMode.setEnabled(false); hidePopup(); }), gc.next().anchor(Gri... | createLowerPanel |
243,277 | DropDownLink<InspectionsLevel> (@NotNull LanguageHighlightLevel level, @NotNull UIController controller, @NotNull @Nls String prefix) { return new DropDownLink<>(level.getLevel(), controller.getAvailableLevels(), inspectionsLevel -> { controller.setHighLightLevel(new LanguageHighlightLevel(level.getLangID(), inspection... | createDropDownLink |
243,278 | String (@NotNull InspectionsLevel item) { return prefix + item; } | itemToString |
243,279 | JLabel (@NotNull LanguageHighlightLevel level, @NotNull @Nls String prefix, @NotNull @Nls String msg) { JLabel label = new JLabel(prefix + level.getLevel()); new HelpTooltip().setDescription(msg).installOn(label); return label; } | createNoChangeLabel |
243,280 | void (InputEvent e) { myEvent = e; super.doClick(e); } | doClick |
243,281 | int () { return 1; } | getLength |
243,282 | int (int startColumn) { int tabSize = myView.getTabSize(); return tabSize - startColumn % tabSize; } | getLogicalColumnCount |
243,283 | int (float startX) { float x = getNextTabStop(startX); return EditorUtil.columnsNumber(x - startX, myView.getPlainSpaceWidth()); } | getVisualColumnCount |
243,284 | Consumer<Graphics2D> (float x, float y, int startColumn, int endColumn) { return g -> {}; } | draw |
243,285 | LineFragment (int startOffset, int endOffset) { return this; } | subFragment |
243,286 | float (float startX, int startOffset, int offset) { return trimOffset(offset) <= trimOffset(startOffset) ? startX : getNextTabStop(startX); } | offsetToX |
243,287 | int (float startX, int startColumn, int column) { int visualColumnCount = getVisualColumnCount(startX); int logicalColumnCount = getLogicalColumnCount(startColumn); return column == logicalColumnCount ? visualColumnCount : Math.min(column, visualColumnCount - 1); } | logicalToVisualColumn |
243,288 | int (float startX, int startColumn, int column) { int visualColumnCount = getVisualColumnCount(startX); int logicalColumnCount = getLogicalColumnCount(startColumn); return column == visualColumnCount ? logicalColumnCount : Math.min(column, logicalColumnCount - 1); } | visualToLogicalColumn |
243,289 | int (float startX, int column) { int visualColumnCount = getVisualColumnCount(startX); return column == visualColumnCount ? 1 : 0; } | visualColumnToOffset |
243,290 | int[] (float startX, float x) { if (x <= startX) return new int[] {0, 0}; float nextTabStop = getNextTabStop(startX); if (x > nextTabStop) return new int[] {getVisualColumnCount(startX), 1}; int column; boolean closerToLargerColumns; if (myEditor.getSettings().isCaretInsideTabs()) { float plainSpaceWidth = myView.getPl... | xToVisualColumn |
243,291 | float (float startX, int column) { if (column <= 0) return startX; if (column >= getVisualColumnCount(startX)) return getNextTabStop(startX); return startX + myView.getPlainSpaceWidth() * column; } | visualColumnToX |
243,292 | int (int offset) { return offset <= 0 ? 0 : 1; } | trimOffset |
243,293 | float (float x) { int leftInset = myView.getInsets().left; return EditorUtil.nextTabStop(x - leftInset, myView.getPlainSpaceWidth(), myView.getTabSize()) + leftInset; } | getNextTabStop |
243,294 | void () { myEditor.getScrollingModel().removeVisibleAreaListener(this); myEditor.getContentComponent().removeHierarchyListener(this); } | dispose |
243,295 | void (HierarchyEvent e) { if ((e.getChangeFlags() & HierarchyEvent.SHOWING_CHANGED) != 0 && e.getComponent().isShowing()) { checkFontRenderContext(null); } } | hierarchyChanged |
243,296 | void (@NotNull VisibleAreaEvent e) { checkFontRenderContext(null); } | visibleAreaChanged |
243,297 | int (int y) { assertNotInBulkMode(); return myMapper.yToVisualLine(y); } | yToVisualLine |
243,298 | int (int line) { assertNotInBulkMode(); return myMapper.visualLineToY(line); } | visualLineToY |
243,299 | int[] (int line) { assertNotInBulkMode(); return myMapper.visualLineToYRange(line); } | visualLineToYRange |
Subsets and Splits
No community queries yet
The top public SQL queries from the community will appear here once available.