diff --git a/CHANGELOG.md b/CHANGELOG.md index 5db359e0..036cc0ee 100644 --- a/CHANGELOG.md +++ b/CHANGELOG.md @@ -5,6 +5,10 @@ FlatLaf Change Log #### New features and improvements +- Button: Disabled `Button.defaultButtonFollowsFocus` on Windows (as on other + platforms). If you like to keep the old behavior in your application, use: + `if(SystemInfo.isWindows) + UIManager.put("Button.defaultButtonFollowsFocus",true);`. - ComboBox, Spinner and SplitPaneDivider: Added pressed feedback to arrow buttons. - TextComponent: Clip placeholder text if it does not fit into visible area. (PR diff --git a/flatlaf-core/src/main/resources/com/formdev/flatlaf/FlatLaf.properties b/flatlaf-core/src/main/resources/com/formdev/flatlaf/FlatLaf.properties index c8a34016..9d39f7cb 100644 --- a/flatlaf-core/src/main/resources/com/formdev/flatlaf/FlatLaf.properties +++ b/flatlaf-core/src/main/resources/com/formdev/flatlaf/FlatLaf.properties @@ -149,7 +149,6 @@ Button.margin = 2,14,2,14 Button.iconTextGap = 4 Button.rollover = true Button.defaultButtonFollowsFocus = false -[win]Button.defaultButtonFollowsFocus = true Button.borderWidth = 1 Button.default.borderWidth = 1 diff --git a/flatlaf-testing/dumps/uidefaults/FlatDarkLaf_1.8.0_202-linux.txt b/flatlaf-testing/dumps/uidefaults/FlatDarkLaf_1.8.0_202-linux.txt index 53feaf64..1b47b2a5 100644 --- a/flatlaf-testing/dumps/uidefaults/FlatDarkLaf_1.8.0_202-linux.txt +++ b/flatlaf-testing/dumps/uidefaults/FlatDarkLaf_1.8.0_202-linux.txt @@ -1,9 +1,6 @@ - OS Windows 10 + OS Linux -- Button.defaultButtonFollowsFocus true -+ Button.defaultButtonFollowsFocus false - - ProgressBar.font [active] Segoe UI plain 10 javax.swing.plaf.FontUIResource [UI] + ProgressBar.font [active] Cantarell plain 13 javax.swing.plaf.FontUIResource [UI] diff --git a/flatlaf-testing/dumps/uidefaults/FlatDarkLaf_1.8.0_202-mac.txt b/flatlaf-testing/dumps/uidefaults/FlatDarkLaf_1.8.0_202-mac.txt index 7a4016df..ca6fa9ba 100644 --- a/flatlaf-testing/dumps/uidefaults/FlatDarkLaf_1.8.0_202-mac.txt +++ b/flatlaf-testing/dumps/uidefaults/FlatDarkLaf_1.8.0_202-mac.txt @@ -1,9 +1,6 @@ - OS Windows 10 + OS Mac OS X -- Button.defaultButtonFollowsFocus true -+ Button.defaultButtonFollowsFocus false - + ComboBox.showPopupOnNavigation true - Menu.shortcutKeys length=1 [I diff --git a/flatlaf-testing/dumps/uidefaults/FlatDarkLaf_1.8.0_202.txt b/flatlaf-testing/dumps/uidefaults/FlatDarkLaf_1.8.0_202.txt index 78de0a0a..2e591abb 100644 --- a/flatlaf-testing/dumps/uidefaults/FlatDarkLaf_1.8.0_202.txt +++ b/flatlaf-testing/dumps/uidefaults/FlatDarkLaf_1.8.0_202.txt @@ -77,7 +77,7 @@ Button.default.foreground #bbbbbb javax.swing.plaf.ColorUIResource [UI] Button.default.hoverBackground #3b5f8b com.formdev.flatlaf.util.DerivedColor [UI] lighten(3% autoInverse) Button.default.hoverBorderColor #537699 javax.swing.plaf.ColorUIResource [UI] Button.default.pressedBackground #3f6796 com.formdev.flatlaf.util.DerivedColor [UI] lighten(6% autoInverse) -Button.defaultButtonFollowsFocus true +Button.defaultButtonFollowsFocus false Button.disabledBackground #3c3f41 javax.swing.plaf.ColorUIResource [UI] Button.disabledBorderColor #5e6060 javax.swing.plaf.ColorUIResource [UI] Button.disabledSelectedBackground #53585a com.formdev.flatlaf.util.DerivedColor [UI] lighten(3% autoInverse) diff --git a/flatlaf-testing/dumps/uidefaults/FlatLightLaf_1.8.0_202-linux.txt b/flatlaf-testing/dumps/uidefaults/FlatLightLaf_1.8.0_202-linux.txt index 53feaf64..1b47b2a5 100644 --- a/flatlaf-testing/dumps/uidefaults/FlatLightLaf_1.8.0_202-linux.txt +++ b/flatlaf-testing/dumps/uidefaults/FlatLightLaf_1.8.0_202-linux.txt @@ -1,9 +1,6 @@ - OS Windows 10 + OS Linux -- Button.defaultButtonFollowsFocus true -+ Button.defaultButtonFollowsFocus false - - ProgressBar.font [active] Segoe UI plain 10 javax.swing.plaf.FontUIResource [UI] + ProgressBar.font [active] Cantarell plain 13 javax.swing.plaf.FontUIResource [UI] diff --git a/flatlaf-testing/dumps/uidefaults/FlatLightLaf_1.8.0_202-mac.txt b/flatlaf-testing/dumps/uidefaults/FlatLightLaf_1.8.0_202-mac.txt index 7a4016df..ca6fa9ba 100644 --- a/flatlaf-testing/dumps/uidefaults/FlatLightLaf_1.8.0_202-mac.txt +++ b/flatlaf-testing/dumps/uidefaults/FlatLightLaf_1.8.0_202-mac.txt @@ -1,9 +1,6 @@ - OS Windows 10 + OS Mac OS X -- Button.defaultButtonFollowsFocus true -+ Button.defaultButtonFollowsFocus false - + ComboBox.showPopupOnNavigation true - Menu.shortcutKeys length=1 [I diff --git a/flatlaf-testing/dumps/uidefaults/FlatLightLaf_1.8.0_202.txt b/flatlaf-testing/dumps/uidefaults/FlatLightLaf_1.8.0_202.txt index 8128c677..cddf7339 100644 --- a/flatlaf-testing/dumps/uidefaults/FlatLightLaf_1.8.0_202.txt +++ b/flatlaf-testing/dumps/uidefaults/FlatLightLaf_1.8.0_202.txt @@ -77,7 +77,7 @@ Button.default.foreground #000000 javax.swing.plaf.ColorUIResource [UI] Button.default.hoverBackground #f7f7f7 com.formdev.flatlaf.util.DerivedColor [UI] darken(3% autoInverse) Button.default.hoverBorderColor #87afda javax.swing.plaf.ColorUIResource [UI] Button.default.pressedBackground #e6e6e6 com.formdev.flatlaf.util.DerivedColor [UI] darken(10% autoInverse) -Button.defaultButtonFollowsFocus true +Button.defaultButtonFollowsFocus false Button.disabledBackground #f2f2f2 javax.swing.plaf.ColorUIResource [UI] Button.disabledBorderColor #cfcfcf javax.swing.plaf.ColorUIResource [UI] Button.disabledSelectedBackground #dedede com.formdev.flatlaf.util.DerivedColor [UI] darken(13% autoInverse) diff --git a/flatlaf-testing/dumps/uidefaults/FlatTestLaf_1.8.0_202.txt b/flatlaf-testing/dumps/uidefaults/FlatTestLaf_1.8.0_202.txt index 616bd940..374023a0 100644 --- a/flatlaf-testing/dumps/uidefaults/FlatTestLaf_1.8.0_202.txt +++ b/flatlaf-testing/dumps/uidefaults/FlatTestLaf_1.8.0_202.txt @@ -78,7 +78,7 @@ Button.default.hoverBorderColor #ff0000 javax.swing.plaf.ColorUIResource [UI] Button.default.pressedBackground #ffc800 javax.swing.plaf.ColorUIResource [UI] Button.default.startBackground #dddddd javax.swing.plaf.ColorUIResource [UI] Button.default.startBorderColor #ff0000 javax.swing.plaf.ColorUIResource [UI] -Button.defaultButtonFollowsFocus true +Button.defaultButtonFollowsFocus false Button.disabledBackground #e0e0e0 javax.swing.plaf.ColorUIResource [UI] Button.disabledBorderColor #000088 javax.swing.plaf.ColorUIResource [UI] Button.disabledText #000088 javax.swing.plaf.ColorUIResource [UI]