yaoh.wu 8 years ago
parent
commit
cf45782905
  1. 49
      designer_base/src/com/fr/design/gui/style/BorderPane.java
  2. 4
      designer_base/src/com/fr/design/locale/designer.properties
  3. 4
      designer_base/src/com/fr/design/locale/designer_en_US.properties
  4. 6
      designer_base/src/com/fr/design/locale/designer_ja_JP.properties
  5. 6
      designer_base/src/com/fr/design/locale/designer_ko_KR.properties
  6. 6
      designer_base/src/com/fr/design/locale/designer_zh_CN.properties
  7. 6
      designer_base/src/com/fr/design/locale/designer_zh_TW.properties
  8. 13
      designer_base/src/com/fr/design/mainframe/backgroundpane/PatternBackgroundQuickPane.java

49
designer_base/src/com/fr/design/gui/style/BorderPane.java

@ -51,34 +51,16 @@ public class BorderPane extends AbstractBasicStylePane {
} }
protected void initComponents() { protected void initComponents() {
topToggleButton = new UIToggleButton(BaseUtils.readIcon("/com/fr/base/images/dialog/border/top.png")); initButtonsWithIcon();
leftToggleButton = new UIToggleButton(BaseUtils.readIcon("/com/fr/base/images/dialog/border/left.png"));
bottomToggleButton = new UIToggleButton(BaseUtils.readIcon("/com/fr/base/images/dialog/border/bottom.png"));
rightToggleButton = new UIToggleButton(BaseUtils.readIcon("/com/fr/base/images/dialog/border/right.png"));
horizontalToggleButton = new UIToggleButton(BaseUtils.readIcon("/com/fr/base/images/dialog/border/horizontal.png"));
verticalToggleButton = new UIToggleButton(BaseUtils.readIcon("/com/fr/base/images/dialog/border/vertical.png"));
this.currentLineCombo = new LineComboBox(CoreConstants.UNDERLINE_STYLE_ARRAY);
this.currentLineColorPane = new NewColorSelectBox(100);
this.setLayout(new BorderLayout(0, 6)); this.setLayout(new BorderLayout(0, 6));
double p = TableLayout.PREFERRED, f = TableLayout.FILL;
double p = TableLayout.PREFERRED; double[] columnSize1 = {p, f}, rowSize1 = {p, p};
double f = TableLayout.FILL;
double[] columnSize1 = {p, f};
double[] rowSize1 = {p, p};
Component[][] components1 = new Component[][]{ Component[][] components1 = new Component[][]{
new Component[]{new UILabel(Inter.getLocText("Style") + ":"), currentLineCombo}, new Component[]{new UILabel(Inter.getLocText("FR-Designer_Style") + ":"), currentLineCombo},
new Component[]{new UILabel(Inter.getLocText("Color") + ":"), currentLineColorPane}, new Component[]{new UILabel(Inter.getLocText("FR-Designer_Color") + ":"), currentLineColorPane},
}; };
JPanel northPane = TableLayoutHelper.createTableLayoutPane(components1, rowSize1, columnSize1); JPanel northPane = TableLayoutHelper.createTableLayoutPane(components1, rowSize1, columnSize1);
double[] columnSize2 = {p, f}, rowSize2 = {p, p};
double[] columnSize2 = {p, f};
double[] rowSize2 = {p, p};
JPanel externalPane = new JPanel(new GridLayout(0, 4)); JPanel externalPane = new JPanel(new GridLayout(0, 4));
externalPane.add(topToggleButton); externalPane.add(topToggleButton);
externalPane.add(leftToggleButton); externalPane.add(leftToggleButton);
@ -87,20 +69,15 @@ public class BorderPane extends AbstractBasicStylePane {
JPanel insidePane = new JPanel(new GridLayout(0, 2)); JPanel insidePane = new JPanel(new GridLayout(0, 2));
insidePane.add(horizontalToggleButton); insidePane.add(horizontalToggleButton);
insidePane.add(verticalToggleButton); insidePane.add(verticalToggleButton);
Component[][] components2 = new Component[][]{ Component[][] components2 = new Component[][]{
new Component[]{outerToggleButton = new UIToggleButton(BaseUtils.readIcon("com/fr/design/images/m_format/out.png")), innerToggleButton = new UIToggleButton(BaseUtils.readIcon("com/fr/design/images/m_format/in.png"))}, new Component[]{outerToggleButton = new UIToggleButton(BaseUtils.readIcon("com/fr/design/images/m_format/out.png")), innerToggleButton = new UIToggleButton(BaseUtils.readIcon("com/fr/design/images/m_format/in.png"))},
new Component[]{externalPane, insidePane,} new Component[]{externalPane, insidePane,}
}; };
JPanel centerPane = TableLayoutHelper.createTableLayoutPane(components2, rowSize2, columnSize2); JPanel centerPane = TableLayoutHelper.createTableLayoutPane(components2, rowSize2, columnSize2);
this.setLayout(new BorderLayout(0, 6)); this.setLayout(new BorderLayout(0, 6));
this.add(northPane, BorderLayout.NORTH); this.add(northPane, BorderLayout.NORTH);
this.add(centerPane, BorderLayout.CENTER); this.add(centerPane, BorderLayout.CENTER);
outerToggleButton.addChangeListener(new ChangeListener() { outerToggleButton.addChangeListener(new ChangeListener() {
@Override @Override
public void stateChanged(ChangeEvent e) { public void stateChanged(ChangeEvent e) {
boolean value = outerToggleButton.isSelected(); boolean value = outerToggleButton.isSelected();
@ -110,9 +87,7 @@ public class BorderPane extends AbstractBasicStylePane {
rightToggleButton.setSelected(value); rightToggleButton.setSelected(value);
} }
}); });
innerToggleButton.addChangeListener(new ChangeListener() { innerToggleButton.addChangeListener(new ChangeListener() {
@Override @Override
public void stateChanged(ChangeEvent e) { public void stateChanged(ChangeEvent e) {
boolean value = innerToggleButton.isSelected(); boolean value = innerToggleButton.isSelected();
@ -120,12 +95,22 @@ public class BorderPane extends AbstractBasicStylePane {
verticalToggleButton.setSelected(value); verticalToggleButton.setSelected(value);
} }
}); });
}
private void initButtonsWithIcon(){
topToggleButton = new UIToggleButton(BaseUtils.readIcon("/com/fr/base/images/dialog/border/top.png"));
leftToggleButton = new UIToggleButton(BaseUtils.readIcon("/com/fr/base/images/dialog/border/left.png"));
bottomToggleButton = new UIToggleButton(BaseUtils.readIcon("/com/fr/base/images/dialog/border/bottom.png"));
rightToggleButton = new UIToggleButton(BaseUtils.readIcon("/com/fr/base/images/dialog/border/right.png"));
horizontalToggleButton = new UIToggleButton(BaseUtils.readIcon("/com/fr/base/images/dialog/border/horizontal.png"));
verticalToggleButton = new UIToggleButton(BaseUtils.readIcon("/com/fr/base/images/dialog/border/vertical.png"));
this.currentLineCombo = new LineComboBox(CoreConstants.UNDERLINE_STYLE_ARRAY);
this.currentLineColorPane = new NewColorSelectBox(100);
} }
@Override @Override
public String title4PopupWindow() { public String title4PopupWindow() {
return Inter.getLocText("Border"); return Inter.getLocText("FR-Designer_Border");
} }
public void populate(Style style) { public void populate(Style style) {

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

@ -596,3 +596,7 @@ FR-Designer_AxisReversed=AxisValue
FR-Designer_Logarithmic=Logarithmic FR-Designer_Logarithmic=Logarithmic
FR-Designer_Chart_Log_Base=Log Base FR-Designer_Chart_Log_Base=Log Base
FR-Designer_Chart_F_Radar_Axis=Chart_F_Radar_Axis FR-Designer_Chart_F_Radar_Axis=Chart_F_Radar_Axis
FR-Designer_Style=Style
FR-Designer_Color=Color
FR-Designer_Border=Border
FR-Designer_Background-Pattern=Pattern

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

@ -596,4 +596,8 @@ FR-Designer_AxisReversed=Axis in reverse order
FR-Designer_Logarithmic=Log scale FR-Designer_Logarithmic=Log scale
FR-Designer_Chart_Log_Base=Log Base FR-Designer_Chart_Log_Base=Log Base
FR-Designer_Chart_F_Radar_Axis=Value Axis FR-Designer_Chart_F_Radar_Axis=Value Axis
FR-Designer_Style=Style
FR-Designer_Color=Color
FR-Designer_Border=Border
FR-Designer_Background-Pattern=Pattern

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

@ -560,4 +560,8 @@ FR-Designer_Plugin_Should_Update_Please_Contact_Developer=
FR-Designer_AxisReversed=\u8EF8\u9006\u9806 FR-Designer_AxisReversed=\u8EF8\u9006\u9806
FR-Designer_Logarithmic=\u5BFE\u6570\u76EE\u76DB\u308A FR-Designer_Logarithmic=\u5BFE\u6570\u76EE\u76DB\u308A
FR-Designer_Chart_Log_Base=\u5E95\u6570 FR-Designer_Chart_Log_Base=\u5E95\u6570
FR-Designer_Chart_F_Radar_Axis=\u5782\u76F4\u8EF8 FR-Designer_Chart_F_Radar_Axis=\u5782\u76F4\u8EF8
FR-Designer_Style=\u30B9\u30BF\u30A4\u30EB
FR-Designer_Color=\u8272
FR-Designer_Border=\u67A0
FR-Designer_Background-Pattern=\u30D1\u30BF\u30FC\u30F3

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

@ -555,4 +555,8 @@ FR-Designer_Plugin_Should_Update_Please_Contact_Developer=
FR-Designer_AxisReversed=\uCD95\uC5ED\uC21C FR-Designer_AxisReversed=\uCD95\uC5ED\uC21C
FR-Designer_Logarithmic=\uB85C\uADF8\uB208\uAE08 FR-Designer_Logarithmic=\uB85C\uADF8\uB208\uAE08
FR-Designer_Chart_Log_Base=\uAE30\uC218 FR-Designer_Chart_Log_Base=\uAE30\uC218
FR-Designer_Chart_F_Radar_Axis=\uAC12\uCD95 FR-Designer_Chart_F_Radar_Axis=\uAC12\uCD95
FR-Designer_Style=\uC591\uC2DD
FR-Designer_Color=\uC0C9
FR-Designer_Border=\uD14C\uB450\uB9AC
FR-Designer_Background-Pattern=\uC774\uBBF8\uC9C0

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

@ -595,4 +595,8 @@ FR-Designer_Too_Small_To_Paste=\u6B64\u5904\u65E0\u6CD5\u7C98\u8D34\uFF0C\u5C0F\
FR-Designer_AxisReversed=\u8F74\u9006\u5E8F FR-Designer_AxisReversed=\u8F74\u9006\u5E8F
FR-Designer_Logarithmic=\u5BF9\u6570\u523B\u5EA6 FR-Designer_Logarithmic=\u5BF9\u6570\u523B\u5EA6
FR-Designer_Chart_Log_Base=\u5E95\u6570 FR-Designer_Chart_Log_Base=\u5E95\u6570
FR-Designer_Chart_F_Radar_Axis=\u503C\u8F74 FR-Designer_Chart_F_Radar_Axis=\u503C\u8F74
FR-Designer_Style=\u6837\u5F0F
FR-Designer_Color=\u989C\u8272
FR-Designer_Border=\u8FB9\u6846
FR-Designer_Background-Pattern=\u56FE\u6848

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

@ -581,4 +581,8 @@ FR-Designer_Mouse_Click_Tips=
FR-Designer_AxisReversed=\u8EF8\u9006\u5E8F FR-Designer_AxisReversed=\u8EF8\u9006\u5E8F
FR-Designer_Logarithmic=\u5C0D\u6578\u523B\u5EA6 FR-Designer_Logarithmic=\u5C0D\u6578\u523B\u5EA6
FR-Designer_Chart_Log_Base=\u5E95\u6578 FR-Designer_Chart_Log_Base=\u5E95\u6578
FR-Designer_Chart_F_Radar_Axis=\u503C\u8EF8 FR-Designer_Chart_F_Radar_Axis=\u503C\u8EF8
FR-Designer_Style=\u6A23\u5F0F
FR-Designer_Color=\u984F\u8272
FR-Designer_Border=\u6846\u7DDA
FR-Designer_Background-Pattern=\u5716\u6848

13
designer_base/src/com/fr/design/mainframe/backgroundpane/PatternBackgroundQuickPane.java

@ -26,17 +26,16 @@ import java.awt.geom.Rectangle2D;
public class PatternBackgroundQuickPane extends BackgroundQuickPane { public class PatternBackgroundQuickPane extends BackgroundQuickPane {
private int patternIndex = 0; // pattern setIndex. private int patternIndex = 0; // pattern setIndex.
private final static int DEFAULT_DIM_HEIGHT = 190;
private ColorSelectBox foregroundColorPane; private ColorSelectBox foregroundColorPane;
private ColorSelectBox backgroundColorPane; private ColorSelectBox backgroundColorPane;
private PatternButton[] patternButtonArray; private PatternButton[] patternButtonArray;
public PatternBackgroundQuickPane() { public PatternBackgroundQuickPane() {
this.setLayout(new BorderLayout(0, 4)); this.setLayout(new BorderLayout(0, 4));
JPanel contentPane = FRGUIPaneFactory.createY_AXISBoxInnerContainer_S_Pane(); JPanel contentPane = FRGUIPaneFactory.createY_AXISBoxInnerContainer_S_Pane();
this.add(contentPane, BorderLayout.NORTH); this.add(contentPane, BorderLayout.NORTH);
contentPane.setBorder(new UIRoundedBorder(UIConstants.LINE_COLOR, 1, 5)); contentPane.setBorder(new UIRoundedBorder(UIConstants.LINE_COLOR, 1, 5));
JPanel typePane2 = new JPanel(); JPanel typePane2 = new JPanel();
contentPane.add(typePane2); contentPane.add(typePane2);
typePane2.setLayout(new GridLayout(0, 8, 1, 1)); typePane2.setLayout(new GridLayout(0, 8, 1, 1));
@ -48,13 +47,11 @@ public class PatternBackgroundQuickPane extends BackgroundQuickPane {
patternButtonGroup.add(patternButtonArray[i]); patternButtonGroup.add(patternButtonArray[i]);
typePane2.add(patternButtonArray[i]); typePane2.add(patternButtonArray[i]);
} }
JPanel colorPane = new JPanel(new GridLayout(0, 2)); JPanel colorPane = new JPanel(new GridLayout(0, 2));
foregroundColorPane = new ColorSelectBox(70); foregroundColorPane = new ColorSelectBox(70);
backgroundColorPane = new ColorSelectBox(70); backgroundColorPane = new ColorSelectBox(70);
colorPane.add(this.createLabelColorPane(Inter.getLocText("FR-Designer_Foreground") + ":", foregroundColorPane));
colorPane.add(this.createLabelColorPane(Inter.getLocText("Foreground") + ":", foregroundColorPane)); colorPane.add(this.createLabelColorPane(Inter.getLocText("FR-Designer_Background") + ":", backgroundColorPane));
colorPane.add(this.createLabelColorPane(Inter.getLocText("Background") + ":", backgroundColorPane));
this.add(colorPane, BorderLayout.CENTER); this.add(colorPane, BorderLayout.CENTER);
foregroundColorPane.addSelectChangeListener(colorChangeListener); foregroundColorPane.addSelectChangeListener(colorChangeListener);
backgroundColorPane.addSelectChangeListener(colorChangeListener); backgroundColorPane.addSelectChangeListener(colorChangeListener);
@ -63,7 +60,7 @@ public class PatternBackgroundQuickPane extends BackgroundQuickPane {
@Override @Override
public Dimension getPreferredSize() { public Dimension getPreferredSize() {
Dimension dim = super.getPreferredSize(); Dimension dim = super.getPreferredSize();
dim.height = 190; dim.height = DEFAULT_DIM_HEIGHT;
return dim; return dim;
} }
@ -204,6 +201,6 @@ public class PatternBackgroundQuickPane extends BackgroundQuickPane {
@Override @Override
public String title4PopupWindow() { public String title4PopupWindow() {
return Inter.getLocText("Background-Pattern"); return Inter.getLocText("FR-Designer_Background-Pattern");
} }
} }
Loading…
Cancel
Save