diff --git a/designer-chart/src/main/java/com/fr/van/chart/designer/component/marker/VanChartCommonMarkerPane.java b/designer-chart/src/main/java/com/fr/van/chart/designer/component/marker/VanChartCommonMarkerPane.java index bda44ccf3b..15cba5c8d6 100644 --- a/designer-chart/src/main/java/com/fr/van/chart/designer/component/marker/VanChartCommonMarkerPane.java +++ b/designer-chart/src/main/java/com/fr/van/chart/designer/component/marker/VanChartCommonMarkerPane.java @@ -2,7 +2,6 @@ package com.fr.van.chart.designer.component.marker; import com.fr.chart.chartglyph.Marker; import com.fr.design.beans.BasicBeanPane; -import com.fr.design.constants.LayoutConstants; import com.fr.design.gui.ilable.UILabel; import com.fr.design.gui.ispinner.UISpinner; import com.fr.design.gui.xcombox.MarkerComboBox; @@ -57,6 +56,7 @@ public class VanChartCommonMarkerPane extends BasicBeanPane } private static Marker[] normalMarkersWithAuto = null; + protected static Marker[] getNormalMarkersWithAuto() { if (normalMarkersWithAuto == null) { normalMarkersWithAuto = new Marker[NORMAL_TYPES.length + 1]; @@ -130,17 +130,17 @@ public class VanChartCommonMarkerPane extends BasicBeanPane double p = TableLayout.PREFERRED; double f = TableLayout.FILL; - double e = TableLayout4VanChartHelper.EDIT_AREA_WIDTH; + double e = getColumnSize()[1]; double[] columnSize = {f, e}; double[] rowSize = {p, p, p}; - return TableLayoutHelper.createGapTableLayoutPane(getPaneComponents(), rowSize, columnSize, 0, LayoutConstants.VGAP_MEDIUM); + return TableLayoutHelper.createTableLayoutPane(getPaneComponents(), rowSize, columnSize); } protected Component[][] getPaneComponents() { return new Component[][]{ new Component[]{null, null}, - new Component[]{null, typeComboBox}, + new Component[]{new UILabel(com.fr.design.i18n.Toolkit.i18nText("Fine-Design_Chart_Fill_Color")), typeComboBox}, new Component[]{null, centerPane}, }; } @@ -175,7 +175,7 @@ public class VanChartCommonMarkerPane extends BasicBeanPane protected Component[][] getMarkerConfigComponent() { return new Component[][]{ - new Component[]{new UILabel(Toolkit.i18nText("Fine-Design_Chart_Fill_Color")), markerFillColor}, + new Component[]{markerFillColor, null}, new Component[]{new UILabel(Toolkit.i18nText("Fine-Design_Chart_Radius")), radius} }; } diff --git a/designer-realize/src/main/java/com/fr/design/headerfooter/HFAttributesEditDialog.java b/designer-realize/src/main/java/com/fr/design/headerfooter/HFAttributesEditDialog.java index 152f8fd282..2b81db2b95 100644 --- a/designer-realize/src/main/java/com/fr/design/headerfooter/HFAttributesEditDialog.java +++ b/designer-realize/src/main/java/com/fr/design/headerfooter/HFAttributesEditDialog.java @@ -26,12 +26,14 @@ import com.fr.design.layout.FRGUIPaneFactory; import com.fr.design.style.FRFontPane; import com.fr.design.style.FormatPane; import com.fr.general.ComparatorUtils; +import com.fr.general.date.FineDateFormat; import javax.swing.*; import java.awt.*; import java.awt.event.ActionEvent; import java.awt.event.ActionListener; +import java.text.Format; import java.util.ArrayList; /** @@ -274,10 +276,16 @@ public class HFAttributesEditDialog extends BasicPane { ((NumberOfPageHFElement) hfElement).setFRFont(this.frFontPane.update()); } else if (ComparatorUtils.equals(this.hfElement.getClass(),DateHFElement.class)) { ((DateHFElement) hfElement).setFRFont(this.frFontPane.update()); - ((DateHFElement) hfElement).setFormat(this.formatPane.update()); + Format format = this.formatPane.update(); + if (format instanceof FineDateFormat) { + ((DateHFElement) hfElement).setFormat(format); + } } else if (ComparatorUtils.equals(this.hfElement.getClass(),TimeHFElement.class)) { ((TimeHFElement) hfElement).setFRFont(this.frFontPane.update()); - ((TimeHFElement) hfElement).setFormat(this.formatPane.update()); + Format format = this.formatPane.update(); + if (format instanceof FineDateFormat) { + ((TimeHFElement) hfElement).setFormat(format); + } } else if (ComparatorUtils.equals(this.hfElement.getClass(),ImageHFElement.class)) { ((ImageHFElement) hfElement).setImage(this.imagePane.update()); } else if (ComparatorUtils.equals(this.hfElement.getClass(),NewLineHFElement.class)) { diff --git a/designer-realize/src/main/java/com/fr/design/report/UnitFieldPane.java b/designer-realize/src/main/java/com/fr/design/report/UnitFieldPane.java index 4a6984d0f0..6da8957b26 100644 --- a/designer-realize/src/main/java/com/fr/design/report/UnitFieldPane.java +++ b/designer-realize/src/main/java/com/fr/design/report/UnitFieldPane.java @@ -67,7 +67,7 @@ public class UnitFieldPane extends JPanel { this.unitType = unitType; - valueSpinner = new UIBasicSpinner(new SpinnerNumberModel(0.0, 0.0, Double.MAX_VALUE, 1.0)); + valueSpinner = new UIBasicSpinner(new SpinnerNumberModel(0.0, Integer.MIN_VALUE, Double.MAX_VALUE, 1.0)); textField = ((JSpinner.DefaultEditor) valueSpinner.getEditor()).getTextField(); textField.setColumns(OperatingSystem.isWindows() ? TEXT_FIELD_COLUMNS_WINDOWS : TEXT_FIELD_COLUMNS); InputEventBaseOnOS.addBasicEditInputMap(textField);