本文整理匯總了Java中com.intellij.openapi.editor.colors.TextAttributesKey.getExternalName方法的典型用法代碼示例。如果您正苦於以下問題:Java TextAttributesKey.getExternalName方法的具體用法?Java TextAttributesKey.getExternalName怎麽用?Java TextAttributesKey.getExternalName使用的例子?那麽, 這裏精選的方法代碼示例或許可以為您提供幫助。您也可以進一步了解該方法所在類com.intellij.openapi.editor.colors.TextAttributesKey
的用法示例。
在下文中一共展示了TextAttributesKey.getExternalName方法的3個代碼示例,這些例子默認根據受歡迎程度排序。您可以為喜歡或者感覺有用的代碼點讚,您的評價將有助於係統推薦出更棒的Java代碼示例。
示例1: SchemeTextAttributesDescription
import com.intellij.openapi.editor.colors.TextAttributesKey; //導入方法依賴的package包/類
private SchemeTextAttributesDescription(String name, String group, @NotNull TextAttributesKey key, @NotNull MyColorScheme scheme, Icon icon,
String toolTip) {
super(name, group,
getInitialAttributes(scheme, key).clone(),
key, scheme, icon, toolTip);
this.key = key;
myInitialAttributes = getInitialAttributes(scheme, key);
TextAttributesKey fallbackKey = key.getFallbackAttributeKey();
if (fallbackKey != null) {
myFallbackAttributes = scheme.getAttributes(fallbackKey);
myBaseAttributeDescriptor = ColorSettingsPages.getInstance().getAttributeDescriptor(fallbackKey);
if (myBaseAttributeDescriptor == null) {
myBaseAttributeDescriptor =
new Pair<ColorSettingsPage, AttributesDescriptor>(null, new AttributesDescriptor(fallbackKey.getExternalName(), fallbackKey));
}
}
myIsInheritedInitial = scheme.isInherited(key);
setInherited(myIsInheritedInitial);
if (myIsInheritedInitial) {
setInheritedAttributes(getTextAttributes());
}
initCheckedStatus();
}
示例2: TextAttributesDescription
import com.intellij.openapi.editor.colors.TextAttributesKey; //導入方法依賴的package包/類
public TextAttributesDescription(@NotNull String name,
String group,
TextAttributes attributes,
TextAttributesKey type,
EditorColorsScheme scheme, Icon icon, final String toolTip) {
super(name, group, type == null ? null : type.getExternalName(), scheme, icon, toolTip);
myAttributes = attributes;
initCheckedStatus();
}
示例3: createSuccessAnnotation
import com.intellij.openapi.editor.colors.TextAttributesKey; //導入方法依賴的package包/類
void createSuccessAnnotation(@NotNull PsiElement element, @NotNull AnnotationHolder holder, @NotNull TextAttributesKey key) {
holder.createInfoAnnotation(element, null).setEnforcedTextAttributes(TextAttributes.ERASE_MARKER);
String description = ApplicationManager.getApplication().isUnitTestMode() ? key.getExternalName() : null;
holder.createInfoAnnotation(element, description).setTextAttributes(key);
}