From f36cf8c00faa4c312b9960bac6e9a36b15d7d897 Mon Sep 17 00:00:00 2001 From: Zhanying <2446962908@qq.com> Date: Wed, 18 Sep 2024 15:44:26 +0800 Subject: [PATCH 1/2] =?UTF-8?q?REPORT-134295=20fix:=20=E3=80=90FBP?= =?UTF-8?q?=E3=80=91=E6=89=A9=E5=B1=95=E5=9B=BE=E8=A1=A8=E6=95=B0=E6=8D=AE?= =?UTF-8?q?=E9=9D=A2=E6=9D=BF=E5=B8=83=E5=B1=80=E9=80=82=E9=85=8D?= MIME-Version: 1.0 Content-Type: text/plain; charset=UTF-8 Content-Transfer-Encoding: 8bit --- .../com/fr/design/chartx/data/DataLayoutHelper.java | 12 ++---------- .../com/fr/design/chartx/single/CellDataPane.java | 2 -- .../com/fr/design/chartx/single/DataSetPane.java | 1 - .../com/fr/design/chartx/single/SingleDataPane.java | 1 - 4 files changed, 2 insertions(+), 14 deletions(-) diff --git a/designer-chart/src/main/java/com/fr/design/chartx/data/DataLayoutHelper.java b/designer-chart/src/main/java/com/fr/design/chartx/data/DataLayoutHelper.java index 98ae28085c..9ac16b486b 100644 --- a/designer-chart/src/main/java/com/fr/design/chartx/data/DataLayoutHelper.java +++ b/designer-chart/src/main/java/com/fr/design/chartx/data/DataLayoutHelper.java @@ -1,15 +1,13 @@ package com.fr.design.chartx.data; +import com.fine.theme.utils.FineLayoutBuilder; import com.fr.design.gui.ilable.UILabel; -import com.fr.design.layout.TableLayout; -import com.fr.design.layout.TableLayoutHelper; import javax.swing.BorderFactory; import javax.swing.JComponent; import javax.swing.JPanel; import javax.swing.SwingConstants; import java.awt.Component; -import java.util.Arrays; /** * @author shine @@ -46,13 +44,7 @@ public class DataLayoutHelper { } public static JPanel createDataLayoutPane(Component[][] components) { - int len = components.length; - double p = TableLayout.PREFERRED; - double[] columnSize = {DataLayoutHelper.LABEL_WIDTH, DataLayoutHelper.WIDTH}; - double[] rowSize = new double[len]; - Arrays.fill(rowSize, p); - - return TableLayoutHelper.createTableLayoutPane(components, rowSize, columnSize); + return FineLayoutBuilder.compatibleTableLayout(10, components, new double[] {1.2, 3}); } public static JPanel createDataLayoutPane(String label, Component component) { diff --git a/designer-chart/src/main/java/com/fr/design/chartx/single/CellDataPane.java b/designer-chart/src/main/java/com/fr/design/chartx/single/CellDataPane.java index 37c45d0416..b4bb2672b0 100644 --- a/designer-chart/src/main/java/com/fr/design/chartx/single/CellDataPane.java +++ b/designer-chart/src/main/java/com/fr/design/chartx/single/CellDataPane.java @@ -2,7 +2,6 @@ package com.fr.design.chartx.single; import com.fr.chartx.data.CellDataDefinition; import com.fr.design.beans.FurtherBasicBeanPane; -import com.fr.design.chartx.data.DataLayoutHelper; import com.fr.design.chartx.fields.AbstractCellDataFieldsPane; import com.fr.design.i18n.Toolkit; @@ -24,7 +23,6 @@ public class CellDataPane extends FurtherBasicBeanPane { this.setLayout(new BorderLayout()); this.add(cellDataFieldsPane, BorderLayout.CENTER); - DataLayoutHelper.addNormalBorder(this); } @Override diff --git a/designer-chart/src/main/java/com/fr/design/chartx/single/DataSetPane.java b/designer-chart/src/main/java/com/fr/design/chartx/single/DataSetPane.java index dab74e15a4..699784cc73 100644 --- a/designer-chart/src/main/java/com/fr/design/chartx/single/DataSetPane.java +++ b/designer-chart/src/main/java/com/fr/design/chartx/single/DataSetPane.java @@ -48,7 +48,6 @@ public class DataSetPane extends FurtherBasicBeanPane { this.setLayout(new BorderLayout(0, 6)); this.add(northPane, BorderLayout.NORTH); this.add(dataSetFieldsPane, BorderLayout.CENTER); - DataLayoutHelper.addNormalBorder(this); checkBoxUse(); } diff --git a/designer-chart/src/main/java/com/fr/design/chartx/single/SingleDataPane.java b/designer-chart/src/main/java/com/fr/design/chartx/single/SingleDataPane.java index 06ed06649b..00873cadd1 100644 --- a/designer-chart/src/main/java/com/fr/design/chartx/single/SingleDataPane.java +++ b/designer-chart/src/main/java/com/fr/design/chartx/single/SingleDataPane.java @@ -46,7 +46,6 @@ public class SingleDataPane extends BasicBeanPane { protected void initLayout() { this.setLayout(new BorderLayout(0, 6)); JPanel northPane = DataLayoutHelper.createDataLayoutPane(Toolkit.i18nText("Fine-Design_Chart_Data_Source"), jcb); - DataLayoutHelper.addNormalBorder(northPane); this.add(northPane, BorderLayout.NORTH); this.add(cardPane, BorderLayout.CENTER); From 755a1dbbc1655f384ec51fe281f87496f3a76904 Mon Sep 17 00:00:00 2001 From: =?UTF-8?q?Levy=2EXie-=E8=A7=A3=E5=AE=89=E6=A3=AE?= Date: Fri, 20 Sep 2024 10:44:16 +0800 Subject: [PATCH 2/2] =?UTF-8?q?REPORT-135143=20&=20REPORT-133294=20&=20REP?= =?UTF-8?q?ORT-133394=20fix:NewUI=E7=BB=86=E8=8A=82=E9=97=AE=E9=A2=98?= =?UTF-8?q?=E4=BF=AE=E5=A4=8D?= MIME-Version: 1.0 Content-Type: text/plain; charset=UTF-8 Content-Transfer-Encoding: 8bit --- .../main/java/com/fine/theme/light/ui/FineHeaderPaneUI.java | 3 +++ .../src/main/java/com/fr/design/gui/ibutton/UIHeadGroup.java | 1 + .../resources/com/fine/theme/icon/font/background_disable.svg | 4 ++++ .../resources/com/fine/theme/icon/font/foreground_disable.svg | 4 ++++ .../com/fr/van/chart/column/VanChartColumnSeriesPane.java | 2 +- 5 files changed, 13 insertions(+), 1 deletion(-) create mode 100644 designer-base/src/main/resources/com/fine/theme/icon/font/background_disable.svg create mode 100644 designer-base/src/main/resources/com/fine/theme/icon/font/foreground_disable.svg diff --git a/designer-base/src/main/java/com/fine/theme/light/ui/FineHeaderPaneUI.java b/designer-base/src/main/java/com/fine/theme/light/ui/FineHeaderPaneUI.java index 4555096842..ea07516938 100644 --- a/designer-base/src/main/java/com/fine/theme/light/ui/FineHeaderPaneUI.java +++ b/designer-base/src/main/java/com/fine/theme/light/ui/FineHeaderPaneUI.java @@ -18,6 +18,7 @@ import java.awt.FontMetrics; import java.awt.Graphics; import java.awt.Graphics2D; import java.awt.Insets; +import java.awt.RenderingHints; import java.awt.geom.AffineTransform; /** @@ -100,6 +101,8 @@ public class FineHeaderPaneUI extends PanelUI implements AnimatedPainter { + FineUIScale.scale(UIManager.getInt("ExpandablePane.HeaderPane.hGap")); float titleY = (headerPane.getHeight() - (ascent + descent)) / 2.0f + ascent; FlatUIUtils.setRenderingHints(g2d); + g2d.setRenderingHint(RenderingHints.KEY_TEXT_ANTIALIASING, RenderingHints.VALUE_TEXT_ANTIALIAS_LCD_HRGB); + g2d.drawString(headerPane.getTitle(), titleX, titleY); g2d.dispose(); } diff --git a/designer-base/src/main/java/com/fr/design/gui/ibutton/UIHeadGroup.java b/designer-base/src/main/java/com/fr/design/gui/ibutton/UIHeadGroup.java index 715fd3e793..e6730126d8 100644 --- a/designer-base/src/main/java/com/fr/design/gui/ibutton/UIHeadGroup.java +++ b/designer-base/src/main/java/com/fr/design/gui/ibutton/UIHeadGroup.java @@ -101,6 +101,7 @@ public class UIHeadGroup extends Row { b.setEnabled(h.isEnable()); b.putClientProperty(BUTTON_TYPE, BUTTON_TYPE_TAB); b.addActionListener(e -> setSelectedIndex((int) index)); + b.setFocusPainted(false); }) ).toArray(Layouts.Cell[]::new); diff --git a/designer-base/src/main/resources/com/fine/theme/icon/font/background_disable.svg b/designer-base/src/main/resources/com/fine/theme/icon/font/background_disable.svg new file mode 100644 index 0000000000..3dff853cb9 --- /dev/null +++ b/designer-base/src/main/resources/com/fine/theme/icon/font/background_disable.svg @@ -0,0 +1,4 @@ + + + + diff --git a/designer-base/src/main/resources/com/fine/theme/icon/font/foreground_disable.svg b/designer-base/src/main/resources/com/fine/theme/icon/font/foreground_disable.svg new file mode 100644 index 0000000000..dcf70fdc59 --- /dev/null +++ b/designer-base/src/main/resources/com/fine/theme/icon/font/foreground_disable.svg @@ -0,0 +1,4 @@ + + + + diff --git a/designer-chart/src/main/java/com/fr/van/chart/column/VanChartColumnSeriesPane.java b/designer-chart/src/main/java/com/fr/van/chart/column/VanChartColumnSeriesPane.java index 7822cb3443..a8b039c77b 100644 --- a/designer-chart/src/main/java/com/fr/van/chart/column/VanChartColumnSeriesPane.java +++ b/designer-chart/src/main/java/com/fr/van/chart/column/VanChartColumnSeriesPane.java @@ -79,7 +79,7 @@ public class VanChartColumnSeriesPane extends VanChartAbstractPlotSeriesPane { isFixedWidth.addActionListener(e -> checkColumnWidth()); isFillWithImage.addActionListener(e -> checkImagePane()); - return new UIExpandablePane(Toolkit.i18nText("Fine-Design_Chart_Filled_With_Image"), borderPane, true); + return new UIExpandablePane(Toolkit.i18nText("Fine-Design_Chart_Widget_Style"), borderPane, true); } private void checkAll() {