From 2134c19c5830b03c7385076659f68bff382ed499 Mon Sep 17 00:00:00 2001 From: Karl Tauber Date: Mon, 2 Jan 2023 18:58:18 +0100 Subject: [PATCH] IntelliJ Themes: avoid that accent color affect some colors in some IntelliJ themes (issue #625) --- CHANGELOG.md | 7 +++++-- .../com/formdev/flatlaf/IntelliJTheme$ThemeLaf.properties | 6 ++++++ .../formdev/flatlaf/testing/uidefaults/UIDefaultsDump.java | 6 ++++++ 3 files changed, 17 insertions(+), 2 deletions(-) diff --git a/CHANGELOG.md b/CHANGELOG.md index ece1592f..510bcc6a 100644 --- a/CHANGELOG.md +++ b/CHANGELOG.md @@ -5,8 +5,11 @@ FlatLaf Change Log #### Fixed bugs -- IntelliJ Themes: Fixed default button hover background in "Solarized Light" - theme. (issue #628) +- IntelliJ Themes: + - Fixed default button hover background in "Solarized Light" theme. (issue + #628) + - Avoid that accent color affect some colors in some IntelliJ themes. (issue + #625) ## 3.0 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 45a9051a..0ef49018 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 @@ -44,6 +44,12 @@ info = lazy(ToolTip.background) infoText = lazy(ToolTip.foreground) +#---- variables ---- + +# make sure that accent color (set via FlatLaf.setSystemColorGetter()) is ignored +@accentColor = null + + #---- Button ---- Button.startBackground = $Button.background diff --git a/flatlaf-testing/src/main/java/com/formdev/flatlaf/testing/uidefaults/UIDefaultsDump.java b/flatlaf-testing/src/main/java/com/formdev/flatlaf/testing/uidefaults/UIDefaultsDump.java index 2b3c6a51..9669aed9 100644 --- a/flatlaf-testing/src/main/java/com/formdev/flatlaf/testing/uidefaults/UIDefaultsDump.java +++ b/flatlaf-testing/src/main/java/com/formdev/flatlaf/testing/uidefaults/UIDefaultsDump.java @@ -134,6 +134,12 @@ public class UIDefaultsDump // ex.printStackTrace(); // } + // used to test whether system color influences IntelliJ themes + // (first run without this, save result, run with this and compare outputs) +// FlatLaf.setSystemColorGetter( name -> { +// return Color.red; +// } ); + // dumpIntelliJThemes( dir ); // JIDE