From e828cd48d5030505beb64c53954f33bb6a8b14f7 Mon Sep 17 00:00:00 2001 From: =?UTF-8?q?=E7=99=BD=E5=B2=B3?= <445798420@qq.com> Date: Fri, 10 Jul 2020 15:11:41 +0800 Subject: [PATCH] =?UTF-8?q?CHART-14541=20=E8=BD=B4=E6=A0=87=E9=A2=98?= =?UTF-8?q?=E5=A2=9E=E5=8A=A0=E7=BC=A9=E8=BF=9B?= MIME-Version: 1.0 Content-Type: text/plain; charset=UTF-8 Content-Transfer-Encoding: 8bit --- .../chart/designer/style/axis/VanChartBaseAxisPane.java | 5 +++-- .../chart/designer/style/axis/VanChartTimeAxisPane.java | 8 ++++---- .../chart/designer/style/axis/VanChartValueAxisPane.java | 2 +- 3 files changed, 8 insertions(+), 7 deletions(-) diff --git a/designer-chart/src/main/java/com/fr/van/chart/designer/style/axis/VanChartBaseAxisPane.java b/designer-chart/src/main/java/com/fr/van/chart/designer/style/axis/VanChartBaseAxisPane.java index fcc34958e..be2c7d8a5 100644 --- a/designer-chart/src/main/java/com/fr/van/chart/designer/style/axis/VanChartBaseAxisPane.java +++ b/designer-chart/src/main/java/com/fr/van/chart/designer/style/axis/VanChartBaseAxisPane.java @@ -126,7 +126,7 @@ public class VanChartBaseAxisPane extends FurtherBasicBeanPane { double[] column = {f, s}; double[] rowSize = {p, p, p, p, p, p, p, p}; Component[][] components = new Component[][]{ - new Component[]{createTitlePane(new double[]{p, p, p, p, p, p}, columnSize, isXAxis), null}, + new Component[]{createTitlePane(new double[]{p, p, p, p, p, p}, column, isXAxis), null}, new Component[]{createLabelPane(new double[]{p, p}, column), null}, new Component[]{createLineStylePane(new double[]{p, p, p, p, p}, columnSize), null}, new Component[]{createAxisPositionPane(new double[]{p, p, p}, columnSize, isXAxis), null}, @@ -144,7 +144,7 @@ public class VanChartBaseAxisPane extends FurtherBasicBeanPane { titleContent = new TinyFormulaPane(); titleUseHtml = new UIToggleButton(com.fr.design.i18n.Toolkit.i18nText("Fine-Design_Chart_Html")); UIComponentUtils.setLineWrap(titleUseHtml); - titleTextAttrPane = new ChartTextAttrPane(); + titleTextAttrPane = getChartTextAttrPane(); titleTextRotation = new UINumberDragPane(-ROTATION_MAX, ROTATION_MAX); if (isXAxis) { titleTextRotation.populateBean(0.0); @@ -163,6 +163,7 @@ public class VanChartBaseAxisPane extends FurtherBasicBeanPane { }, }; titlePane = TableLayout4VanChartHelper.createGapTableLayoutPane(components, row, col); + titlePane.setBorder(BorderFactory.createEmptyBorder(0, 10, 0, 0)); JPanel showTitlePane = TableLayout4VanChartHelper.createGapTableLayoutPane(Toolkit.i18nText("Fine-Design_Chart_Axis_Title"), showTitle); showTitle.addActionListener(new ActionListener() { diff --git a/designer-chart/src/main/java/com/fr/van/chart/designer/style/axis/VanChartTimeAxisPane.java b/designer-chart/src/main/java/com/fr/van/chart/designer/style/axis/VanChartTimeAxisPane.java index 2d408c905..b57f0fc2f 100644 --- a/designer-chart/src/main/java/com/fr/van/chart/designer/style/axis/VanChartTimeAxisPane.java +++ b/designer-chart/src/main/java/com/fr/van/chart/designer/style/axis/VanChartTimeAxisPane.java @@ -27,15 +27,15 @@ import com.fr.van.chart.designer.TableLayout4VanChartHelper; import javax.swing.BorderFactory; import javax.swing.JPanel; +import java.text.ParseException; +import java.util.Date; +import java.util.regex.Pattern; import java.awt.BorderLayout; import java.awt.Component; import java.awt.Dimension; import java.awt.FlowLayout; import java.awt.event.ActionEvent; import java.awt.event.ActionListener; -import java.text.ParseException; -import java.util.Date; -import java.util.regex.Pattern; /** * 时间坐标轴 @@ -68,7 +68,7 @@ public class VanChartTimeAxisPane extends VanChartBaseAxisPane { double[] column = {f, s}; double[] rowSize = {p,p,p,p,p,p,p,p,p,p,p,p,p,p}; Component[][] components = new Component[][]{ - new Component[]{createTitlePane(new double[]{p, p, p, p, p,p}, columnSize, isXAxis),null}, + new Component[]{createTitlePane(new double[]{p, p, p, p, p,p}, column, isXAxis),null}, new Component[]{createLabelPane(new double[]{p, p}, column),null}, new Component[]{createValueDefinition(),null}, new Component[]{createLineStylePane(new double[]{p, p,p,p,p}, columnSize),null}, diff --git a/designer-chart/src/main/java/com/fr/van/chart/designer/style/axis/VanChartValueAxisPane.java b/designer-chart/src/main/java/com/fr/van/chart/designer/style/axis/VanChartValueAxisPane.java index 2b90633e6..934185b38 100644 --- a/designer-chart/src/main/java/com/fr/van/chart/designer/style/axis/VanChartValueAxisPane.java +++ b/designer-chart/src/main/java/com/fr/van/chart/designer/style/axis/VanChartValueAxisPane.java @@ -49,7 +49,7 @@ public class VanChartValueAxisPane extends VanChartBaseAxisPane { double[] column = {f, s}; double[] rowSize = {p,p,p,p,p,p,p,p,p,p,p,p,p,p}; Component[][] components = new Component[][]{ - new Component[]{createTitlePane(new double[]{p, p, p, p, p, p}, columnSize, isXAxis), null}, + new Component[]{createTitlePane(new double[]{p, p, p, p, p, p}, column, isXAxis), null}, new Component[]{createLabelPane(new double[]{p, p}, column), null}, new Component[]{createMinMaxValuePane(new double[]{p, p}, columnSize), null}, new Component[]{createLineStylePane(new double[]{p, p, p, p, p}, columnSize), null},