mirror of
https://gitflic.ru/project/openide/openide.git
synced 2026-09-27 10:03:11 +07:00
correct fonts in Ctrl-N-like dialogs
This commit is contained in:
@@ -36,6 +36,8 @@ import com.intellij.ide.ui.UISettings;
|
||||
import com.intellij.ide.util.treeView.NodeRenderer;
|
||||
import com.intellij.navigation.ItemPresentation;
|
||||
import com.intellij.navigation.NavigationItem;
|
||||
import com.intellij.openapi.editor.colors.EditorColorsManager;
|
||||
import com.intellij.openapi.editor.colors.EditorColorsScheme;
|
||||
import com.intellij.openapi.editor.markup.TextAttributes;
|
||||
import com.intellij.openapi.vcs.FileStatus;
|
||||
import com.intellij.ui.ColoredListCellRenderer;
|
||||
@@ -56,6 +58,9 @@ public class NavigationItemListCellRenderer extends JPanel implements ListCellRe
|
||||
int index,
|
||||
boolean isSelected,
|
||||
boolean cellHasFocus) {
|
||||
EditorColorsScheme scheme = EditorColorsManager.getInstance().getGlobalScheme();
|
||||
Font editorFont = new Font(scheme.getEditorFontName(), Font.PLAIN, scheme.getEditorFontSize());
|
||||
setFont(editorFont);
|
||||
removeAll();
|
||||
final Component leftCellRendererComponent =
|
||||
new LeftRenderer().getListCellRendererComponent(list, value, index, isSelected, cellHasFocus);
|
||||
|
||||
@@ -85,7 +85,6 @@ public class PsiElementModuleRenderer extends DefaultListCellRenderer{
|
||||
setBorder(BorderFactory.createEmptyBorder(0, 0, 0, 2));
|
||||
setHorizontalTextPosition(SwingConstants.LEFT);
|
||||
setBackground(UIManager.getColor(selected ? "List.selectionBackground" : "List.background"));
|
||||
setFont(UIManager.getFont("List.font"));
|
||||
setForeground(selected ? UIManager.getColor("List.selectionForeground") : UIManager.getColor("textInactiveText"));
|
||||
}
|
||||
}
|
||||
|
||||
Reference in New Issue
Block a user