From 12ec0abf54c8be85ba32d9b009327660c9fd6b6a Mon Sep 17 00:00:00 2001 From: Karl Tauber Date: Sat, 12 Sep 2020 22:00:17 +0200 Subject: [PATCH] UI defaults: moved some common properties from FlatLightLaf.properties and FlatDarkLaf.properties to FlatLaf.properties --- .../com/formdev/flatlaf/FlatDarkLaf.properties | 18 ------------------ .../com/formdev/flatlaf/FlatLaf.properties | 10 ++++++++++ .../formdev/flatlaf/FlatLightLaf.properties | 18 ------------------ .../uidefaults/FlatTestLaf_1.8.0_202.txt | 1 + 4 files changed, 11 insertions(+), 36 deletions(-) diff --git a/flatlaf-core/src/main/resources/com/formdev/flatlaf/FlatDarkLaf.properties b/flatlaf-core/src/main/resources/com/formdev/flatlaf/FlatDarkLaf.properties index b07ff3b6..de84a20c 100644 --- a/flatlaf-core/src/main/resources/com/formdev/flatlaf/FlatDarkLaf.properties +++ b/flatlaf-core/src/main/resources/com/formdev/flatlaf/FlatDarkLaf.properties @@ -120,8 +120,6 @@ CheckBox.icon[filled].selectedPressedBackground=darken($CheckBox.icon[filled].se #---- ComboBox ---- -ComboBox.background=@textComponentBackground -ComboBox.buttonBackground=@textComponentBackground ComboBox.buttonEditableBackground=#404445 ComboBox.buttonArrowColor=#9A9DA1 ComboBox.buttonDisabledArrowColor=#585858 @@ -175,11 +173,6 @@ InternalFrame.activeDropShadowOpacity=0.5 InternalFrame.inactiveDropShadowOpacity=0.75 -#---- List ---- - -List.background=@textComponentBackground - - #---- Menu ---- Menu.icon.arrowColor=#A7A7A7 @@ -189,7 +182,6 @@ Menu.icon.disabledArrowColor=#606060 #---- MenuBar ---- MenuBar.borderColor=#515151 -MenuBar.hoverBackground=@menuHoverBackground #---- MenuItemCheckBox ---- @@ -222,11 +214,6 @@ ProgressBar.selectionForeground=@foreground ProgressBar.selectionBackground=@foreground -#---- RadioButton ---- - -RadioButton.icon[filled].centerDiameter=5 - - #---- RootPane ---- RootPane.activeBorderColor=darken(@background,7%,derived) @@ -266,7 +253,6 @@ SplitPaneDivider.oneTouchHoverArrowColor=#7A7D81 #---- TabbedPane ---- -TabbedPane.disabledForeground=@disabledText TabbedPane.underlineColor=#4A88C7 TabbedPane.disabledUnderlineColor=#7a7a7a TabbedPane.hoverColor=#2e3133 @@ -276,13 +262,11 @@ TabbedPane.contentAreaColor=#323232 #---- Table ---- -Table.background=@textComponentBackground Table.gridColor=lighten($Table.background,3%) #---- TableHeader ---- -TableHeader.background=@textComponentBackground TableHeader.separatorColor=lighten($TableHeader.background,10%) TableHeader.bottomSeparatorColor=$TableHeader.separatorColor @@ -297,7 +281,6 @@ TitlePane.buttonPressedBackground=lighten($TitlePane.background,20%,derived) #---- ToggleButton ---- ToggleButton.selectedBackground=lighten($ToggleButton.background,10%,derived) -ToggleButton.selectedForeground=@foreground ToggleButton.disabledSelectedBackground=lighten($ToggleButton.background,3%,derived) ToggleButton.toolbar.selectedBackground=lighten($ToggleButton.background,7%,derived) @@ -311,5 +294,4 @@ ToolTip.background=#1e2123 #---- Tree ---- -Tree.background=@textComponentBackground Tree.hash=#505355 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 5987d927..ead914d8 100644 --- a/flatlaf-core/src/main/resources/com/formdev/flatlaf/FlatLaf.properties +++ b/flatlaf-core/src/main/resources/com/formdev/flatlaf/FlatLaf.properties @@ -200,6 +200,8 @@ ComboBox.editorColumns=0 ComboBox.maximumRowCount=15 [mac]ComboBox.showPopupOnNavigation=true ComboBox.buttonStyle=auto +ComboBox.background=@textComponentBackground +ComboBox.buttonBackground=@textComponentBackground #---- Component ---- @@ -304,6 +306,7 @@ List.cellFocusColor=@cellFocusColor List.cellNoFocusBorder=com.formdev.flatlaf.ui.FlatListCellBorder$Default List.focusCellHighlightBorder=com.formdev.flatlaf.ui.FlatListCellBorder$Focused List.focusSelectedCellHighlightBorder=com.formdev.flatlaf.ui.FlatListCellBorder$Selected +List.background=@textComponentBackground List.selectionInactiveBackground=@selectionInactiveBackground List.selectionInactiveForeground=@selectionInactiveForeground List.dropCellBackground=@dropCellBackground @@ -329,6 +332,7 @@ Menu.background=@menuBackground MenuBar.border=com.formdev.flatlaf.ui.FlatMenuBarBorder MenuBar.background=@menuBackground +MenuBar.hoverBackground=@menuHoverBackground MenuBar.itemMargins=3,8,3,8 @@ -427,6 +431,7 @@ ProgressBar.repaintInterval=15 RadioButton.border=com.formdev.flatlaf.ui.FlatMarginBorder RadioButton.icon=com.formdev.flatlaf.icons.FlatRadioButtonIcon RadioButton.icon.centerDiameter=8 +RadioButton.icon[filled].centerDiameter=5 RadioButton.margin=2,2,2,2 RadioButton.iconTextGap=4 RadioButton.rollover=true @@ -538,6 +543,7 @@ TabbedPane.tabAreaInsets=0,0,0,0 TabbedPane.selectedTabPadInsets=0,0,0,0 TabbedPane.tabRunOverlay=0 TabbedPane.tabsOverlapBorder=true +TabbedPane.disabledForeground=@disabledText TabbedPane.shadow=@background TabbedPane.contentBorderInsets=null @@ -560,6 +566,7 @@ Table.focusCellHighlightBorder=com.formdev.flatlaf.ui.FlatTableCellBorder$Focuse Table.focusSelectedCellHighlightBorder=com.formdev.flatlaf.ui.FlatTableCellBorder$Selected Table.focusCellBackground=@textComponentBackground Table.focusCellForeground=@foreground +Table.background=@textComponentBackground Table.selectionInactiveBackground=@selectionInactiveBackground Table.selectionInactiveForeground=@selectionInactiveForeground Table.dropCellBackground=@dropCellBackground @@ -573,6 +580,7 @@ Table.dropLineShortColor=@dropLineShortColor TableHeader.height=25 TableHeader.cellBorder=2,3,2,3 TableHeader.focusCellBackground=$TableHeader.background +TableHeader.background=@textComponentBackground #---- TextArea ---- @@ -644,6 +652,7 @@ ToggleButton.rollover=true ToggleButton.background=$Button.background ToggleButton.pressedBackground=$Button.pressedBackground +ToggleButton.selectedForeground=@foreground ToggleButton.toolbar.hoverBackground=$Button.toolbar.hoverBackground ToggleButton.toolbar.pressedBackground=$Button.toolbar.pressedBackground @@ -684,6 +693,7 @@ ToolTipManager.enableToolTipMode=activeApplication Tree.border=1,1,1,1 Tree.editorBorder=1,1,1,1,@cellFocusColor +Tree.background=@textComponentBackground Tree.selectionInactiveBackground=@selectionInactiveBackground Tree.selectionInactiveForeground=@selectionInactiveForeground Tree.textBackground=$Tree.background diff --git a/flatlaf-core/src/main/resources/com/formdev/flatlaf/FlatLightLaf.properties b/flatlaf-core/src/main/resources/com/formdev/flatlaf/FlatLightLaf.properties index af28a165..25f6b972 100644 --- a/flatlaf-core/src/main/resources/com/formdev/flatlaf/FlatLightLaf.properties +++ b/flatlaf-core/src/main/resources/com/formdev/flatlaf/FlatLightLaf.properties @@ -127,8 +127,6 @@ CheckBox.icon[filled].selectedPressedBackground=darken($CheckBox.icon[filled].se #---- ComboBox ---- -ComboBox.background=@textComponentBackground -ComboBox.buttonBackground=@textComponentBackground ComboBox.buttonEditableBackground=#fafafa ComboBox.buttonArrowColor=#666 ComboBox.buttonDisabledArrowColor=#ABABAB @@ -187,11 +185,6 @@ InternalFrame.activeDropShadowOpacity=0.25 InternalFrame.inactiveDropShadowOpacity=0.5 -#---- List ---- - -List.background=@textComponentBackground - - #---- Menu ---- Menu.icon.arrowColor=#666 @@ -201,7 +194,6 @@ Menu.icon.disabledArrowColor=#ABABAB #---- MenuBar ---- MenuBar.borderColor=#cdcdcd -MenuBar.hoverBackground=@menuHoverBackground #---- MenuItemCheckBox ---- @@ -234,11 +226,6 @@ ProgressBar.selectionForeground=@textComponentBackground ProgressBar.selectionBackground=@foreground -#---- RadioButton ---- - -RadioButton.icon[filled].centerDiameter=5 - - #---- RootPane ---- RootPane.activeBorderColor=#707070 @@ -278,7 +265,6 @@ SplitPaneDivider.oneTouchHoverArrowColor=#333 #---- TabbedPane ---- -TabbedPane.disabledForeground=@disabledText TabbedPane.underlineColor=#4083C9 TabbedPane.disabledUnderlineColor=#ababab TabbedPane.hoverColor=#d9d9d9 @@ -288,13 +274,11 @@ TabbedPane.contentAreaColor=#bfbfbf #---- Table ---- -Table.background=@textComponentBackground Table.gridColor=darken($Table.background,3%) #---- TableHeader ---- -TableHeader.background=@textComponentBackground TableHeader.separatorColor=darken($TableHeader.background,10%) TableHeader.bottomSeparatorColor=$TableHeader.separatorColor @@ -309,7 +293,6 @@ TitlePane.buttonPressedBackground=darken($TitlePane.background,20%,derived) #---- ToggleButton ---- ToggleButton.selectedBackground=darken($ToggleButton.background,20%,derived) -ToggleButton.selectedForeground=@foreground ToggleButton.disabledSelectedBackground=darken($ToggleButton.background,13%,derived) ToggleButton.toolbar.selectedBackground=$ToggleButton.selectedBackground @@ -323,5 +306,4 @@ ToolTip.background=#fafafa #---- Tree ---- -Tree.background=@textComponentBackground Tree.hash=#E6E6E6 diff --git a/flatlaf-testing/src/main/resources/com/formdev/flatlaf/testing/uidefaults/FlatTestLaf_1.8.0_202.txt b/flatlaf-testing/src/main/resources/com/formdev/flatlaf/testing/uidefaults/FlatTestLaf_1.8.0_202.txt index b6c43ca0..bda10372 100644 --- a/flatlaf-testing/src/main/resources/com/formdev/flatlaf/testing/uidefaults/FlatTestLaf_1.8.0_202.txt +++ b/flatlaf-testing/src/main/resources/com/formdev/flatlaf/testing/uidefaults/FlatTestLaf_1.8.0_202.txt @@ -714,6 +714,7 @@ RadioButton.highlight #ffffff javax.swing.plaf.ColorUIResource [UI] RadioButton.icon.centerDiameter 8 RadioButton.icon [lazy] 15,15 com.formdev.flatlaf.icons.FlatRadioButtonIcon [UI] RadioButton.iconTextGap 4 +RadioButton.icon[filled].centerDiameter 5 RadioButton.light #e3e3e3 javax.swing.plaf.ColorUIResource [UI] RadioButton.margin 2,2,2,2 javax.swing.plaf.InsetsUIResource [UI] RadioButton.rollover true