本文整理匯總了Java中com.intellij.ui.JBColor.black方法的典型用法代碼示例。如果您正苦於以下問題:Java JBColor.black方法的具體用法?Java JBColor.black怎麽用?Java JBColor.black使用的例子?那麽, 這裏精選的方法代碼示例或許可以為您提供幫助。您也可以進一步了解該方法所在類com.intellij.ui.JBColor
的用法示例。
在下文中一共展示了JBColor.black方法的4個代碼示例,這些例子默認根據受歡迎程度排序。您可以為喜歡或者感覺有用的代碼點讚,您的評價將有助於係統推薦出更棒的Java代碼示例。
示例1: lookAndFeelChanged
import com.intellij.ui.JBColor; //導入方法依賴的package包/類
@Override
public void lookAndFeelChanged(LafManager source) {
final Color background = UIUtil.isUnderDarcula()
? JBColor.background()
: JBColor.black;
inputTerminal.setBackground(background);
// TODO: Upstream fix for Kahlua
outputTerminal.setBackground(background);
// Find the panes we are looking for
JScrollPane scrollPane = (JScrollPane) outputTerminal.getComponent(0);
JPanel panel1 = (JPanel) scrollPane.getViewport().getView();
JPanel panel2 = (JPanel) panel1.getComponent(0);
// Set the background onto the panes directly
JPanel panel3 = (JPanel) panel2.getComponent(0);
panel3.setBackground(background);
JEditorPane editorPane = (JEditorPane) panel2.getComponent(1);
editorPane.setBackground(background);
}
示例2: addTransparencyIfNeeded
import com.intellij.ui.JBColor; //導入方法依賴的package包/類
public static SimpleTextAttributes addTransparencyIfNeeded(@NotNull final SimpleTextAttributes baseStyle, boolean isActive) {
if (isActive) return baseStyle;
Color color = baseStyle.getFgColor();
if (color == null) {
color = JBColor.black;
}
//noinspection UseJBColor
return new SimpleTextAttributes(baseStyle.getStyle(),
new Color(color.getRed(), color.getGreen(), color.getBlue(), 85));
}
示例3: getRecordTitleColor
import com.intellij.ui.JBColor; //導入方法依賴的package包/類
@Nullable
private Color getRecordTitleColor(@NotNull DiffChange change) {
TextDiffType type = getDiffType(change);
if (type == TextDiffType.INSERTED) return FileStatus.ADDED.getColor();
if (type == TextDiffType.DELETED) return FileStatus.DELETED.getColor();
if (type == TextDiffType.MODIFIED) return FileStatus.MODIFIED.getColor();
return JBColor.black; // unchanged
}
示例4: getOutlineColor
import com.intellij.ui.JBColor; //導入方法依賴的package包/類
@Override
public Color getOutlineColor(boolean isActive) {
ColorKey key = isActive ? EditorColors.SELECTED_TEARLINE_COLOR : EditorColors.TEARLINE_COLOR;
Color color = myEditor.getColorsScheme().getColor(key);
return color != null ? color : JBColor.black;
}