Browse Source

REPORT-60644 单元格样式设置调整,ui显示有问题

【问题原因】
单元格元素编辑面板和格式面板中,标签和设置项宽度使用不同方法来
设置的,会不匹配的

【改动思路】
先调整格式设置面板中的设置项与标签之间的间距,使设置项宽度与
单元格元素编辑面板中的其他设置项宽度保持一致.
research/11.0
Starryi 3 years ago
parent
commit
5047480026
  1. 4
      designer-base/src/main/java/com/fr/design/gui/style/TextFontTippedPane.java
  2. 6
      designer-base/src/main/java/com/fr/design/gui/style/TextFormatPane.java

4
designer-base/src/main/java/com/fr/design/gui/style/TextFontTippedPane.java

@ -9,7 +9,6 @@ import com.fr.design.layout.FRGUIPaneFactory;
import com.fr.design.layout.TableLayout;
import com.fr.design.layout.TableLayoutHelper;
import com.fr.design.mainframe.theme.edit.ui.LabelUtils;
import com.fr.design.widget.FRWidgetFactory;
import javax.swing.BorderFactory;
import javax.swing.JPanel;
@ -63,8 +62,7 @@ public class TextFontTippedPane extends AbstractBasicStylePane {
private JPanel createFormatTipPane() {
JPanel container = FRGUIPaneFactory.createBorderLayout_S_Pane();
container.setBorder(BorderFactory.createEmptyBorder(IntervalConstants.INTERVAL_L1, 0, 0, 0));
UILabel formatMigratedTip = FRWidgetFactory.createLineWrapLabel(Toolkit.i18nText("Fine-Design_Report_Format_Style_Migrated_Tip"));
formatMigratedTip.setForeground(new Color(153, 153, 153));
JTextArea formatMigratedTip = LabelUtils.createAutoWrapLabel(Toolkit.i18nText("Fine-Design_Report_Format_Style_Migrated_Tip"), new Color(153, 153, 153));
container.add(formatMigratedTip, BorderLayout.NORTH);
return container;

6
designer-base/src/main/java/com/fr/design/gui/style/TextFormatPane.java

@ -58,7 +58,6 @@ public class TextFormatPane extends AbstractBasicStylePane implements GlobalName
private static final int LABEL_DELTA_WIDTH = 8;
private static final int LABEL_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,
@ -127,13 +126,12 @@ public class TextFormatPane extends AbstractBasicStylePane implements GlobalName
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);
typePane.setBorder(BorderFactory.createEmptyBorder(0, 20, 0, 0));
JPanel option = new JPanel(new BorderLayout());
option.add(new UILabel(Toolkit.i18nText("Fine-Design_Report_Base_Option"), SwingConstants.LEFT), BorderLayout.WEST);
roundingBox = new UICheckBox(Toolkit.i18nText("Fine-Design_Report_Base_Option_Half_Up"));
roundingBox.setBorder(BorderFactory.createEmptyBorder(0, 40, 0, 0));
roundingBox.setBorder(BorderFactory.createEmptyBorder(0, 30, 0, 0));
roundingBox.addItemListener(new ItemListener() {
@Override
public void itemStateChanged(ItemEvent e) {

Loading…
Cancel
Save