當前位置: 首頁>>代碼示例>>Java>>正文


Java SyntaxHighlighterBase類代碼示例

本文整理匯總了Java中com.intellij.openapi.fileTypes.SyntaxHighlighterBase的典型用法代碼示例。如果您正苦於以下問題:Java SyntaxHighlighterBase類的具體用法?Java SyntaxHighlighterBase怎麽用?Java SyntaxHighlighterBase使用的例子?那麽, 這裏精選的類代碼示例或許可以為您提供幫助。


SyntaxHighlighterBase類屬於com.intellij.openapi.fileTypes包,在下文中一共展示了SyntaxHighlighterBase類的10個代碼示例,這些例子默認根據受歡迎程度排序。您可以為喜歡或者感覺有用的代碼點讚,您的評價將有助於係統推薦出更棒的Java代碼示例。

示例1: getTokenHighlights

import com.intellij.openapi.fileTypes.SyntaxHighlighterBase; //導入依賴的package包/類
@NotNull
@Override
public TextAttributesKey[] getTokenHighlights(IElementType tokenType) {
    TextAttributesKey[] defaultTextAttributeKeys, extendedHighlighterKeys;

    defaultTextAttributeKeys = super.getTokenHighlights(tokenType);
    extendedHighlighterKeys = SyntaxHighlighterBase.pack(keys1.get(tokenType), keys2.get(tokenType));

    int numKeys = defaultTextAttributeKeys.length + extendedHighlighterKeys.length;
    TextAttributesKey[] merged = new TextAttributesKey[numKeys];

    System.arraycopy(defaultTextAttributeKeys, 0, merged, 0, defaultTextAttributeKeys.length);
    System.arraycopy(extendedHighlighterKeys,
            0, merged,
            defaultTextAttributeKeys.length,
            extendedHighlighterKeys.length);

    return merged;
}
 
開發者ID:christoffer,項目名稱:pycharm-pyxl,代碼行數:20,代碼來源:PyxlHighlighter.java

示例2: getAttributes

import com.intellij.openapi.fileTypes.SyntaxHighlighterBase; //導入依賴的package包/類
public TextAttributes getAttributes(IElementType tokenType) {
  TextAttributes attrs = myAttributesMap.get(tokenType);
  if (attrs == null) {
    attrs = convertAttributes(SyntaxHighlighterBase.pack(myBackground, mySyntaxHighlighter.getTokenHighlights(tokenType)));
    myAttributesMap.put(tokenType, attrs);
  }
  return attrs;
}
 
開發者ID:jskierbi,項目名稱:intellij-ce-playground,代碼行數:9,代碼來源:LayeredLexerEditorHighlighter.java

示例3: getTokenHighlights

import com.intellij.openapi.fileTypes.SyntaxHighlighterBase; //導入依賴的package包/類
@Override
@NotNull
public TextAttributesKey[] getTokenHighlights(IElementType tokenType) {
    return SyntaxHighlighterBase.pack(XmlHighlighterColors.HTML_CODE, keys1.get(tokenType));
}
 
開發者ID:LichFaker,項目名稱:RtplPlugin,代碼行數:6,代碼來源:RtplSyntaxHighlighter.java

示例4: getTokenHighlights

import com.intellij.openapi.fileTypes.SyntaxHighlighterBase; //導入依賴的package包/類
@NotNull
public TextAttributesKey[] getTokenHighlights(IElementType tokenType) {
  return SyntaxHighlighterBase.pack(ATTRIBUTES.get(tokenType));
}
 
開發者ID:jskierbi,項目名稱:intellij-ce-playground,代碼行數:5,代碼來源:RestSyntaxHighlighter.java

示例5: getTokenHighlights

import com.intellij.openapi.fileTypes.SyntaxHighlighterBase; //導入依賴的package包/類
@Override
@NotNull
public TextAttributesKey[] getTokenHighlights(IElementType tokenType) {
  return SyntaxHighlighterBase.pack(XmlHighlighterColors.HTML_CODE, pack(keys1.get(tokenType), keys2.get(tokenType)));
}
 
開發者ID:jskierbi,項目名稱:intellij-ce-playground,代碼行數:6,代碼來源:HtmlFileHighlighter.java

示例6: getTokenHighlights

import com.intellij.openapi.fileTypes.SyntaxHighlighterBase; //導入依賴的package包/類
@NotNull
public TextAttributesKey[] getTokenHighlights(IElementType tokenType) {
  return SyntaxHighlighterBase.pack(keys1.get(tokenType), keys2.get(tokenType));
}
 
開發者ID:jskierbi,項目名稱:intellij-ce-playground,代碼行數:5,代碼來源:PropertiesHighlighter.java

示例7: getTokenHighlights

import com.intellij.openapi.fileTypes.SyntaxHighlighterBase; //導入依賴的package包/類
@Nonnull
public TextAttributesKey[] getTokenHighlights(IElementType tokenType) {
  return SyntaxHighlighterBase.pack(keys1.get(tokenType), keys2.get(tokenType));
}
 
開發者ID:raydac,項目名稱:netbeans-mmd-plugin,代碼行數:5,代碼來源:MMHighlighter.java

示例8: getTokenHighlights

import com.intellij.openapi.fileTypes.SyntaxHighlighterBase; //導入依賴的package包/類
@NotNull
@Override
public TextAttributesKey[] getTokenHighlights(IElementType iElementType) {
    return SyntaxHighlighterBase.pack(keys1.get(iElementType), keys2.get(iElementType));
}
 
開發者ID:dubrousky,項目名稱:CMaker,代碼行數:6,代碼來源:CMakeHighlighter.java

示例9: getTokenHighlights

import com.intellij.openapi.fileTypes.SyntaxHighlighterBase; //導入依賴的package包/類
@Override
@NotNull
public TextAttributesKey[] getTokenHighlights(IElementType tokenType)
{
	return SyntaxHighlighterBase.pack(XmlHighlighterColors.HTML_CODE, pack(keys1.get(tokenType), keys2.get(tokenType)));
}
 
開發者ID:consulo,項目名稱:consulo-xml,代碼行數:7,代碼來源:HtmlFileHighlighter.java

示例10: getTokenHighlights

import com.intellij.openapi.fileTypes.SyntaxHighlighterBase; //導入依賴的package包/類
@NotNull
public TextAttributesKey[] getTokenHighlights(final IElementType tokenType)
{
	return SyntaxHighlighterBase.pack(ourMap.get(tokenType), VELOCITY_SCRIPTING_BACKGROUND);
}
 
開發者ID:consulo,項目名稱:consulo-apache-velocity,代碼行數:6,代碼來源:VtlSyntaxHighlighter.java


注:本文中的com.intellij.openapi.fileTypes.SyntaxHighlighterBase類示例由純淨天空整理自Github/MSDocs等開源代碼及文檔管理平台,相關代碼片段篩選自各路編程大神貢獻的開源項目,源碼版權歸原作者所有,傳播和使用請參考對應項目的License;未經允許,請勿轉載。