Browse Source

Merge pull request #1063 in BA/design from ~MOMEAK/design9.0:9.0 to 9.0

* commit '27405f56c2f3e971d2c9ea8dcffc2b2b04baa397':
  视觉
  视觉
  rollback
  视觉
  rollback
  视觉
  rollback
  REPORT-2897 9.0设计器修改 视觉优化
  REPORT-2897 9.0设计器修改 控件设置网页框
master
superman 7 years ago
parent
commit
c7a8b9f2aa
  1. 14
      designer/src/com/fr/design/mainframe/ReportFloatPane.java
  2. 58
      designer/src/com/fr/design/mainframe/cell/settingpane/CellOtherSetPane.java
  3. 33
      designer/src/com/fr/design/present/BarCodePane.java
  4. 9
      designer/src/com/fr/design/widget/ui/BasicWidgetPropertySettingPane.java
  5. 1
      designer/src/com/fr/design/widget/ui/DirectWriteEditorDefinePane.java
  6. 3
      designer/src/com/fr/design/widget/ui/IframeEditorDefinePane.java
  7. 10
      designer/src/com/fr/design/widget/ui/NumberEditorDefinePane.java
  8. 10
      designer/src/com/fr/design/widget/ui/TextFieldEditorDefinePane.java
  9. 13
      designer/src/com/fr/design/widget/ui/WaterMarkDictPane.java
  10. 2
      designer/src/com/fr/quickeditor/floatquick/FloatImageQuickEditor.java
  11. 7
      designer/src/com/fr/quickeditor/floatquick/FloatStringQuickEditor.java
  12. 1
      designer_base/src/com/fr/design/constants/UIConstants.java
  13. 11
      designer_base/src/com/fr/design/gui/style/FRFontPane.java
  14. 40
      designer_base/src/com/fr/design/gui/style/FormatPane.java
  15. 7
      designer_base/src/com/fr/design/locale/designer.properties
  16. 7
      designer_base/src/com/fr/design/locale/designer_en_US.properties
  17. 9
      designer_base/src/com/fr/design/locale/designer_ja_JP.properties
  18. 9
      designer_base/src/com/fr/design/locale/designer_ko_KR.properties
  19. 1
      designer_base/src/com/fr/design/locale/designer_zh_CN.properties
  20. 1
      designer_base/src/com/fr/design/locale/designer_zh_TW.properties
  21. 25
      designer_base/src/com/fr/design/present/dict/FormulaDictPane.java

14
designer/src/com/fr/design/mainframe/ReportFloatPane.java

@ -2,6 +2,7 @@ package com.fr.design.mainframe;
import com.fr.design.actions.UpdateAction;
import com.fr.design.actions.core.ActionFactory;
import com.fr.design.constants.UIConstants;
import com.fr.design.file.HistoryTemplateListPane;
import com.fr.design.gui.ibutton.UIButton;
import com.fr.design.gui.ilable.UILabel;
@ -42,7 +43,14 @@ public class ReportFloatPane extends JPanel {
UIToolbar topToolBar = new UIToolbar();
topToolBar.setLayout(new BorderLayout());
insertFloatMenu = createInsertToolBar();
topToolBar.add(createButtonUI());
topToolBar.setPreferredSize(new Dimension(155,20));
topToolBar.add(createButtonUI(), BorderLayout.CENTER);
topToolBar.setBorder(BorderFactory.createEmptyBorder(-1, -1, -1, -1));
JPanel toolBarPane = new JPanel(new BorderLayout());
toolBarPane.add(topToolBar, BorderLayout.CENTER);
toolBarPane.setBorder(BorderFactory.createLineBorder(UIConstants.POP_DIALOG_BORDER));
toolBarPane.setPreferredSize(new Dimension(155,20));
UILabel emptyLabel = new UILabel();
emptyLabel.setBorder(BorderFactory.createEmptyBorder(0, 4, 0, 0));
@ -51,10 +59,10 @@ public class ReportFloatPane extends JPanel {
double[] columnSize = {p, p, p, f};
double[] rowSize = {p};
Component[][] components = new Component[][]{
new Component[]{new UILabel(), new UILabel(Inter.getLocText("FR-Designer_Add_FloatElement")), emptyLabel, topToolBar},
new Component[]{new UILabel(), new UILabel(Inter.getLocText("FR-Designer_Add_FloatElement")), emptyLabel, toolBarPane},
};
JPanel leftTopPane = TableLayoutHelper.createTableLayoutPane(components, rowSize, columnSize);
leftTopPane.setBorder(BorderFactory.createEmptyBorder(10, 4, 0, 13));
leftTopPane.setBorder(BorderFactory.createEmptyBorder(10, 5, 0, 15));
this.add(leftTopPane, BorderLayout.NORTH);
}

58
designer/src/com/fr/design/mainframe/cell/settingpane/CellOtherSetPane.java

@ -63,7 +63,8 @@ public class CellOtherSetPane extends AbstractCellAttrPane {
// 插入行策略
private UIButtonGroup insertRowPolicy;
private ValueEditorPane valueEditor;
private CardLayout insertRowLayout;
private JPanel insertRowPane;
private JPanel southContentPane;
private JPanel defaultValuePane;
@ -109,14 +110,41 @@ public class CellOtherSetPane extends AbstractCellAttrPane {
defaultValuePane = new JPanel(new BorderLayout(4, 0));
valueEditor = ValueEditorPaneFactory.createBasicValueEditorPane();
defaultValuePane.add(valueEditor, BorderLayout.CENTER);
defaultValuePane.setVisible(false);
insertRowLayout = new CardLayout();
insertRowPane = new JPanel(insertRowLayout);
insertRowPane.add(new JPanel(), "none");
insertRowPane.add(defaultValuePane, "content");
insertRowPane.setPreferredSize(new Dimension(0, 0));
insertRowPolicy.addChangeListener(new ChangeListener() {
@Override
public void stateChanged(ChangeEvent e) {
defaultValuePane.setVisible(insertRowPolicy.getSelectedIndex() == 1);
if (insertRowPolicy.getSelectedIndex() == 1) {
insertRowPane.setPreferredSize(new Dimension(100, 20));
insertRowLayout.show(insertRowPane, "content");
} else {
insertRowLayout.show(insertRowPane, "none");
insertRowPane.setPreferredSize(new Dimension(0, 0));
}
}
});
double f = TableLayout.FILL;
double p = TableLayout.PREFERRED;
double[] rowSize1 = {p, p};
double[] columnSize1 = {p, f};
int[][] rowCount1 = {{1, 1}, {1, 1}};
Component[][] components1 = new Component[][]{
new Component[]{new UILabel(Inter.getLocText("FR-Designer_CellWrite_InsertRow_Policy"), SwingConstants.LEFT), insertRowPolicy},
new Component[]{null, insertRowPane},
};
southContentPane = TableLayoutHelper.createGapTableLayoutPane(components1, rowSize1, columnSize1, rowCount1, LayoutConstants.VGAP_MEDIUM, LayoutConstants.VGAP_MEDIUM);
JPanel seniorPane = new JPanel(new BorderLayout());
seniorPane.add(seniorUpPane(), BorderLayout.NORTH);
seniorPane.add(southContentPane, BorderLayout.CENTER);
southContentPane.setBorder(BorderFactory.createEmptyBorder(0, 0, 10, 0));
return seniorPane;
}
private JPanel seniorUpPane() {
JPanel fileNamePane = createNormal();
double f = TableLayout.FILL;
double p = TableLayout.PREFERRED;
@ -133,19 +161,7 @@ public class CellOtherSetPane extends AbstractCellAttrPane {
new Component[]{new UILabel(Inter.getLocText("FR-Designer_CellWrite_ToolTip"), SwingConstants.RIGHT), tooltipTextField},
new Component[]{null, null},
};
JPanel seniorCenterPane = TableLayoutHelper.createGapTableLayoutPane(components, rowSize, columnSize, rowCount, LayoutConstants.VGAP_MEDIUM, LayoutConstants.VGAP_MEDIUM);
double[] rowSize1 = {p, p};
double[] columnSize1 = {p, f};
int[][] rowCount1 = {{1, 1}, {1, 1}};
Component[][] components1 = new Component[][]{
new Component[]{new UILabel(Inter.getLocText("FR-Designer_CellWrite_InsertRow_Policy"), SwingConstants.LEFT), insertRowPolicy},
new Component[]{null, defaultValuePane},
};
southContentPane = TableLayoutHelper.createGapTableLayoutPane(components1, rowSize1, columnSize1, rowCount1, LayoutConstants.VGAP_MEDIUM, LayoutConstants.VGAP_MEDIUM);
JPanel seniorPane = new JPanel(new BorderLayout());
seniorPane.add(seniorCenterPane, BorderLayout.NORTH);
seniorPane.add(southContentPane, BorderLayout.CENTER);
return seniorPane;
return TableLayoutHelper.createGapTableLayoutPane(components, rowSize, columnSize, rowCount, LayoutConstants.VGAP_MEDIUM, LayoutConstants.VGAP_MEDIUM);
}
private JPanel pagePane() {
@ -305,7 +321,13 @@ public class CellOtherSetPane extends AbstractCellAttrPane {
} else {
insertRowPolicy.setSelectedIndex(0);
}
defaultValuePane.setVisible(insertRowPolicy.getSelectedIndex() == 1);
if (insertRowPolicy.getSelectedIndex() == 1) {
insertRowPane.setPreferredSize(new Dimension(100, 20));
insertRowLayout.show(insertRowPane, "content");
} else {
insertRowLayout.show(insertRowPane, "none");
insertRowPane.setPreferredSize(new Dimension(0, 0));
}
southContentPane.setVisible(true);
JTemplate jTemplate = HistoryTemplateListPane.getInstance().getCurrentEditingTemplate();
if (!jTemplate.isJWorkBook()) { //表单中报表块编辑屏蔽掉 插入行策略

33
designer/src/com/fr/design/present/BarCodePane.java

@ -2,6 +2,7 @@ package com.fr.design.present;
import com.fr.design.beans.FurtherBasicBeanPane;
import com.fr.design.border.UIRoundedBorder;
import com.fr.design.constants.LayoutConstants;
import com.fr.design.constants.UIConstants;
import com.fr.design.gui.icheckbox.UICheckBox;
import com.fr.design.gui.icombobox.UIComboBox;
@ -85,7 +86,7 @@ public class BarCodePane extends FurtherBasicBeanPane<BarcodePresent> {
RCodesizespinner = new UIBasicSpinner(new SpinnerNumberModel(2, 1, 6, 1));
RCodeVersionComboBox = new UIComboBox();
RCodeErrorCorrectComboBox = new UIComboBox();
typeSetLabel = new UILabel(Inter.getLocText("Type_Set"), UILabel.RIGHT);
typeSetLabel = new UILabel(Inter.getLocText("Type_Set"), UILabel.LEFT);
initVersionComboBox();
initErrorCorrectComboBox();
@ -95,7 +96,9 @@ public class BarCodePane extends FurtherBasicBeanPane<BarcodePresent> {
double f = TableLayout.FILL;
double[] columnSize = {p, f};
double[] rowSize = {p, p, p, p, p, p, p, p};
int[][] rowCount = {{1, 1, 1}, {1, 1, 1}, {1, 1, 1}, {1, 1, 1}, {1, 1, 1}, {1, 1, 1}, {1, 1, 1}, {1, 1, 1}};
barCodePreviewPane.setPreferredSize(new Dimension(0, 125));
typeComboBox.setPreferredSize(new Dimension(155,20));
final JPanel centerPane = new JPanel(new CardLayout());
Component[][] components = new Component[][]{
@ -103,7 +106,7 @@ public class BarCodePane extends FurtherBasicBeanPane<BarcodePresent> {
new Component[]{borderPane, null},
new Component[]{centerPane, null}
};
JPanel barCode = TableLayoutHelper.createTableLayoutPane(components, rowSize, columnSize);
JPanel barCode = TableLayoutHelper.createGapTableLayoutPane(components, rowSize, columnSize, rowCount, LayoutConstants.VGAP_LARGE, LayoutConstants.VGAP_LARGE);
centerPane.add(getNormalPane(), "normal");
centerPane.add(getSpecialPane(), "special");
typeComboBox.addItemListener(new ItemListener() {
@ -145,21 +148,23 @@ public class BarCodePane extends FurtherBasicBeanPane<BarcodePresent> {
double f = TableLayout.FILL;
double p = TableLayout.PREFERRED;
double[] rowSize = {p, p, p, p, p, p, p, p};
double[] columnSize1 = {p, f, f};
double[] columnSize = {p, f, f};
int[][] rowCount = {{1, 1, 1}, {1, 1, 1}, {1, 1, 1}};
JPanel barWidthContainer = new JPanel(new FlowLayout(FlowLayout.LEFT, 2, 0));
barWidthContainer.add(barWidthSpinner);
JPanel barHeightContainer = new JPanel(new FlowLayout(FlowLayout.LEFT, 2, 0));
barHeightContainer.add(barHeightSpinner);
UILabel uiLabel = new UILabel(Inter.getLocText("Tree-Width") + ":", UILabel.RIGHT);
UILabel uiLabel = new UILabel(Inter.getLocText("FR-Designer-Tree_Width"), UILabel.RIGHT);
uiLabel.setPreferredSize(typeSetLabel.getPreferredSize());
drawingTextCheckBox.setBorder(UIConstants.CELL_ATTR_ZEROBORDER);
Component[][] components_normal = new Component[][]{
new Component[]{new UILabel("条形码大小", UILabel.LEFT), barWidthContainer, barHeightContainer},
new Component[]{null, new UILabel(Inter.getLocText("Tree-Width"), UILabel.CENTER), new UILabel(Inter.getLocText("Height"), UILabel.CENTER)},
new Component[]{new UILabel(Inter.getLocText("FR-Designer_Barcode_Size"), UILabel.LEFT), barWidthContainer, barHeightContainer},
new Component[]{null, new UILabel(Inter.getLocText("FR-Designer-Tree_Width"), UILabel.CENTER), new UILabel(Inter.getLocText("FR-Designer_Height"), UILabel.CENTER)},
new Component[]{drawingTextCheckBox, null, null}
};
JPanel normalPane = TableLayoutHelper.createTableLayoutPane(components_normal, rowSize, columnSize1);
JPanel normalPane = TableLayoutHelper.createGapTableLayoutPane(components_normal, rowSize, columnSize, rowCount, LayoutConstants.VGAP_LARGE, LayoutConstants.VGAP_LARGE);
return normalPane;
}
@ -167,17 +172,21 @@ public class BarCodePane extends FurtherBasicBeanPane<BarcodePresent> {
private JPanel getSpecialPane() {
double p = TableLayout.PREFERRED;
double f = TableLayout.FILL;
double[] columnSize1 = {p, p};
double[] columnSize = {p, p};
double[] rowSize = {p, p, p, p, p, p, p, p};
UILabel uiLabel = new UILabel(Inter.getLocText("RCodeVersion") + ":", UILabel.RIGHT);
int[][] rowCount = {{1, 1}, {1, 1}, {1, 1}, {1, 1}, {1, 1}, {1, 1}, {1, 1}, {1, 1}};
UILabel uiLabel = new UILabel(Inter.getLocText("RCodeVersion"), UILabel.LEFT);
uiLabel.setPreferredSize(typeSetLabel.getPreferredSize());
RCodeVersionComboBox.setPreferredSize(new Dimension(155,20));
RCodeErrorCorrectComboBox.setPreferredSize(new Dimension(155,20));
RCodesizespinner.setPreferredSize(new Dimension(155,20));
Component[][] components_special = new Component[][]{
new Component[]{uiLabel, RCodeVersionComboBox},
new Component[]{new UILabel(Inter.getLocText("RCodeErrorCorrect") + ":", UILabel.RIGHT), RCodeErrorCorrectComboBox},
new Component[]{new UILabel(Inter.getLocText("RCodeDrawPix") + ":", UILabel.RIGHT), RCodesizespinner}
new Component[]{new UILabel(Inter.getLocText("RCodeErrorCorrect"), UILabel.LEFT), RCodeErrorCorrectComboBox},
new Component[]{new UILabel(Inter.getLocText("RCodeDrawPix"), UILabel.LEFT), RCodesizespinner}
};
JPanel specialPane = TableLayoutHelper.createTableLayoutPane(components_special, rowSize, columnSize1);
JPanel specialPane = TableLayoutHelper.createGapTableLayoutPane(components_special, rowSize, columnSize, rowCount, LayoutConstants.VGAP_LARGE, LayoutConstants.VGAP_LARGE);
return specialPane;
}

9
designer/src/com/fr/design/widget/ui/BasicWidgetPropertySettingPane.java

@ -24,15 +24,18 @@ public class BasicWidgetPropertySettingPane extends BasicPane {
public BasicWidgetPropertySettingPane() {
this.setLayout(new BorderLayout());
enableCheckBox = new UICheckBox(Inter.getLocText("FR-Designer_Visible"), true);
enableCheckBox.setBorder(BorderFactory.createEmptyBorder(0,0,0,0));
visibleCheckBox = new UICheckBox(Inter.getLocText("FR-Designer_Widget-Visible"), true);
enableCheckBox.setBorder(BorderFactory.createEmptyBorder(0, 0, 0, 0));
visibleCheckBox.setBorder(BorderFactory.createEmptyBorder(0, 0, 0, 0));
visibleCheckBox.setBorder(BorderFactory.createEmptyBorder(0,0,0,0));
widgetNameComboBox = new ParameterTreeComboBox();
widgetNameComboBox.refreshTree();
JPanel widgetNamePane = new JPanel(new BorderLayout());
widgetNamePane.add(widgetNameComboBox, BorderLayout.CENTER);
widgetNamePane.setBorder(BorderFactory.createEmptyBorder(0,20,0,0));
double f = TableLayout.FILL;
double p = TableLayout.PREFERRED;
Component[][] components = new Component[][]{
new Component[]{new UILabel(Inter.getLocText("FR-Designer_Form-Widget_Name") + " "), widgetNameComboBox},
new Component[]{new UILabel(Inter.getLocText("FR-Designer_Form-Widget_Name")), widgetNamePane},
new Component[]{enableCheckBox, null},
new Component[]{visibleCheckBox, null},
};

1
designer/src/com/fr/design/widget/ui/DirectWriteEditorDefinePane.java

@ -24,7 +24,6 @@ public abstract class DirectWriteEditorDefinePane<T extends DirectWriteEditor> e
JPanel contentPane = FRGUIPaneFactory.createBorderLayout_S_Pane();
contentPane.setBorder(BorderFactory.createEmptyBorder(0, 2, 0, 0));
directWriteCheckBox = new UICheckBox(Inter.getLocText("Form-Allow_Edit"), false);
directWriteCheckBox.setBorder(BorderFactory.createEmptyBorder(0, 0, 0, 0));
directWriteCheckBox.setPreferredSize(new Dimension(100, 30));
waterMarkDictPane = new WaterMarkDictPane();

3
designer/src/com/fr/design/widget/ui/IframeEditorDefinePane.java

@ -1,5 +1,6 @@
package com.fr.design.widget.ui;
import com.fr.base.FRContext;
import com.fr.design.constants.LayoutConstants;
import com.fr.design.dialog.DialogActionListener;
import com.fr.design.dialog.UIDialog;
@ -83,7 +84,7 @@ public class IframeEditorDefinePane extends AbstractDataModify<IframeEditor> {
try {
pr = (ParameterProvider) parameterProvider.clone();
} catch (CloneNotSupportedException e1) {
e1.printStackTrace();
FRContext.getLogger().error(e1.getMessage(), e1);
}
list.add(pr);
}

10
designer/src/com/fr/design/widget/ui/NumberEditorDefinePane.java

@ -156,14 +156,12 @@ public class NumberEditorDefinePane extends FieldEditorDefinePane<NumberEditor>
@Override
protected JPanel setFirstContentPane() {
JPanel content = FRGUIPaneFactory.createY_AXISBoxInnerContainer_L_Pane();
content.setBorder(BorderFactory.createEmptyBorder(0, 0, 0, 0));
content.setLayout(FRGUIPaneFactory.createBorderLayout());
// richer:数字的允许直接编辑没有意义
JPanel content = FRGUIPaneFactory.createBorderLayout_S_Pane();
waterMarkDictPane = new WaterMarkDictPane();
waterMarkDictPane.setBorder(BorderFactory.createEmptyBorder(0, 0, 10, 0));
content.add(waterMarkDictPane, BorderLayout.CENTER);
return waterMarkDictPane;
return content;
}

10
designer/src/com/fr/design/widget/ui/TextFieldEditorDefinePane.java

@ -58,18 +58,18 @@ public class TextFieldEditorDefinePane extends FieldEditorDefinePane<TextEditor>
}
});
JPanel jPanel = FRGUIPaneFactory.createBorderLayout_S_Pane();
jPanel.add(waterMarkDictPane, BorderLayout.CENTER);
JPanel content = FRGUIPaneFactory.createBorderLayout_S_Pane();
waterMarkDictPane.setBorder(BorderFactory.createEmptyBorder(0, 0, 10, 0));
return jPanel;
content.add(waterMarkDictPane, BorderLayout.CENTER);
return content;
}
public JPanel setValidatePane(){
public JPanel setValidatePane() {
return regPane;
}
protected RegPane createRegPane() {
return new RegPane();
}

13
designer/src/com/fr/design/widget/ui/WaterMarkDictPane.java

@ -1,18 +1,16 @@
package com.fr.design.widget.ui;
import java.awt.*;
import java.awt.event.KeyListener;
import com.fr.design.gui.ilable.UILabel;
import javax.swing.*;
import com.fr.design.gui.itextfield.UITextField;
import com.fr.design.layout.TableLayout;
import com.fr.design.layout.TableLayoutHelper;
import com.fr.form.ui.WaterMark;
import com.fr.general.Inter;
import javax.swing.*;
import java.awt.*;
import java.awt.event.KeyListener;
public class WaterMarkDictPane extends JPanel {
private UITextField waterMarkTextField;
@ -25,7 +23,7 @@ public class WaterMarkDictPane extends JPanel {
waterMarkTextField = new UITextField(13);
UILabel emptyLabel = new UILabel();
emptyLabel.setBorder(BorderFactory.createEmptyBorder(0, 33, 0, 0));
emptyLabel.setBorder(BorderFactory.createEmptyBorder(0, 30, 0, 0));
double f = TableLayout.FILL;
double p = TableLayout.PREFERRED;
@ -36,7 +34,6 @@ public class WaterMarkDictPane extends JPanel {
double[] columnSize = {p, p, f};
int[][] rowCount = {{1, 1}};
JPanel panel = TableLayoutHelper.createTableLayoutPane(components, rowSize, columnSize);
// JPanel panel = TableLayoutHelper.createGapTableLayoutPane(components, rowSize, columnSize, rowCount, LayoutConstants.VGAP_LARGE, LayoutConstants.VGAP_MEDIUM);
panel.setBorder(BorderFactory.createEmptyBorder(10, 0, 0, 0));
this.add(panel, BorderLayout.CENTER);
}

2
designer/src/com/fr/quickeditor/floatquick/FloatImageQuickEditor.java

@ -42,7 +42,7 @@ public class FloatImageQuickEditor extends FloatQuickEditor {
JPanel pane = TableLayoutHelper.createTableLayoutPane(components, rowSize, columnSize);
this.setLayout(new BorderLayout());
this.setBorder(BorderFactory.createEmptyBorder(10, 78, 10, 17));
this.setBorder(BorderFactory.createEmptyBorder(10, 75, 10, 15));
this.add(pane, BorderLayout.CENTER);

7
designer/src/com/fr/quickeditor/floatquick/FloatStringQuickEditor.java

@ -4,6 +4,7 @@ import com.fr.base.BaseUtils;
import com.fr.base.Formula;
import com.fr.base.Style;
import com.fr.base.TextFormat;
import com.fr.design.constants.UIConstants;
import com.fr.design.file.HistoryTemplateListPane;
import com.fr.design.gui.ibutton.UIButton;
import com.fr.design.mainframe.ElementCasePane;
@ -37,7 +38,7 @@ public class FloatStringQuickEditor extends FloatQuickEditor {
JPanel pane = new JPanel(new BorderLayout(5, 0));
pane.add(stringTextField, BorderLayout.CENTER);
pane.add(formulaButton, BorderLayout.EAST);
pane.setBorder(BorderFactory.createEmptyBorder(0,0,0,7));
pane.setBorder(BorderFactory.createEmptyBorder(0,0,0,5));
formulaButton.setVisible(false);
this.setLayout(new BorderLayout());
this.setBorder(BorderFactory.createEmptyBorder(10, 10, 10, 10));
@ -50,7 +51,7 @@ public class FloatStringQuickEditor extends FloatQuickEditor {
stringTextField.setLineWrap(true);
stringTextField.setWrapStyleWord(true);
stringTextField.setMargin(new Insets(5, 5, 5, 5));
stringTextField.setBorder(BorderFactory.createLineBorder(Color.gray));
stringTextField.setBorder(BorderFactory.createLineBorder(UIConstants.POP_DIALOG_BORDER));
stringTextField.setBackground(Color.WHITE);
}
@ -73,7 +74,7 @@ public class FloatStringQuickEditor extends FloatQuickEditor {
Formula formula = (Formula) value;
str = formula.getContent();
stringTextField.setLineWrap(false);
this.setBorder(BorderFactory.createEmptyBorder(10, 78, 10, 10));
this.setBorder(BorderFactory.createEmptyBorder(10, 75, 10, 10));
reserveInResult = formula.isReserveInResult();
reserveOnWriteOrAnaly = formula.isReserveOnWriteOrAnaly();
} else {

1
designer_base/src/com/fr/design/constants/UIConstants.java

@ -19,6 +19,7 @@ public interface UIConstants {
public static final Icon BLACK_ICON = BaseUtils.readIcon("/com/fr/base/images/cell/blank.gif");
public static final Border CELL_ATTR_ZEROBORDER = BorderFactory.createEmptyBorder(0 ,0, 0, 0);
public static final Border CELL_ATTR_EMPTYBORDER = BorderFactory.createEmptyBorder(0 ,10, 0, 0);
public static final Border CELL_ATTR_NORMALBORDER = BorderFactory.createEmptyBorder(0 ,10, 0, 15);

11
designer_base/src/com/fr/design/gui/style/FRFontPane.java

@ -302,12 +302,13 @@ public class FRFontPane extends AbstractBasicStylePane implements GlobalNameObse
double f = TableLayout.FILL;
double[] columnSize = {p};
double[] rowSize = {p, p, p};
int[][] rowCount = {{1, 1}, {1, 1}, {1, 1}};
Component[][] components = new Component[][]{
new Component[]{fontSizeStyleComboBox},
new Component[]{buttonPane},
new Component[]{createLinePane()}
};
return TableLayoutHelper.createTableLayoutPane(components, rowSize, columnSize);
return TableLayoutHelper.createGapTableLayoutPane(components, rowSize, columnSize, rowCount, LayoutConstants.VGAP_MEDIUM, LayoutConstants.VGAP_MEDIUM);
}
private JPanel createRightPane() {
@ -315,17 +316,19 @@ public class FRFontPane extends AbstractBasicStylePane implements GlobalNameObse
double f = TableLayout.FILL;
double[] columnSize = {f};
double[] rowSize = {p, p};
int[][] rowCount = {{1, 1}, {1, 1}};
Component[][] components = new Component[][]{
new Component[]{fontSizeComboBox},
new Component[]{isSuperOrSubPane}
};
return TableLayoutHelper.createTableLayoutPane(components, rowSize, columnSize);
return TableLayoutHelper.createGapTableLayoutPane(components, rowSize, columnSize, rowCount, LayoutConstants.VGAP_MEDIUM, LayoutConstants.VGAP_MEDIUM);
}
private JPanel createPane() {
JPanel createPane = new JPanel(new BorderLayout(3, 5));
JPanel createPane = new JPanel(new BorderLayout());
createPane.add(fontNameComboBox, BorderLayout.NORTH);
JPanel jPanel = TableLayoutHelper.createGapTableLayoutPane(new Component[][]{new Component[]{createLeftPane(), createRightPane()}}, TableLayoutHelper.FILL_LASTCOLUMN, 5, 7);
JPanel jPanel = TableLayoutHelper.createGapTableLayoutPane(new Component[][]{new Component[]{createLeftPane(), createRightPane()}}, TableLayoutHelper.FILL_LASTCOLUMN, LayoutConstants.VGAP_LARGE, LayoutConstants.VGAP_LARGE);
jPanel.setBorder(BorderFactory.createEmptyBorder(10, 0, 0, 0));
createPane.add(jPanel, BorderLayout.CENTER);
return createPane;
}

40
designer_base/src/com/fr/design/gui/style/FormatPane.java

@ -42,6 +42,7 @@ public class FormatPane extends AbstractBasicStylePane {
private static final int LABLE_DELTA_WIDTH = 8;
private static final int LABLE_HEIGHT = 15; //标签背景的范围
private static final int CURRENCY_FLAG_POINT = 6;
private static final Border LEFT_BORDER = BorderFactory.createEmptyBorder(0,30,0,0);
private static final Integer[] TYPES = new Integer[]{FormatContents.NULL, FormatContents.NUMBER, FormatContents.CURRENCY, FormatContents.PERCENT, FormatContents.SCIENTIFIC,
FormatContents.DATE, FormatContents.TIME, FormatContents.TEXT};
@ -76,7 +77,7 @@ public class FormatPane extends AbstractBasicStylePane {
contentPane = new JPanel(new BorderLayout(0, 4)) {
@Override
public Dimension getPreferredSize() {
return new Dimension(super.getPreferredSize().width, 70);
return new Dimension(super.getPreferredSize().width, 65);
}
};
typeComboBox = new UIComboBox(types);
@ -84,37 +85,44 @@ public class FormatPane extends AbstractBasicStylePane {
typeComboBox.setRenderer(render);
typeComboBox.addItemListener(itemListener);
contentPane.add(sampleLabel, BorderLayout.NORTH);
centerPane = new JPanel(new CardLayout());
centerPane.add(new JPanel(), "hide");
centerPane.setPreferredSize(new Dimension(0, 0));
centerPane.add(contentPane, "show");
formatFontPane = new JPanel(new BorderLayout());
formatFontPane.add(centerPane, BorderLayout.NORTH);
formatFontPane.add(new FRFontPane(), BorderLayout.CENTER);
txtCenterPane = FRGUIPaneFactory.createBorderLayout_S_Pane();
contentPane.add(txtCenterPane, BorderLayout.CENTER);
txtCenterPane = new JPanel(new BorderLayout());
textField = new UIComboBox(FormatField.getInstance().getFormatArray(getFormatContents()));
textField.addItemListener(textFieldItemListener);
textField.setEditable(true);
txtCenterPane.add(textField, BorderLayout.NORTH);
contentPane.add(txtCenterPane, BorderLayout.CENTER);
centerPane = new JPanel(new CardLayout());
centerPane.add(new JPanel(), "hide");
centerPane.setPreferredSize(new Dimension(0, 0));
centerPane.add(contentPane, "show");
frFontPane = new FRFontPane();
UILabel font = new UILabel(Inter.getLocText("FR-Designer_FRFont"), SwingConstants.LEFT);
JPanel fontPane = new JPanel(new BorderLayout());
fontPane.add(font, BorderLayout.NORTH);
double f = TableLayout.FILL;
double p = TableLayout.PREFERRED;
typeComboBox.setPreferredSize(new Dimension(155,20));
JPanel typePane = new JPanel(new BorderLayout());
typePane.add(typeComboBox, BorderLayout.CENTER);
typePane.setBorder(LEFT_BORDER);
centerPane.setBorder(LEFT_BORDER);
frFontPane.setBorder(LEFT_BORDER);
Component[][] components = new Component[][]{
new Component[]{null, null},
new Component[]{new UILabel(Inter.getLocText("FR-Base_Format") + " ", SwingConstants.LEFT), typeComboBox},
new Component[]{new UILabel(Inter.getLocText("FR-Base_Format"), SwingConstants.LEFT), typePane},
new Component[]{null, centerPane},
new Component[]{fontPane, frFontPane},
new Component[]{null, null}
};
double[] rowSize = {p, p, p, p, p};
double[] columnSize = {p, f};
int[][] rowCount = {{1, 1}, {1, 1}, {1, 1}, {1, 3}, {1, 1}};
JPanel panel = TableLayoutHelper.createGapTableLayoutPane(components, rowSize, columnSize, rowCount, LayoutConstants.VGAP_SMALL, LayoutConstants.VGAP_MEDIUM);
int[][] rowCount = {{1, 1}, {1, 1}, {1, 1}, {1, 1}, {1, 1}};
JPanel panel = TableLayoutHelper.createGapTableLayoutPane(components, rowSize, columnSize, rowCount, LayoutConstants.VGAP_LARGE, LayoutConstants.VGAP_MEDIUM);
this.add(panel, BorderLayout.CENTER);
}
@ -310,7 +318,7 @@ public class FormatPane extends AbstractBasicStylePane {
for (int i = 0; i < items.length; i++) {
textField.addItem(items[i]);
}
centerPane.setPreferredSize(new Dimension(270, 70));
centerPane.setPreferredSize(new Dimension(270, 65));
cardLayout.show(centerPane, "show");
}
isFormat = true;

7
designer_base/src/com/fr/design/locale/designer.properties

@ -2120,6 +2120,7 @@ FR-Designer_Widget_Display_Position=Display Position
FR-Designer_Size_Limit=Size_Limit
FR-Designer_Widget_Name=Widget Name
FR-Designer_Coords_And_Size=Coords & Size
FS-Designer_DS_Filter_Odd_Tip=\
FS-Designer_DS_Filter_Even_Tip=\
FS-Designer_DS_Filter_Specify_Tip=\
FR-Designer_Barcode_Size=Barcode_Size
FS-Designer_DS_Filter_Odd_Tip=Odd_Tip
FS-Designer_DS_Filter_Even_Tip=Even_Tip
FS-Designer_DS_Filter_Specify_Tip=Specify_Tip

7
designer_base/src/com/fr/design/locale/designer_en_US.properties

@ -2116,6 +2116,7 @@ FR-Designer_Widget_Display_Position=Display Position
FR-Designer_Size_Limit=Size_Limit
FR-Designer_Widget_Name=Widget Name
FR-Designer_Coords_And_Size=Coords & Size
FS-Designer_DS_Filter_Odd_Tip=\
FS-Designer_DS_Filter_Even_Tip=\
FS-Designer_DS_Filter_Specify_Tip=\
FR-Designer_Barcode_Size=Barcode_Size
FS-Designer_DS_Filter_Odd_Tip=Odd_Tip
FS-Designer_DS_Filter_Even_Tip=Even_Tip
FS-Designer_DS_Filter_Specify_Tip=Specify_Tip

9
designer_base/src/com/fr/design/locale/designer_ja_JP.properties

@ -2109,7 +2109,7 @@ FR-Designer_Use_Params_Template=
FR-Designer_Label_Name=
FR-Designer_Insert_Formula=
FR-Designer_Not_Support_Authority_Edit=\u3053\u306E\u8981\u7D20\u306F\u6A29\u9650\u5236\u5FA1\u3092\u30B5\u30DD\u30FC\u30C8\u3057\u3066\u3044\u307E\u305B\u3093
FR-Designer_Dynamic_Parameter=\
FR-Designer_Dynamic_Parameter=
FR-Designer_Remove_Item=
FR-Designer_Widget_No_Repeat=
FR-Designer_Widget_Error_Tip=
@ -2119,6 +2119,7 @@ FR-Designer_Widget_Display_Position=
FR-Designer_Size_Limit=
FR-Designer_Widget_Name=
FR-Designer_Coords_And_Size=
FS-Designer_DS_Filter_Odd_Tip=\
FS-Designer_DS_Filter_Even_Tip=\
FS-Designer_DS_Filter_Specify_Tip=\
FR-Designer_Barcode_Size=
FS-Designer_DS_Filter_Odd_Tip=
FS-Designer_DS_Filter_Even_Tip=
FS-Designer_DS_Filter_Specify_Tip=

9
designer_base/src/com/fr/design/locale/designer_ko_KR.properties

@ -2109,7 +2109,7 @@ FR-Designer_Use_Params_Template=
FR-Designer_Label_Name=
FR-Designer_Add_Event=
FR-Designer_Not_Support_Authority_Edit=\uD574\uB2F9\uC694\uC18C\uB294\uAD8C\uD55C\uCEE8\uD2B8\uB864\uC744\uC9C0\uC6D0\uD558\uC9C0\uC54A\uC2B5\uB2C8\uB2E4.
FR-Designer_Dynamic_Parameter=\
FR-Designer_Dynamic_Parameter=
FR-Designer_Remove_Item=
FR-Designer_Widget_No_Repeat=
FR-Designer_Widget_Error_Tip=
@ -2119,6 +2119,7 @@ FR-Designer_Widget_Display_Position=
FR-Designer_Size_Limit=
FR-Designer_Widget_Name=
FR-Designer_Coords_And_Size=
FS-Designer_DS_Filter_Odd_Tip=\
FS-Designer_DS_Filter_Even_Tip=\
FS-Designer_DS_Filter_Specify_Tip=\
FR-Designer_Barcode_Size=
FS-Designer_DS_Filter_Odd_Tip=
FS-Designer_DS_Filter_Even_Tip=
FS-Designer_DS_Filter_Specify_Tip=

1
designer_base/src/com/fr/design/locale/designer_zh_CN.properties

@ -2127,6 +2127,7 @@ FR-Designer_Widget_Display_Position=\u663E\u793A\u4F4D\u7F6E
FR-Designer_Size_Limit=\u5927\u5C0F\u9650\u5236
FR-Designer_Widget_Name=\u63A7\u4EF6\u540D\u79F0
FR-Designer_Coords_And_Size=\u5750\u6807\u00B7\u5C3A\u5BF8
FR-Designer_Barcode_Size=\u6761\u5F62\u7801\u5927\u5C0F
FS-Designer_DS_Filter_Odd_Tip=\u63D0\u793A\uFF1A\u5E8F\u53F7\u4ECE1\u5F00\u59CB\uFF0C\u9009\u62E9\u4E86\u5947\u6570\u96C6(1,3,5...)
FS-Designer_DS_Filter_Even_Tip=\u63D0\u793A\uFF1A\u5E8F\u53F7\u4ECE1\u5F00\u59CB\uFF0C\u9009\u62E9\u4E86\u5076\u6570\u96C6(2,4,6...)
FS-Designer_DS_Filter_Specify_Tip=\u63D0\u793A\uFF1A\u683C\u5F0F\u4E3A1,2-3,5,8\uFF0C\u5E8F\u53F7\u4ECE1\u5F00\u59CB\uFF0C\u5185\u503C\u53C2\u6570$_count_\u8868\u793A\u603B\u4E2A\u6570

1
designer_base/src/com/fr/design/locale/designer_zh_TW.properties

@ -2119,6 +2119,7 @@ FR-Designer_Widget_Display_Position=
FR-Designer_Size_Limit=
FR-Designer_Widget_Name=
FR-Designer_Coords_And_Size=
FR-Designer_Barcode_Size=
FS-Designer_DS_Filter_Odd_Tip=\u63D0\u793A\uFF1A\u5E8F\u865F\u5F9E1\u958B\u59CB\uFF0C\u9078\u64C7\u4E86\u5947\u6578\u96C6(1,3,5...)
FS-Designer_DS_Filter_Even_Tip=\u63D0\u793A\uFF1A\u5E8F\u865F\u5F9E1\u958B\u59CB\uFF0C\u9078\u64C7\u4E86\u5076\u6578\u96C6(2,4,6...)
FS-Designer_DS_Filter_Specify_Tip=\u63D0\u793A\uFF1A\u683C\u5F0F\u70BA1,2-3,5,8\uFF0C\u5E8F\u865F\u5F9E1\u958B\u59CB\uFF0C\u5185\u7F6E\u53C3\u6578$_count_\u8868\u793A\u7E02\u500B\u6578

25
designer_base/src/com/fr/design/present/dict/FormulaDictPane.java

@ -4,6 +4,7 @@ import com.fr.base.BaseUtils;
import com.fr.base.Formula;
import com.fr.data.impl.FormulaDictionary;
import com.fr.design.beans.FurtherBasicBeanPane;
import com.fr.design.constants.LayoutConstants;
import com.fr.design.editor.editor.FormulaEditor;
import com.fr.design.gui.ilable.UILabel;
import com.fr.design.layout.TableLayout;
@ -40,8 +41,9 @@ public class FormulaDictPane extends FurtherBasicBeanPane<FormulaDictionary> {
private void initComponents() {
keyFormulaEditor = new FormulaEditor();
keyFormulaEditor.setColumns(EDITOR_COLUMN);
JPanel keyFormulaContainer = new JPanel(new FlowLayout(FlowLayout.RIGHT));
keyFormulaEditor.setPreferredSize(new Dimension(148, 20));
JPanel keyFormulaContainer = new JPanel(new FlowLayout(FlowLayout.RIGHT, 5, 0));
keyFormulaContainer.setBorder(BorderFactory.createEmptyBorder(0,-5,0,-5));
keyFormulaEditor.setPreferredSize(new Dimension(144, 20));
Icon icon = BaseUtils.readIcon("/com/fr/design/images/m_insert/formula.png");
keyFormulaContainer.add(new JLabel(icon));
keyFormulaContainer.add(keyFormulaEditor);
@ -52,30 +54,31 @@ public class FormulaDictPane extends FurtherBasicBeanPane<FormulaDictionary> {
double p = TableLayout.PREFERRED;
double f = TableLayout.FILL;
double[] columnSize = {p, f};
double[] rowSize = {p, p, p, p, p, p};
double[] rowSize = {p, p, p};
int[][] rowCount = {{1, 1}, {1, 1}, {1, 1}};
UILabel tag = new UILabel(Inter.getLocText("Formula_Dictionary_Display_Examples_Html"));
tag.setPreferredSize(new Dimension(225,20));
JPanel t = new JPanel(new BorderLayout());
t.add(tag, BorderLayout.NORTH);
t.add(tag, BorderLayout.CENTER);
Formula vf = new Formula("$$$");
valueFormulaEditor = new FormulaEditor("", vf);
JPanel valueFormulaContainer = new JPanel(new FlowLayout(FlowLayout.RIGHT));
valueFormulaEditor.setPreferredSize(new Dimension(148, 20));
JPanel valueFormulaContainer = new JPanel(new FlowLayout(FlowLayout.RIGHT, 5, 0));
valueFormulaContainer.setBorder(BorderFactory.createEmptyBorder(0,-5,0,-5));
valueFormulaEditor.setPreferredSize(new Dimension(144, 20));
valueFormulaContainer.add(new JLabel(icon));
valueFormulaContainer.add(valueFormulaEditor);
Component[][] components = new Component[][]{
new Component[]{null, null},
new Component[]{new UILabel(Inter.getLocText("FR-Designer_Actual_Value"), UILabel.LEFT), keyFormulaContainer},
new Component[]{null, null},
new Component[]{new UILabel(Inter.getLocText("FR-Designer_Display_Value"), UILabel.LEFT), valueFormulaContainer},
new Component[]{null, null},
new Component[]{t, null}
new Component[]{tag, null}
};
JPanel panel = TableLayoutHelper.createTableLayoutPane(components, rowSize, columnSize);
JPanel panel = TableLayoutHelper.createGapTableLayoutPane(components, rowSize, columnSize, rowCount, LayoutConstants.VGAP_LARGE, LayoutConstants.VGAP_LARGE);
this.setLayout(new BorderLayout());
this.add(panel, BorderLayout.CENTER);

Loading…
Cancel
Save