From f03725ae3622a6100be4e62d3b87d4727685f062 Mon Sep 17 00:00:00 2001 From: Karl Tauber Date: Fri, 4 Aug 2023 11:18:28 +0200 Subject: [PATCH] IntelliJ Themes: fixed ComboBox backgrounds in all "Material UI Lite" themes and in some other themes --- CHANGELOG.md | 9 +++++---- .../java/com/formdev/flatlaf/IntelliJTheme.java | 1 + .../flatlaf/IntelliJTheme$ThemeLaf.properties | 16 ++++++++++++++++ 3 files changed, 22 insertions(+), 4 deletions(-) diff --git a/CHANGELOG.md b/CHANGELOG.md index e69a9158..a7921e3d 100644 --- a/CHANGELOG.md +++ b/CHANGELOG.md @@ -34,16 +34,17 @@ FlatLaf Change Log - "Monocai" theme: Fixed unreadable text color of default buttons. (issue #693) - "Vuesion" theme: Fixed foreground colors of disabled text. + - "Material UI Lite" themes: Fixed non-editable ComboBox button background. - CheckBox and RadioButton: Fixed unselected icon colors for themes "Atom One Light", "Cyan Light", "GitHub", "Light Owl", "Material Lighter" and "Solarized Light". - TabbedPane: Fixed focused tab background color for themes "Arc *", "Material Design Dark", "Monocai", "One Dark", "Spacegray" and "Xcode-Dark". (issue #697) - - TextComponents: Fixed background colors of enabled text components, to - distinguish from disabled, for themes "Carbon", "Cobalt 2", "Gradianto *", - "Gruvbox *", "Monocai", "Spacegray", "Vuesion", "Xcode-Dark", "GitHub", and - "Light Owl". (issue #528) + - TextComponents, ComboBox and Spinner: Fixed background colors of enabled + text components, to distinguish from disabled, for themes "Carbon", "Cobalt + 2", "Gradianto *", "Gruvbox *", "Monocai", "Spacegray", "Vuesion", + "Xcode-Dark", "GitHub", and "Light Owl". (issue #528) - Native Windows libraries: Fixed crash when running in Java 8 and newer Java version is installed in `PATH` environment variable and using class `SystemInfo` before AWT initialization. (issue #673) diff --git a/flatlaf-core/src/main/java/com/formdev/flatlaf/IntelliJTheme.java b/flatlaf-core/src/main/java/com/formdev/flatlaf/IntelliJTheme.java index bc7c4c15..cf67a6f9 100644 --- a/flatlaf-core/src/main/java/com/formdev/flatlaf/IntelliJTheme.java +++ b/flatlaf-core/src/main/java/com/formdev/flatlaf/IntelliJTheme.java @@ -673,6 +673,7 @@ public class IntelliJTheme // ComboBox uiKeyMapping.put( "ComboBox.background", "" ); // ignore + uiKeyMapping.put( "ComboBox.buttonBackground", "" ); // ignore uiKeyMapping.put( "ComboBox.nonEditableBackground", "ComboBox.background" ); uiKeyMapping.put( "ComboBox.ArrowButton.background", "ComboBox.buttonEditableBackground" ); uiKeyMapping.put( "ComboBox.ArrowButton.disabledIconColor", "ComboBox.buttonDisabledArrowColor" ); diff --git a/flatlaf-core/src/main/resources/com/formdev/flatlaf/IntelliJTheme$ThemeLaf.properties b/flatlaf-core/src/main/resources/com/formdev/flatlaf/IntelliJTheme$ThemeLaf.properties index ef405637..a095a001 100644 --- a/flatlaf-core/src/main/resources/com/formdev/flatlaf/IntelliJTheme$ThemeLaf.properties +++ b/flatlaf-core/src/main/resources/com/formdev/flatlaf/IntelliJTheme$ThemeLaf.properties @@ -152,6 +152,8 @@ ToggleButton.endBackground = $ToggleButton.background [Cobalt_2]CheckBox.icon.checkmarkColor = #002946 [Cobalt_2]MenuItem.checkBackground = @ijMenuCheckBackgroundL10 [Cobalt_2]MenuItem.underlineSelectionCheckBackground = @ijMenuCheckBackgroundL10 +[Cobalt_2]ComboBox.background = @ijTextBackgroundL3 +[Cobalt_2]ComboBox.buttonBackground = @ijTextBackgroundL3 [Cobalt_2]TextField.background = @ijTextBackgroundL3 [Cyan_light]MenuItem.checkBackground = @ijMenuCheckBackgroundL20 @@ -180,11 +182,15 @@ ToggleButton.endBackground = $ToggleButton.background [Gruvbox_Dark_Hard]Component.accentColor = lazy(TabbedPane.underlineColor) [Gruvbox_Dark_Hard]ToggleButton.selectedBackground = $ToggleButton.selectedBackground [Gruvbox_Dark_Hard]ToggleButton.toolbar.selectedBackground = $ToggleButton.toolbar.selectedBackground +[Gruvbox_Dark_Hard]ComboBox.background = @ijTextBackgroundL3 +[Gruvbox_Dark_Hard]ComboBox.buttonBackground = @ijTextBackgroundL3 [Gruvbox_Dark_Hard]TextField.background = @ijTextBackgroundL3 [Gruvbox_Dark_Medium]Component.accentColor = lazy(TabbedPane.underlineColor) [Gruvbox_Dark_Medium]ToggleButton.selectedBackground = $ToggleButton.selectedBackground [Gruvbox_Dark_Medium]ToggleButton.toolbar.selectedBackground = $ToggleButton.toolbar.selectedBackground +[Gruvbox_Dark_Medium]ComboBox.background = @ijTextBackgroundL3 +[Gruvbox_Dark_Medium]ComboBox.buttonBackground = @ijTextBackgroundL3 [Gruvbox_Dark_Medium]TextField.background = @ijTextBackgroundL3 [Gruvbox_Dark_Soft]Component.accentColor = lazy(TabbedPane.underlineColor) @@ -192,6 +198,8 @@ ToggleButton.endBackground = $ToggleButton.background [Gruvbox_Dark_Soft]MenuItem.underlineSelectionCheckBackground = @ijMenuCheckBackgroundL10 [Gruvbox_Dark_Soft]ToggleButton.selectedBackground = $ToggleButton.selectedBackground [Gruvbox_Dark_Soft]ToggleButton.toolbar.selectedBackground = $ToggleButton.toolbar.selectedBackground +[Gruvbox_Dark_Soft]ComboBox.background = @ijTextBackgroundL3 +[Gruvbox_Dark_Soft]ComboBox.buttonBackground = @ijTextBackgroundL3 [Gruvbox_Dark_Soft]TextField.background = @ijTextBackgroundL3 [Hiberbee_Dark]TabbedPane.focusColor = #5A5A5A @@ -214,6 +222,8 @@ ToggleButton.endBackground = $ToggleButton.background [Light_Flat]CheckBox.icon[filled].background = #fff [Light_Flat]CheckBox.icon[filled].checkmarkColor = #fff [Light_Flat]Component.accentColor = lazy(TabbedPane.underlineColor) +[Light_Flat]ComboBox.background = lazy(ComboBox.editableBackground) +[Light_Flat]ComboBox.buttonBackground = lazy(ComboBox.editableBackground) [Light_Flat]TableHeader.background = #E5E5E9 [Monocai]Button.default.foreground = #2D2A2F @@ -239,11 +249,15 @@ ToggleButton.endBackground = $ToggleButton.background [One_Dark]Slider.focusedColor = fade(#568af2,40%) [Solarized_Dark---4lex4]Component.accentColor = lazy(TabbedPane.underlineColor) +[Solarized_Dark---4lex4]ComboBox.background = lazy(ComboBox.editableBackground) +[Solarized_Dark---4lex4]ComboBox.buttonBackground = lazy(ComboBox.editableBackground) [Solarized_Dark---4lex4]Slider.focusedColor = fade($Component.focusColor,80%,derived) [Solarized_Light---4lex4]Button.default.hoverBackground = darken($Button.default.background,3%,derived) [Solarized_Light---4lex4]Component.accentColor = lazy(TabbedPane.underlineColor) +[Spacegray]ComboBox.background = @ijTextBackgroundL4 +[Spacegray]ComboBox.buttonBackground = @ijTextBackgroundL4 [Spacegray]TextField.background = @ijTextBackgroundL4 [vuesion-theme]*.disabledForeground = #8C8C8C @@ -256,6 +270,8 @@ ToggleButton.endBackground = $ToggleButton.background [vuesion-theme]Slider.trackColor = #303a45 [vuesion-theme]Slider.thumbColor = #ececee [vuesion-theme]Slider.focusedColor = fade(#ececee,20%) +[vuesion-theme]ComboBox.background = @ijTextBackgroundL4 +[vuesion-theme]ComboBox.buttonBackground = @ijTextBackgroundL4 [vuesion-theme]TextField.background = @ijTextBackgroundL4 [Xcode-Dark]TextField.background = @ijTextBackgroundL4