From 1cd29b730b72401aa281963d50bd4d1c3fbb39a6 Mon Sep 17 00:00:00 2001 From: obo Date: Mon, 19 Feb 2024 16:56:11 +0800 Subject: [PATCH 1/2] =?UTF-8?q?REPORT-114524=20=E3=80=90=E6=8E=A7=E4=BB=B6?= =?UTF-8?q?=E6=98=BE=E7=A4=BA=E5=A2=9E=E5=BC=BA-=E5=A4=8D=E9=80=89?= =?UTF-8?q?=E6=8C=89=E9=92=AE=E7=BB=84=E6=8E=A7=E4=BB=B6=E3=80=91=E8=87=AA?= =?UTF-8?q?=E5=AE=9A=E4=B9=89=EF=BC=8C=E8=87=AA=E5=AE=9A=E4=B9=89=E4=BF=AE?= =?UTF-8?q?=E6=94=B9=E6=8E=A7=E4=BB=B6=E8=83=8C=E6=99=AF=E5=90=8E=E4=BC=9A?= =?UTF-8?q?=E6=8A=A5=E9=94=99?= MIME-Version: 1.0 Content-Type: text/plain; charset=UTF-8 Content-Transfer-Encoding: 8bit --- .../com/fr/design/widgettheme/common/ButtonSettingPane.java | 6 ++++++ 1 file changed, 6 insertions(+) diff --git a/designer-form/src/main/java/com/fr/design/widgettheme/common/ButtonSettingPane.java b/designer-form/src/main/java/com/fr/design/widgettheme/common/ButtonSettingPane.java index acdebeb964..f6b1403454 100644 --- a/designer-form/src/main/java/com/fr/design/widgettheme/common/ButtonSettingPane.java +++ b/designer-form/src/main/java/com/fr/design/widgettheme/common/ButtonSettingPane.java @@ -3,9 +3,11 @@ package com.fr.design.widgettheme.common; import com.fr.design.widgettheme.StyleSetting; import com.fr.design.widgettheme.BaseStyleSettingPane; import com.fr.form.ui.Widget; +import com.fr.util.ColorUtils; import com.fr.widgettheme.theme.widget.theme.cell.ButtonTheme; import org.jetbrains.annotations.Nullable; +import java.awt.Color; import java.util.Arrays; import java.util.List; @@ -64,6 +66,9 @@ public class ButtonSettingPane extends BaseStyleSettingPane } else { styleSettingHead.setSelectedIndex(1); colorSelectBox.setSelectObject(buttonTheme.getThemeColor()); + Color widgetBgColor = buttonTheme.getWidgetBackground().getColor(); + widgetBgColorSelectBox.setSelectObject(ColorUtils.ignoreColorAlpha(widgetBgColor)); + widgetBgAlphaDragPane.populateBean(ColorUtils.roundColorAlphaDouble(widgetBgColor)); assignFontSizePane(buttonTheme); } switchCard(); @@ -83,6 +88,7 @@ public class ButtonSettingPane extends BaseStyleSettingPane protected void updateButtonStyleBean(ButtonTheme buttonTheme) { buttonTheme.setThemeColor(colorSelectBox.getSelectObject()); + buttonTheme.setWidgetBackground(ColorUtils.createColorBackgroundWithAlpha(widgetBgColorSelectBox.getSelectObject(), widgetBgAlphaDragPane.updateBean())); assignFontSizeStyle(buttonTheme); switchCard(); } From 56fd8856300fb7242c80b79d107c72fb4edd6e93 Mon Sep 17 00:00:00 2001 From: obo Date: Mon, 19 Feb 2024 17:19:51 +0800 Subject: [PATCH 2/2] =?UTF-8?q?=E8=A7=86=E5=9B=BE=E6=A0=91=E4=B9=9F?= =?UTF-8?q?=E8=A1=A5=E4=B8=80=E4=B8=8B?= MIME-Version: 1.0 Content-Type: text/plain; charset=UTF-8 Content-Transfer-Encoding: 8bit --- .../fr/design/widgettheme/common/TreeEditorSettingPane.java | 6 ++++++ 1 file changed, 6 insertions(+) diff --git a/designer-form/src/main/java/com/fr/design/widgettheme/common/TreeEditorSettingPane.java b/designer-form/src/main/java/com/fr/design/widgettheme/common/TreeEditorSettingPane.java index 6f6676071c..a2e570dfed 100644 --- a/designer-form/src/main/java/com/fr/design/widgettheme/common/TreeEditorSettingPane.java +++ b/designer-form/src/main/java/com/fr/design/widgettheme/common/TreeEditorSettingPane.java @@ -3,9 +3,11 @@ package com.fr.design.widgettheme.common; import com.fr.design.widgettheme.StyleSetting; import com.fr.design.widgettheme.BaseStyleSettingPane; import com.fr.form.ui.TreeEditor; +import com.fr.util.ColorUtils; import com.fr.widgettheme.theme.widget.theme.cell.TreeTheme; import org.jetbrains.annotations.Nullable; +import java.awt.Color; import java.util.Arrays; import java.util.List; @@ -56,6 +58,9 @@ public class TreeEditorSettingPane extends BaseStyleSettin } else { styleSettingHead.setSelectedIndex(1); colorSelectBox.setSelectObject(treeTheme.getThemeColor()); + Color widgetBgColor = treeTheme.getWidgetBackground().getColor(); + widgetBgColorSelectBox.setSelectObject(ColorUtils.ignoreColorAlpha(widgetBgColor)); + widgetBgAlphaDragPane.populateBean(ColorUtils.roundColorAlphaDouble(widgetBgColor)); assignFontSizePane(treeTheme); } switchCard(); @@ -83,6 +88,7 @@ public class TreeEditorSettingPane extends BaseStyleSettin protected void updateTreeStyleBean(TreeTheme treeTheme) { treeTheme.setThemeColor(colorSelectBox.getSelectObject()); + treeTheme.setWidgetBackground(ColorUtils.createColorBackgroundWithAlpha(widgetBgColorSelectBox.getSelectObject(), widgetBgAlphaDragPane.updateBean())); assignFontSizeStyle(treeTheme); switchCard(); }