mirror of
https://gitflic.ru/project/openide/openide.git
synced 2026-09-27 10:03:11 +07:00
fix unfocused foreground on Nimbus
This commit is contained in:
@@ -142,7 +142,7 @@ public abstract class ColoredTreeCellRenderer extends SimpleColoredComponent imp
|
||||
* It guaranties readability of selected text in any LAF.
|
||||
*/
|
||||
public void append(@NotNull @Nls String fragment, @NotNull SimpleTextAttributes attributes, boolean isMainText) {
|
||||
if (mySelected && (myFocused || UIUtil.isUnderNimbusLookAndFeel())) {
|
||||
if (mySelected && myFocused) {
|
||||
super.append(fragment, new SimpleTextAttributes(attributes.getStyle(), UIUtil.getTreeSelectionForeground()), isMainText);
|
||||
}
|
||||
else if (mySelected && UIUtil.isUnderAquaBasedLookAndFeel()) {
|
||||
|
||||
@@ -947,7 +947,7 @@ public class UIUtil {
|
||||
}
|
||||
|
||||
public static boolean isFullRowSelectionLAF() {
|
||||
return isUnderNimbusLookAndFeel() || isUnderQuaquaLookAndFeel();
|
||||
return isUnderQuaquaLookAndFeel();
|
||||
}
|
||||
|
||||
public static boolean isUnderNativeMacLookAndFeel() {
|
||||
|
||||
@@ -42,10 +42,10 @@ public class WideSelectionTreeUI extends BasicTreeUI {
|
||||
|
||||
private static final Icon TREE_COLLAPSED_ICON = UIUtil.getTreeCollapsedIcon();
|
||||
private static final Icon TREE_EXPANDED_ICON = UIUtil.getTreeExpandedIcon();
|
||||
private static final Icon TREE_SELECTED_COLLAPSED_ICON = UIUtil.isUnderAquaBasedLookAndFeel() ? AllIcons.Mac.Tree_white_right_arrow
|
||||
: TREE_COLLAPSED_ICON;
|
||||
private static final Icon TREE_SELECTED_EXPANDED_ICON = UIUtil.isUnderAquaBasedLookAndFeel() ? AllIcons.Mac.Tree_white_down_arrow
|
||||
: TREE_EXPANDED_ICON;
|
||||
private static final Icon TREE_SELECTED_COLLAPSED_ICON = UIUtil.isUnderAquaBasedLookAndFeel() || UIUtil.isUnderNimbusLookAndFeel()
|
||||
? AllIcons.Mac.Tree_white_right_arrow : TREE_COLLAPSED_ICON;
|
||||
private static final Icon TREE_SELECTED_EXPANDED_ICON = UIUtil.isUnderAquaBasedLookAndFeel() || UIUtil.isUnderNimbusLookAndFeel()
|
||||
? AllIcons.Mac.Tree_white_down_arrow : TREE_EXPANDED_ICON;
|
||||
|
||||
private static final Border LIST_BACKGROUND_PAINTER = (Border)UIManager.get("List.sourceListBackgroundPainter");
|
||||
private static final Border LIST_SELECTION_BACKGROUND_PAINTER = (Border)UIManager.get("List.sourceListSelectionBackgroundPainter");
|
||||
|
||||
Reference in New Issue
Block a user