Unnamed: 0 int64 0 305k | body stringlengths 7 52.9k | name stringlengths 1 185 |
|---|---|---|
264,800 | void (boolean useLigatures) { ensureEditableFontPreferences().setUseLigatures(useLigatures); } | setUseLigatures |
264,801 | Font (EditorFontType key) { return fontPreferences instanceof DelegatingFontPreferences ? EditorFontCache.getInstance().getFont(key) : super.getFont(key); } | getFont |
264,802 | FontPreferences () { return fontPreferences; } | getFontPreferences |
264,803 | void (@NotNull FontPreferences preferences) { preferences.copyTo(ensureEditableFontPreferences()); initFonts(); } | setFontPreferences |
264,804 | void (String fontName) { ModifiableFontPreferences currPreferences = ensureEditableFontPreferences(); boolean useLigatures = currPreferences.useLigatures(); float editorFontSize = getEditorFontSize2D(); currPreferences.clear(); currPreferences.register(fontName, editorFontSize); currPreferences.setUseLigatures(useLigat... | setEditorFontName |
264,805 | int () { return fontPreferences.getSize(fontPreferences.getFontFamily()); } | getEditorFontSize |
264,806 | void (int fontSize) { setEditorFontSize((float)fontSize); } | setEditorFontSize |
264,807 | void (float fontSize) { fontSize = EditorFontsConstants.checkAndFixEditorFontSize(fontSize); ensureEditableFontPreferences().register(fontPreferences.getFontFamily(), fontSize); initFonts(); setSaveNeeded(true); } | setEditorFontSize |
264,808 | float () { return fontPreferences.getSize2D(fontPreferences.getFontFamily()); } | getEditorFontSize2D |
264,809 | float () { return fontPreferences.getLineSpacing(); } | getLineSpacing |
264,810 | void (float lineSpacing) { ensureEditableFontPreferences().setLineSpacing(lineSpacing); } | setLineSpacing |
264,811 | void () { reset(); } | initFonts |
264,812 | EditorColorsScheme () { return this; } | getFontCacheScheme |
264,813 | void (@NotNull Element parentNode) { UISettings settings = UISettings.getInstanceOrNull(); ColorBlindness blindness = settings == null ? null : settings.getColorBlindness(); myValueReader.setAttribute(blindness == null ? null : blindness.name()); if (SCHEME_ELEMENT.equals(parentNode.getName())) { readScheme(parentNode)... | readExternal |
264,814 | void (@NotNull Element node) { deprecatedBackgroundColor = null; if (!SCHEME_ELEMENT.equals(node.getName())) { return; } setName(node.getAttributeValue(NAME_ATTR)); int readVersion = Integer.parseInt(node.getAttributeValue(VERSION_ATTR, "0")); if (readVersion > CURR_VERSION) { throw new IllegalStateException("Unsupport... | readScheme |
264,815 | void (@NotNull Element metaInfoElement) { metaInfo.clear(); for (Element e : metaInfoElement.getChildren()) { if (PROPERTY_ELEMENT.equals(e.getName())) { String propertyName = e.getAttributeValue(PROPERTY_NAME_ATTR); if (propertyName != null) { metaInfo.setProperty(propertyName, e.getText()); } } } } | readMetaInfo |
264,816 | void (@NotNull Element childNode) { for (Element e : childNode.getChildren(OPTION_ELEMENT)) { String keyName = e.getAttributeValue(NAME_ATTR); Element valueElement = e.getChild(VALUE_ELEMENT); TextAttributes attr = valueElement != null ? myValueReader.read(TextAttributes.class, valueElement) : e.getAttributeValue(BASE_... | readAttributes |
264,817 | void (@NotNull Element childNode) { for (Element colorElement : childNode.getChildren(OPTION_ELEMENT)) { String keyName = colorElement.getAttributeValue(NAME_ATTR); Color valueColor = myValueReader.read(Color.class, colorElement); if (valueColor == null && colorElement.getAttributeValue(BASE_ATTRIBUTES_ATTR) != null) {... | readColors |
264,818 | void (@NotNull Element childNode, boolean isDefault, @NotNull Ref<Float> fontScale) { switch (childNode.getAttributeValue(NAME_ATTR)) { case FONT_SCALE -> fontScale.set(myValueReader.read(Float.class, childNode)); case LINE_SPACING -> { Float value = myValueReader.read(Float.class, childNode); if (value != null) setLin... | readSettings |
264,819 | float (Element element, boolean isDefault, Float fontScale) { if (isDefault) { return UISettings.getDefFontSize(); } // Use integer size for compatibility Integer intSize = myValueReader.read(Integer.class, element); if (intSize == null) { return -1; } return UISettings.restoreFontSize(intSize.floatValue(), fontScale);... | readFontSize |
264,820 | void (@NotNull ModifiableFontPreferences preferences, @NotNull Element element, boolean isDefaultScheme, @Nullable Float fontScale, boolean clearFonts) { if (clearFonts) preferences.clearFonts(); List<Element> children = element.getChildren(OPTION_ELEMENT); String fontFamily = null; float size = -1; for (Element e : ch... | readFontSettings |
264,821 | void (Element parentNode) { parentNode.setAttribute(NAME_ATTR, getName()); parentNode.setAttribute(VERSION_ATTR, Integer.toString(version)); /* * FONT_SCALE is used to correctly identify the font size in both the JRE-managed HiDPI mode and * the IDE-managed HiDPI mode: {@link UIUtil#isJreHiDPIEnabled()}. Also, it helps... | writeExternal |
264,822 | void (@NotNull Element attrElements) { List<Map.Entry<String, TextAttributes>> list = new ArrayList<>(attributesMap.entrySet()); list.sort(Map.Entry.comparingByKey()); for (Map.Entry<String, TextAttributes> entry : list) { String keyName = entry.getKey(); TextAttributes attributes = entry.getValue(); writeAttribute(att... | writeAttributes |
264,823 | void (@NotNull Element attrElements, @NotNull TextAttributesKey key, @NotNull TextAttributes attributes) { EditorColorsScheme baseScheme = getBaseScheme(); if (attributes == INHERITED_ATTRS_MARKER) { TextAttributesKey baseKey = key.getFallbackAttributeKey(); // IDEA-162774 do not store if inheritance = on in the parent... | writeAttribute |
264,824 | void () { EditorColorsScheme parentScheme = this.parentScheme; if (parentScheme == null) { return; } attributesMap.entrySet().removeIf(entry -> { String keyName = entry.getKey(); TextAttributes attrs = entry.getValue(); TextAttributesKey key = TextAttributesKey.find(keyName); if (attrs == INHERITED_ATTRS_MARKER) { retu... | optimizeAttributeMap |
264,825 | Element () { Element metaInfoElement = new Element(META_INFO_ELEMENT); metaInfo.setProperty(META_INFO_MODIFIED_TIME, META_INFO_DATE_FORMAT.format(new Date())); List<String> sortedPropertyNames = new ArrayList<>(metaInfo.stringPropertyNames()); sortedPropertyNames.sort(null); for (String propertyName : sortedPropertyNam... | metaInfoToElement |
264,826 | void (@NotNull Element colorElements) { List<ColorKey> list = new ArrayList<>(colorMap.keySet()); list.sort(null); for (ColorKey key : list) { writeColor(colorElements, key); } } | writeColors |
264,827 | void (@NotNull Element colorElements, @NotNull ColorKey key) { EditorColorsScheme baseScheme = getBaseScheme(); Color color = colorMap.get(key); if (color == INHERITED_COLOR_MARKER) { ColorKey fallbackKey = key.getFallbackColorKey(); Color parentFallback = baseScheme instanceof AbstractColorsScheme ? ((AbstractColorsSc... | writeColor |
264,828 | ModifiableFontPreferences () { if (!(fontPreferences instanceof ModifiableFontPreferences)) { ModifiableFontPreferences editableFontPreferences = new FontPreferencesImpl(); fontPreferences.copyTo(editableFontPreferences); fontPreferences = editableFontPreferences; ((FontPreferencesImpl)fontPreferences).addChangeListene... | ensureEditableFontPreferences |
264,829 | FontPreferences () { AppConsoleFontOptions consoleFontOptions = AppConsoleFontOptions.getInstance(); return consoleFontOptions.isUseEditorFont() ? consoleFontPreferences : consoleFontOptions.getFontPreferences(); } | getConsoleFontPreferences |
264,830 | void (@NotNull FontPreferences preferences) { preferences.copyTo(ensureEditableConsoleFontPreferences()); initFonts(); } | setConsoleFontPreferences |
264,831 | void () { consoleFontPreferences = new DelegatingFontPreferences(() -> fontPreferences); initFonts(); } | setUseEditorFontPreferencesInConsole |
264,832 | boolean () { return consoleFontPreferences instanceof DelegatingFontPreferences; } | isUseEditorFontPreferencesInConsole |
264,833 | void (String fontName) { ModifiableFontPreferences consolePreferences = ensureEditableConsoleFontPreferences(); float consoleFontSize = getConsoleFontSize2D(); consolePreferences.clear(); consolePreferences.register(fontName, consoleFontSize); } | setConsoleFontName |
264,834 | ModifiableFontPreferences () { if (!(consoleFontPreferences instanceof ModifiableFontPreferences)) { ModifiableFontPreferences editableFontPreferences = new FontPreferencesImpl(); consoleFontPreferences.copyTo(editableFontPreferences); consoleFontPreferences = editableFontPreferences; } return (ModifiableFontPreference... | ensureEditableConsoleFontPreferences |
264,835 | int () { return (int)(getConsoleFontSize2D() + 0.5); } | getConsoleFontSize |
264,836 | void (int fontSize) { setConsoleFontSize((float)fontSize); } | setConsoleFontSize |
264,837 | void (float fontSize) { ModifiableFontPreferences consoleFontPreferences = ensureEditableConsoleFontPreferences(); fontSize = EditorFontsConstants.checkAndFixEditorFontSize(fontSize); consoleFontPreferences.register(getConsoleFontName(), fontSize); initFonts(); } | setConsoleFontSize |
264,838 | float () { String font = getConsoleFontName(); UISettings uiSettings = UISettings.getInstanceOrNull(); if ((uiSettings == null || !uiSettings.getPresentationMode()) && getConsoleFontPreferences().hasSize(font)) { return getConsoleFontPreferences().getSize2D(font); } return getEditorFontSize2D(); } | getConsoleFontSize2D |
264,839 | float () { return getConsoleFontPreferences().getLineSpacing(); } | getConsoleLineSpacing |
264,840 | void (float lineSpacing) { ensureEditableConsoleFontPreferences().setLineSpacing(lineSpacing); } | setConsoleLineSpacing |
264,841 | void (boolean value) { } | setSaveNeeded |
264,842 | Properties () { return metaInfo; } | getMetaProperties |
264,843 | boolean () { return canBeDeleted; } | canBeDeleted |
264,844 | void (boolean canBeDeleted) { this.canBeDeleted = canBeDeleted; } | setCanBeDeleted |
264,845 | EditorColorsScheme () { return parentScheme; } | getParentScheme |
264,846 | Element () { Element root = new Element("scheme"); writeExternal(root); return root; } | writeScheme |
264,847 | boolean (Object other) { return settingsEqual(other, null); } | settingsEqual |
264,848 | boolean (Object other, @Nullable Predicate<? super ColorKey> colorKeyFilter) { if (!(other instanceof AbstractColorsScheme otherScheme)) { return false; } // parent is used only for default schemes (e.g., Darcula bundled in all IDEs (opposite to IDE-specific, like Cobalt)) if (getBaseDefaultScheme(this) != getBaseDefau... | settingsEqual |
264,849 | boolean (AbstractColorsScheme otherScheme) { return attributesMap.equals(otherScheme.attributesMap); } | attributesEqual |
264,850 | boolean (AbstractColorsScheme otherScheme, @Nullable Predicate<? super ColorKey> colorKeyFilter) { if (colorMap.size() != otherScheme.colorMap.size()) return false; for (Map.Entry<ColorKey, Color> entry : colorMap.entrySet()) { Color c1 = entry.getValue(); ColorKey key = entry.getKey(); Color c2 = otherScheme.colorMap.... | colorsEqual |
264,851 | void (@NotNull EditorColorsScheme newParent) { assert newParent.isReadOnly() : "New parent scheme must be read-only"; parentScheme = newParent; } | setParent |
264,852 | EditorColorsScheme (@NotNull String name) { DefaultColorSchemesManager manager = DefaultColorSchemesManager.getInstance(); EditorColorsScheme defaultScheme = manager.getScheme(name); if (defaultScheme == null) { defaultScheme = new TemporaryParent(name); } return defaultScheme; } | getDefaultScheme |
264,853 | void (Element parentNode, FontPreferences preferences, String optionName) { if (preferences.useLigatures()) { JdomKt.addOptionTag(parentNode, optionName, String.valueOf(true)); } } | writeLigaturesPreferences |
264,854 | void (@NotNull String key, @NotNull Element parent, @NotNull FontPreferences preferences) { for (String fontFamily : preferences.getRealFontFamilies()) { Element element = new Element(key); JdomKt.addOptionTag(element, EDITOR_FONT_NAME, fontFamily); // Write font size as integer for compatibility JdomKt.addOptionTag(el... | writeFontPreferences |
264,855 | boolean (@NotNull EditorColorsScheme scheme, @NotNull TextAttributesKey key) { TextAttributes directAttrs = scheme instanceof DefaultColorsScheme ? ((DefaultColorsScheme)scheme).getDirectlyDefinedAttributes(key) : null; return directAttrs != null && directAttrs != INHERITED_ATTRS_MARKER; } | hasExplicitlyDefinedAttributes |
264,856 | boolean (@NotNull EditorColorsScheme scheme, @NotNull ColorKey key) { Color directColor = scheme instanceof DefaultColorsScheme ? ((DefaultColorsScheme)scheme).getDirectlyDefinedColor(key) : null; return directColor != null && directColor != INHERITED_COLOR_MARKER; } | hasExplicitlyDefinedColors |
264,857 | boolean (@Nullable Color c1, @Nullable Color c2) { if (c1 == NULL_COLOR_MARKER) return c1 == c2; return Comparing.equal(c1, c2 == NULL_COLOR_MARKER ? null : c2); } | colorsEqual |
264,858 | boolean (@NotNull EditorColorsScheme scheme) { return !(scheme instanceof AbstractColorsScheme) || ((AbstractColorsScheme)scheme).isVisible(); } | isVisible |
264,859 | boolean (@NotNull FontPreferences preferences1, @NotNull FontPreferences preferences2) { boolean isDelegating1 = preferences1 instanceof DelegatingFontPreferences; boolean isDelegating2 = preferences2 instanceof DelegatingFontPreferences; return isDelegating1 || isDelegating2 ? isDelegating1 && isDelegating2 : preferen... | areDelegatingOrEqual |
264,860 | EffectType (TextAttributesReader reader, Element element) { Effect effect = reader.readChild(Effect.class, element, EFFECT_TYPE); return effect != null ? effect.myType : EffectType.BOXED; } | read |
264,861 | int (TextAttributesReader reader, Element element) { FontStyle style = reader.readChild(FontStyle.class, element, FONT_TYPE); return style != null ? style.myStyle : Font.PLAIN; } | read |
264,862 | Font (@Nullable EditorFontType key) { synchronized (fonts) { if (fonts.isEmpty()) { initFonts(); } EditorFontType fontType = Objects.requireNonNullElse(key, EditorFontType.PLAIN); Font font = fonts.get(fontType); assert font != null : "Font " + fontType + " not found."; UISettings uiSettings = UISettings.getInstance();... | getFont |
264,863 | void () { synchronized (fonts) { fonts.clear(); } } | reset |
264,864 | EditorColorsScheme () { return EditorColorsManager.getInstance().getGlobalScheme(); } | getFontCacheScheme |
264,865 | void () { EditorColorsScheme scheme = getFontCacheScheme(); FontPreferences preferences = scheme.getFontPreferences(); String editorFontName = preferences.getFontFamily(); float editorFontSize = scheme.getEditorFontSize2D(); String fallbackName = getFallbackName(editorFontName); if (fallbackName != null) { editorFontNa... | initFonts |
264,866 | void (EditorFontType fontType, String familyName, int style, float fontSize, FontPreferences fontPreferences) { Font baseFont = FontFamilyService.getFont(familyName, fontPreferences.getRegularSubFamily(), fontPreferences.getBoldSubFamily(), style, fontSize); fonts.put(fontType, deriveFontWithLigatures(baseFont, fontPre... | setFont |
264,867 | Font (@NotNull Font font, boolean enableLigatures) { return enableLigatures ? font.deriveFont(LIGATURES_ATTRIBUTES) : font; } | deriveFontWithLigatures |
264,868 | void (String attribute) { myAttribute = Strings.isEmpty(attribute) ? null : attribute; } | setAttribute |
264,869 | Color (@NotNull String value) { try { if (value.length() >= 6) { return ColorHexUtil.fromHex(value); } LOG.debug("short color value: ", value); } catch (Exception exception) { LOG.debug("wrong color value: ", value); } if (!StringUtil.isHexDigit(value.charAt(0))) { return null; } int rgb; try { rgb = Integer.parseInt(v... | toColor |
264,870 | PersistentFontPreferences (@NotNull FontPreferences fontPreferences) { return new PersistentFontPreferences(fontPreferences); } | createFontState |
264,871 | AppEditorFontOptions () { return ApplicationManager.getApplication().getService(AppEditorFontOptions.class); } | getInstance |
264,872 | PersistentFontPreferences () { PersistentFontPreferences preferences = new PersistentFontPreferences(); preferences.VERSION = CURR_FONT_PREF_VERSION; return preferences; } | getDefaultState |
264,873 | void (@NotNull ChangeListener changeListener) { myEventDispatcher.addListener(changeListener); } | addChangeListener |
264,874 | void (@NotNull ChangeListener changeListener, @NotNull Disposable parentDisposable) { myEventDispatcher.addListener(changeListener, parentDisposable); } | addChangeListener |
264,875 | void () { myFontSizes.clear(); clearFonts(); } | clear |
264,876 | void () { myEffectiveFontFamilies.clear(); myRealFontFamilies.clear(); myUseLigatures = false; myRegularSubFamily = null; myBoldSubFamily = null; notifyStateChanged(); } | clearFonts |
264,877 | void () { myEventDispatcher.getMulticaster().stateChanged(new ChangeEvent(this)); } | notifyStateChanged |
264,878 | boolean (@NotNull String fontName) { return myFontSizes.containsKey(fontName); } | hasSize |
264,879 | float () { return myLineSpacing; } | getLineSpacing |
264,880 | void (float lineSpacing) { myLineSpacing = EditorFontsConstants.checkAndFixEditorLineSpacing(lineSpacing); } | setLineSpacing |
264,881 | int (@NotNull String fontFamily) { return (int)(getSize2D(fontFamily) + 0.5); } | getSize |
264,882 | float (@NotNull String fontFamily) { float result = myFontSizes.getFloat(fontFamily); if (result <= 0) { result = myTemplateFontSize; } return result > 0 ? result : DEFAULT_FONT_SIZE; } | getSize2D |
264,883 | void (@NotNull String fontFamily, int size) { setSize(fontFamily, (float)size); } | setSize |
264,884 | void (@NotNull String fontFamily, float size) { logSizeChangeIfNeeded(size); myFontSizes.put(fontFamily, size); myTemplateFontSize = size; notifyStateChanged(); } | setSize |
264,885 | void (float size) { if (!LOG.isDebugEnabled()) return; EditorColorsManager colorsManager = ApplicationManager.getApplication().getServiceIfCreated(EditorColorsManager.class); if (colorsManager == null || colorsManager.getGlobalScheme().getFontPreferences() != this) return; LOG.debug("Will set size %s to global font (pr... | logSizeChangeIfNeeded |
264,886 | void (@NotNull @NonNls String fontFamily, int size) { register(fontFamily, (float)size); } | register |
264,887 | void (@NotNull @NonNls String fontFamily, float size) { String fallbackFontFamily = AppEditorFontOptions.NEW_FONT_SELECTOR ? null : FontPreferences.getFallbackName(fontFamily, null); if (!myRealFontFamilies.contains(fontFamily)) { myRealFontFamilies.add(fontFamily); } String effectiveFontFamily = fallbackFontFamily == ... | register |
264,888 | void (@NotNull String fontFamily) { String fallbackFontFamily = AppEditorFontOptions.NEW_FONT_SELECTOR ? null : FontPreferences.getFallbackName(fontFamily, null); if (!myRealFontFamilies.contains(fontFamily)) { myRealFontFamilies.add(fontFamily); } String effectiveFontFamily = fallbackFontFamily == null ? fontFamily : ... | addFontFamily |
264,889 | void (final @NotNull FontPreferences preferences) { if (preferences instanceof ModifiableFontPreferences modifiablePreferences) { modifiablePreferences.setEffectiveFontFamilies(myEffectiveFontFamilies); modifiablePreferences.setRealFontFamilies(myRealFontFamilies); modifiablePreferences.setTemplateFontSize(myTemplateFo... | copyTo |
264,890 | void () { myFontSizes.clear(); } | resetFontSizes |
264,891 | void (@NotNull String fontFamily, int size) { setFontSize(fontFamily, (float)size); } | setFontSize |
264,892 | void (@NotNull String fontFamily, float size) { myFontSizes.put(fontFamily, size); } | setFontSize |
264,893 | void (int size) { setTemplateFontSize((float)size); } | setTemplateFontSize |
264,894 | void (float size) { myTemplateFontSize = size; } | setTemplateFontSize |
264,895 | void (@NotNull List<String> fontFamilies) { myEffectiveFontFamilies.clear(); myEffectiveFontFamilies.addAll(fontFamilies); } | setEffectiveFontFamilies |
264,896 | void (@NotNull List<String> fontFamilies) { myRealFontFamilies.clear(); myRealFontFamilies.addAll(fontFamilies); } | setRealFontFamilies |
264,897 | int () { return myRealFontFamilies.hashCode(); } | hashCode |
264,898 | boolean (Object o) { if (this == o) return true; if (o == null || getClass() != o.getClass()) return false; FontPreferencesImpl that = (FontPreferencesImpl)o; if (!myRealFontFamilies.equals(that.myRealFontFamilies)) return false; for (String fontFamily : myRealFontFamilies) { if (myFontSizes.getFloat(fontFamily) != tha... | equals |
264,899 | boolean () { return myUseLigatures; } | useLigatures |
Subsets and Splits
No community queries yet
The top public SQL queries from the community will appear here once available.