From 312ea3fe961754b0db7ad05224c360d065c9a9ec Mon Sep 17 00:00:00 2001 From: "Richard.Fang" Date: Tue, 10 Sep 2024 15:02:01 +0800 Subject: [PATCH] =?UTF-8?q?REPORT-133990=20&=20REPORT-133567=20&=20REPORT-?= =?UTF-8?q?133398=20&=20REPORT-133389=20&=20REPORT-132370=20&=20REPORT-133?= =?UTF-8?q?696=20&=20REPORT-131838=E3=80=90newUI=E3=80=91fix:=E5=9B=BD?= =?UTF-8?q?=E9=99=85=E5=8C=96=E5=B8=83=E5=B1=80=E8=B0=83=E6=95=B4=E5=8F=8A?= =?UTF-8?q?fbp=E5=9B=9E=E5=BD=92=E9=97=AE=E9=A2=98=E4=BF=AE=E5=A4=8D?= MIME-Version: 1.0 Content-Type: text/plain; charset=UTF-8 Content-Transfer-Encoding: 8bit --- .../data/datapane/connect/JDBCDefPane.java | 3 +-- .../datapane/preview/PreviewTablePane.java | 6 ++--- .../TableDataDesensitizationTableModel.java | 2 -- .../tabledatapane/MultiTDTableDataPane.java | 2 +- .../com/fr/design/editlock/EditLockUtils.java | 9 +++----- .../editor/editor/ColumnSelectedEditor.java | 4 +++- .../fr/design/file/MultiTemplateTabPane.java | 2 ++ .../formula/DefaultTinyFormulaPane.java | 2 +- .../fr/design/gui/frpane/FineTabbedPane.java | 21 ----------------- .../design/gui/frpane/UIBubbleFloatPane.java | 7 ++++-- .../fr/design/gui/ibutton/UIButtonGroup.java | 14 +++++++++++ .../gui/ibutton/UIColorButtonWithAuto.java | 3 +-- .../PatternBackgroundQuickPane.java | 13 ++++++----- .../theme/icon/dataset/connection_locked.svg | 4 ++++ .../dataset/connection_locked_disable.svg | 4 ++++ .../fine/theme/icon/font/autoForeground.svg | 7 ++++++ .../icon/font/autoForeground_disable.svg | 7 ++++++ .../fine/theme/light/ui/fine_light.icon.json | 2 ++ .../fr/design/i18n/dimension_en.properties | 4 +++- .../fr/design/i18n/dimension_ja_JP.properties | 2 ++ .../fr/design/i18n/dimension_ko_KR.properties | 2 ++ .../fr/design/i18n/dimension_zh.properties | 2 ++ .../fr/design/i18n/dimension_zh_TW.properties | 2 ++ .../chart/gui/ChartTypeButtonPane.java | 6 ++--- .../chart/custom/VanChartCustomPlotPane.java | 23 ++++--------------- .../component/VanChartLabelContentPane.java | 4 +--- .../chart/designer/other/AutoRefreshPane.java | 7 +++--- ...VanChartCategoryStylePaneWithCheckBox.java | 2 +- 28 files changed, 88 insertions(+), 78 deletions(-) create mode 100644 designer-base/src/main/resources/com/fine/theme/icon/dataset/connection_locked.svg create mode 100644 designer-base/src/main/resources/com/fine/theme/icon/dataset/connection_locked_disable.svg create mode 100644 designer-base/src/main/resources/com/fine/theme/icon/font/autoForeground.svg create mode 100644 designer-base/src/main/resources/com/fine/theme/icon/font/autoForeground_disable.svg diff --git a/designer-base/src/main/java/com/fr/design/data/datapane/connect/JDBCDefPane.java b/designer-base/src/main/java/com/fr/design/data/datapane/connect/JDBCDefPane.java index 33a1903318..a9322f33fc 100644 --- a/designer-base/src/main/java/com/fr/design/data/datapane/connect/JDBCDefPane.java +++ b/designer-base/src/main/java/com/fr/design/data/datapane/connect/JDBCDefPane.java @@ -4,7 +4,6 @@ import com.fine.swing.ui.layout.Layouts; import com.fine.theme.icon.LazyIcon; import com.fine.theme.utils.FineUIUtils; import com.fr.data.driver.DriverLoader; -import com.fr.data.driver.config.DriverLoaderConfig; import com.fr.data.impl.JDBCDatabaseConnection; import com.fr.data.solution.entity.DriverClasses; import com.fr.datasource.connection.impl.DefaultDatabaseType; @@ -251,7 +250,7 @@ public class JDBCDefPane extends JPanel { cell(driverComboBox).weight(3), flex(0.2), cell(odbcTipsLink).weight(1.8) ).getComponent()) .addSupplier("define", () -> row( - cell(driverLoaderBox).weight(3), cell(driverManageLabel).weight(2) + cell(driverLoaderBox).weight(3), flex(0.2), cell(driverManageLabel).weight(1.8) ).getComponent()); changeDriverRow(); diff --git a/designer-base/src/main/java/com/fr/design/data/datapane/preview/PreviewTablePane.java b/designer-base/src/main/java/com/fr/design/data/datapane/preview/PreviewTablePane.java index be39360327..275b3ce6d4 100644 --- a/designer-base/src/main/java/com/fr/design/data/datapane/preview/PreviewTablePane.java +++ b/designer-base/src/main/java/com/fr/design/data/datapane/preview/PreviewTablePane.java @@ -34,6 +34,7 @@ import com.fr.design.gui.iprogressbar.AutoProgressBar; import com.fr.design.gui.itable.SortableJTable; import com.fr.design.gui.itable.TableSorter; import com.fr.design.gui.itextfield.UINumberField; +import com.fr.design.i18n.DesignSizeI18nManager; import com.fr.design.i18n.Toolkit; import com.fr.design.layout.FRGUIPaneFactory; import com.fr.design.mainframe.DesignerContext; @@ -44,7 +45,6 @@ import com.fr.function.TIME; import com.fr.general.FRFont; import com.fr.general.data.DataModel; import com.fr.log.FineLoggerFactory; -import com.fr.workspace.server.entity.connection.ConnectionBean; import com.fr.workspace.server.repository.connection.ConnectionRepository; import javax.swing.BorderFactory; @@ -53,8 +53,6 @@ import javax.swing.JComponent; import javax.swing.JFrame; import javax.swing.JOptionPane; import javax.swing.JPanel; -import javax.swing.JScrollBar; -import javax.swing.JScrollPane; import javax.swing.JTable; import javax.swing.SwingUtilities; import javax.swing.SwingWorker; @@ -258,7 +256,7 @@ public class PreviewTablePane extends BasicPane { public void doCancel() { } - }, BasicDialog.DEFAULT); + }, DesignSizeI18nManager.getInstance().i18nDimension("com.fr.design.data.datapane.preview.dialog")); dialog.setVisible(true); // 关闭预览页面 PreviewTablePane.this.dialog.setVisible(false); diff --git a/designer-base/src/main/java/com/fr/design/data/datapane/preview/desensitization/view/setting/TableDataDesensitizationTableModel.java b/designer-base/src/main/java/com/fr/design/data/datapane/preview/desensitization/view/setting/TableDataDesensitizationTableModel.java index 32959ef942..8b3d9464fe 100644 --- a/designer-base/src/main/java/com/fr/design/data/datapane/preview/desensitization/view/setting/TableDataDesensitizationTableModel.java +++ b/designer-base/src/main/java/com/fr/design/data/datapane/preview/desensitization/view/setting/TableDataDesensitizationTableModel.java @@ -127,8 +127,6 @@ public class TableDataDesensitizationTableModel extends UITableModelAdapter(new ParameterTableModel() { diff --git a/designer-base/src/main/java/com/fr/design/editlock/EditLockUtils.java b/designer-base/src/main/java/com/fr/design/editlock/EditLockUtils.java index 87ca587f5f..c988f2a711 100644 --- a/designer-base/src/main/java/com/fr/design/editlock/EditLockUtils.java +++ b/designer-base/src/main/java/com/fr/design/editlock/EditLockUtils.java @@ -1,13 +1,10 @@ package com.fr.design.editlock; -import com.fr.base.svg.IconUtils; +import com.fine.theme.icon.LazyIcon; import com.fr.base.svg.SVGLoader; import com.fr.design.dialog.FineJOptionPane; import com.fr.design.i18n.Toolkit; import com.fr.design.mainframe.DesignerContext; -import com.fr.general.IOUtils; -import com.fr.workspace.WorkContext; -import com.fr.workspace.server.lock.editlock.EditLockOperator; import com.fr.report.LockItem; import com.fr.workspace.server.repository.connection.ConnectionRepository; import com.fr.workspace.server.repository.tabledata.TableDataRepository; @@ -30,7 +27,7 @@ public class EditLockUtils { /** * 数据连接锁定标志 */ - public static final Icon CONNECTION_LOCKED_ICON = IconUtils.readIcon("/com/fr/design/images/m_web/connection_locked"); + public static final Icon CONNECTION_LOCKED_ICON = new LazyIcon("connection_locked"); /** * 小锁图片 @@ -40,7 +37,7 @@ public class EditLockUtils { /** * 提示弹窗中的提示标志 */ - public static final Icon TOOLTIPS_ICON = IOUtils.readIcon("/com/fr/design/images/m_web/warningIcon.png"); + public static final Icon TOOLTIPS_ICON = new LazyIcon("warning"); /** * 数据连接锁定中 diff --git a/designer-base/src/main/java/com/fr/design/editor/editor/ColumnSelectedEditor.java b/designer-base/src/main/java/com/fr/design/editor/editor/ColumnSelectedEditor.java index e6ffbadd66..250e32748d 100644 --- a/designer-base/src/main/java/com/fr/design/editor/editor/ColumnSelectedEditor.java +++ b/designer-base/src/main/java/com/fr/design/editor/editor/ColumnSelectedEditor.java @@ -1,5 +1,6 @@ package com.fr.design.editor.editor; +import com.fr.design.constants.LayoutConstants; import com.fr.design.data.DesignTableDataManager; import com.fr.data.SimpleDSColumn; import com.fr.design.data.datapane.TableDataComboBox; @@ -18,6 +19,7 @@ import java.util.regex.Pattern; import static com.fine.swing.ui.layout.Layouts.cell; import static com.fine.swing.ui.layout.Layouts.row; +import static com.fine.swing.ui.layout.Layouts.fix; /** * 选择数据列编辑器 @@ -54,7 +56,7 @@ public class ColumnSelectedEditor extends Editor implements Prep } }); columnNameComboBox = new UIComboBox(); - this.add(row(10, cell(tableDataComboBox), cell(columnNameComboBox)).getComponent()); + this.add(row(cell(tableDataComboBox).weight(1), fix(LayoutConstants.HGAP_LARGE),cell(columnNameComboBox).weight(1)).getComponent()); } @Override diff --git a/designer-base/src/main/java/com/fr/design/file/MultiTemplateTabPane.java b/designer-base/src/main/java/com/fr/design/file/MultiTemplateTabPane.java index 1ac3f12ead..8bedd19c96 100644 --- a/designer-base/src/main/java/com/fr/design/file/MultiTemplateTabPane.java +++ b/designer-base/src/main/java/com/fr/design/file/MultiTemplateTabPane.java @@ -33,6 +33,7 @@ import com.fr.design.worker.save.CallbackSaveWorker; import com.fr.file.FILE; import com.fr.file.FileNodeFILE; import com.fr.general.ComparatorUtils; +import com.fr.general.IOUtils; import com.fr.log.FineLoggerFactory; import com.fr.stable.collections.combination.Pair; import com.fr.third.javax.annotation.Nonnull; @@ -357,6 +358,7 @@ public class MultiTemplateTabPane extends Row { public RightMenuCloseAction(CloseOption option, int tplIndex) { this.option = option; this.setName(option.optionName); + this.setSmallIcon(IOUtils.readIcon("/com/fr/base/images/cell/blank.gif")); this.tplIndex = tplIndex; } diff --git a/designer-base/src/main/java/com/fr/design/formula/DefaultTinyFormulaPane.java b/designer-base/src/main/java/com/fr/design/formula/DefaultTinyFormulaPane.java index 7b69f306d5..7f26c4884c 100644 --- a/designer-base/src/main/java/com/fr/design/formula/DefaultTinyFormulaPane.java +++ b/designer-base/src/main/java/com/fr/design/formula/DefaultTinyFormulaPane.java @@ -56,6 +56,6 @@ public class DefaultTinyFormulaPane extends TinyFormulaPane{ } private Component createDefaultTinyFormulaPane() { - return row(cell(formulaTextField).weight(2), flex(0.1), cell(formulaTextFieldButton).weight(0.4)).getComponent(); + return row(cell(formulaTextField).weight(1), flex(0.1), cell(formulaTextFieldButton)).getComponent(); } } diff --git a/designer-base/src/main/java/com/fr/design/gui/frpane/FineTabbedPane.java b/designer-base/src/main/java/com/fr/design/gui/frpane/FineTabbedPane.java index 1d4274bb99..0ce50448ed 100644 --- a/designer-base/src/main/java/com/fr/design/gui/frpane/FineTabbedPane.java +++ b/designer-base/src/main/java/com/fr/design/gui/frpane/FineTabbedPane.java @@ -6,12 +6,8 @@ import com.formdev.flatlaf.ui.FlatUIUtils; import com.formdev.flatlaf.util.ScaledEmptyBorder; import com.fr.design.gui.ibutton.FitUIButtonGroup; import com.fr.design.gui.ibutton.UIButtonGroup; -import com.fr.design.gui.ibutton.UIToggleButton; import com.fr.design.utils.ColorUtils; -import java.awt.event.MouseAdapter; -import java.awt.event.MouseEvent; -import java.util.List; import javax.swing.JComponent; import javax.swing.JPanel; import javax.swing.event.ChangeEvent; @@ -185,23 +181,6 @@ public class FineTabbedPane extends Box { }); tabGroup.setSelectedIndex(0); cards.show(centerPane, String.valueOf(tabGroup.getSelectedItem())); - if (!useFitTab) { - initTabListeners(); - } - } - - private void initTabListeners() { - List tabs = tabGroup.getLabelButtonList(); - for (UIToggleButton tab : tabs) { - tab.addMouseListener(new MouseAdapter() { - @Override - public void mouseEntered(MouseEvent e) { - if (tab.getPreferredSize().width > tab.getWidth()) { - tab.setToolTipText(tab.getText()); - } - } - }); - } } private void fireStateChanged() { diff --git a/designer-base/src/main/java/com/fr/design/gui/frpane/UIBubbleFloatPane.java b/designer-base/src/main/java/com/fr/design/gui/frpane/UIBubbleFloatPane.java index eba2ce53bd..4916e33100 100644 --- a/designer-base/src/main/java/com/fr/design/gui/frpane/UIBubbleFloatPane.java +++ b/designer-base/src/main/java/com/fr/design/gui/frpane/UIBubbleFloatPane.java @@ -3,6 +3,7 @@ package com.fr.design.gui.frpane; import com.fine.theme.utils.FineUIUtils; import com.formdev.flatlaf.util.SystemInfo; import com.fr.design.beans.BasicBeanPane; +import com.fr.design.constants.LayoutConstants; import com.fr.design.dialog.UIDialog; import com.fr.design.utils.AWTUtilities; import com.fr.log.FineLoggerFactory; @@ -32,6 +33,9 @@ import java.awt.Window; import java.awt.event.AWTEventListener; import java.awt.event.MouseEvent; +import static com.fine.swing.ui.layout.Layouts.column; +import static com.fine.swing.ui.layout.Layouts.cell; + /** * @author Jerry * 非模态悬浮对话框,气泡形状 @@ -226,8 +230,7 @@ public abstract class UIBubbleFloatPane extends BasicBeanPane { } this.setLayout(new BorderLayout()); - this.add(initTopOptionMenu(), BorderLayout.NORTH); - this.add(contentPane, BorderLayout.CENTER); + this.add(column(LayoutConstants.VGAP_MEDIUM, cell(initTopOptionMenu()), cell(contentPane)).getComponent()); } protected JPanel initTopOptionMenu() { diff --git a/designer-base/src/main/java/com/fr/design/gui/ibutton/UIButtonGroup.java b/designer-base/src/main/java/com/fr/design/gui/ibutton/UIButtonGroup.java index fd74f7d042..4e392da122 100644 --- a/designer-base/src/main/java/com/fr/design/gui/ibutton/UIButtonGroup.java +++ b/designer-base/src/main/java/com/fr/design/gui/ibutton/UIButtonGroup.java @@ -181,6 +181,7 @@ public class UIButtonGroup extends Column implements GlobalNameObserver, UIOb } setBorder(new FineRoundBorder()); initLayout(getCols()); + initTabListeners(); } public UIButtonGroup(String[] textArray, T[] objects) { @@ -192,6 +193,19 @@ public class UIButtonGroup extends Column implements GlobalNameObserver, UIOb return UI_CLASS_ID; } + private void initTabListeners() { + for (UIToggleButton tab : labelButtonList) { + tab.addMouseListener(new MouseAdapter() { + @Override + public void mouseEntered(MouseEvent e) { + if (tab.getPreferredSize().width > tab.getWidth()) { + tab.setToolTipText(tab.getText()); + } + } + }); + } + } + /** * 计算按钮组的列布局;支持自定义布局 * diff --git a/designer-base/src/main/java/com/fr/design/gui/ibutton/UIColorButtonWithAuto.java b/designer-base/src/main/java/com/fr/design/gui/ibutton/UIColorButtonWithAuto.java index b10b1d91f8..7a9a41aef2 100644 --- a/designer-base/src/main/java/com/fr/design/gui/ibutton/UIColorButtonWithAuto.java +++ b/designer-base/src/main/java/com/fr/design/gui/ibutton/UIColorButtonWithAuto.java @@ -2,7 +2,6 @@ package com.fr.design.gui.ibutton; import com.fine.theme.icon.LazyIcon; import com.fr.chart.base.ChartConstants; -import com.fr.design.constants.UIConstants; import com.fr.design.style.color.ColorControlWindow; import com.fr.design.style.color.ColorControlWindowWithAuto; import com.fr.general.ComparatorUtils; @@ -17,7 +16,7 @@ public class UIColorButtonWithAuto extends UIColorButton { } if (!ComparatorUtils.equals(oldColor, ChartConstants.AUTO_FONT_COLOR) && ComparatorUtils.equals(newColor, ChartConstants.AUTO_FONT_COLOR)) { - setIcon(UIConstants.AUTO_FONT_ICON); + setIcon(new LazyIcon("autoForeground")); } super.checkColorChange(oldColor, newColor); diff --git a/designer-base/src/main/java/com/fr/design/mainframe/backgroundpane/PatternBackgroundQuickPane.java b/designer-base/src/main/java/com/fr/design/mainframe/backgroundpane/PatternBackgroundQuickPane.java index 789bcd16cf..b8ea2bf0a9 100644 --- a/designer-base/src/main/java/com/fr/design/mainframe/backgroundpane/PatternBackgroundQuickPane.java +++ b/designer-base/src/main/java/com/fr/design/mainframe/backgroundpane/PatternBackgroundQuickPane.java @@ -59,13 +59,14 @@ public class PatternBackgroundQuickPane extends BackgroundQuickPane { backgroundColorPane = new ColorSelectBox(FineUIScale.scale(60)); foregroundColorPane.setSelectObject(DEFAULT_FOREGROUND); foregroundColorPane.setSelectObject(DEFAULT_BACKGROUND); + UILabel foregroundLabel = new UILabel(com.fr.design.i18n.Toolkit.i18nText("Fine-Design_Report_Foreground"), UILabel.LEFT); + foregroundLabel.setToolTipText(com.fr.design.i18n.Toolkit.i18nText("Fine-Design_Report_Foreground")); + UILabel backgroundLabel = new UILabel(com.fr.design.i18n.Toolkit.i18nText("Fine-Design_Basic_Background"), UILabel.LEFT); + backgroundLabel.setToolTipText(com.fr.design.i18n.Toolkit.i18nText("Fine-Design_Basic_Background")); + this.add(Layouts.column(LayoutConstants.VERTICAL_GAP, - row( - cell(new UILabel(com.fr.design.i18n.Toolkit.i18nText("Fine-Design_Report_Foreground"), UILabel.LEFT)).weight(1), - cell(foregroundColorPane).weight(4)), - row( - cell(new UILabel(com.fr.design.i18n.Toolkit.i18nText("Fine-Design_Basic_Background"), UILabel.LEFT)).weight(1), - cell(backgroundColorPane).weight(4)) + row(cell(foregroundLabel).weight(1), cell(foregroundColorPane).weight(4)), + row(cell(backgroundLabel).weight(1), cell(backgroundColorPane).weight(4)) ).with(it -> it.setBorder(new ScaledEmptyBorder(LayoutConstants.VERTICAL_GAP, 0, 0, 0))).getComponent(), BorderLayout.CENTER); foregroundColorPane.addSelectChangeListener(colorChangeListener); backgroundColorPane.addSelectChangeListener(colorChangeListener); diff --git a/designer-base/src/main/resources/com/fine/theme/icon/dataset/connection_locked.svg b/designer-base/src/main/resources/com/fine/theme/icon/dataset/connection_locked.svg new file mode 100644 index 0000000000..a24a789d62 --- /dev/null +++ b/designer-base/src/main/resources/com/fine/theme/icon/dataset/connection_locked.svg @@ -0,0 +1,4 @@ + + + + diff --git a/designer-base/src/main/resources/com/fine/theme/icon/dataset/connection_locked_disable.svg b/designer-base/src/main/resources/com/fine/theme/icon/dataset/connection_locked_disable.svg new file mode 100644 index 0000000000..3b8bfc5a6f --- /dev/null +++ b/designer-base/src/main/resources/com/fine/theme/icon/dataset/connection_locked_disable.svg @@ -0,0 +1,4 @@ + + + + diff --git a/designer-base/src/main/resources/com/fine/theme/icon/font/autoForeground.svg b/designer-base/src/main/resources/com/fine/theme/icon/font/autoForeground.svg new file mode 100644 index 0000000000..11837397ff --- /dev/null +++ b/designer-base/src/main/resources/com/fine/theme/icon/font/autoForeground.svg @@ -0,0 +1,7 @@ + + + + + + + diff --git a/designer-base/src/main/resources/com/fine/theme/icon/font/autoForeground_disable.svg b/designer-base/src/main/resources/com/fine/theme/icon/font/autoForeground_disable.svg new file mode 100644 index 0000000000..46c1bfedc0 --- /dev/null +++ b/designer-base/src/main/resources/com/fine/theme/icon/font/autoForeground_disable.svg @@ -0,0 +1,7 @@ + + + + + + + diff --git a/designer-base/src/main/resources/com/fine/theme/light/ui/fine_light.icon.json b/designer-base/src/main/resources/com/fine/theme/light/ui/fine_light.icon.json index 97a5bc70d7..c5da2acc5f 100644 --- a/designer-base/src/main/resources/com/fine/theme/light/ui/fine_light.icon.json +++ b/designer-base/src/main/resources/com/fine/theme/light/ui/fine_light.icon.json @@ -43,6 +43,7 @@ "database_warning": "dataset/database_warning.svg", "preview": "dataset/preview.svg", "connection": "dataset/connection.svg", + "connection_locked": "dataset/connection_locked.svg", "class_table_data": "dataset/class_table_data.svg", "data_table": "dataset/data_table.svg", "multi": "dataset/multi.svg", @@ -170,6 +171,7 @@ "underline": "font/underline.svg", "foreground": "font/foreground.svg", "background": "font/background.svg", + "autoForeground": "font/autoForeground.svg", "h_left": "cellstyle/h_left.svg", "h_center": "cellstyle/h_center.svg", "h_right": "cellstyle/h_right.svg", diff --git a/designer-base/src/main/resources/com/fr/design/i18n/dimension_en.properties b/designer-base/src/main/resources/com/fr/design/i18n/dimension_en.properties index f35b30539f..f8f5b7f878 100644 --- a/designer-base/src/main/resources/com/fr/design/i18n/dimension_en.properties +++ b/designer-base/src/main/resources/com/fr/design/i18n/dimension_en.properties @@ -35,6 +35,8 @@ com.fr.design.mainframe.EastRegionContainerPane.minimum=340*400 com.fr.design.mainframe.EastRegionContainerPane.standard=480*400 com.fr.design.ds.column.cellEditor.pane=900*600 com.fr.design.actions.reportWebAttr.dialog=800*630 -com.fr.design.actions.printingSetting.dialog=800*600 +com.fr.design.actions.printingSetting.dialog=700*600 +com.fr.design.data.datapane.preview.dialog=700*600 + diff --git a/designer-base/src/main/resources/com/fr/design/i18n/dimension_ja_JP.properties b/designer-base/src/main/resources/com/fr/design/i18n/dimension_ja_JP.properties index 31e4ae38e5..2ffcb1aa42 100644 --- a/designer-base/src/main/resources/com/fr/design/i18n/dimension_ja_JP.properties +++ b/designer-base/src/main/resources/com/fr/design/i18n/dimension_ja_JP.properties @@ -35,5 +35,7 @@ com.fr.design.mainframe.EastRegionContainerPane.standard=480*400 com.fr.design.ds.column.cellEditor.pane=900*600 com.fr.design.actions.reportWebAttr.dialog=700*630 com.fr.design.actions.printingSetting.dialog=700*600 +com.fr.design.data.datapane.preview.dialog=700*600 + diff --git a/designer-base/src/main/resources/com/fr/design/i18n/dimension_ko_KR.properties b/designer-base/src/main/resources/com/fr/design/i18n/dimension_ko_KR.properties index 73b022f454..598b8f68d1 100644 --- a/designer-base/src/main/resources/com/fr/design/i18n/dimension_ko_KR.properties +++ b/designer-base/src/main/resources/com/fr/design/i18n/dimension_ko_KR.properties @@ -35,5 +35,7 @@ com.fr.design.mainframe.EastRegionContainerPane.standard=340*400 com.fr.design.ds.column.cellEditor.pane=900*600 com.fr.design.actions.reportWebAttr.dialog=700*630 com.fr.design.actions.printingSetting.dialog=700*600 +com.fr.design.data.datapane.preview.dialog=700*600 + diff --git a/designer-base/src/main/resources/com/fr/design/i18n/dimension_zh.properties b/designer-base/src/main/resources/com/fr/design/i18n/dimension_zh.properties index 1e30edaf4e..0663409e6d 100644 --- a/designer-base/src/main/resources/com/fr/design/i18n/dimension_zh.properties +++ b/designer-base/src/main/resources/com/fr/design/i18n/dimension_zh.properties @@ -35,5 +35,7 @@ com.fr.design.mainframe.EastRegionContainerPane.standard=286*400 com.fr.design.ds.column.cellEditor.pane=700*600 com.fr.design.actions.reportWebAttr.dialog=660*600 com.fr.design.actions.printingSetting.dialog=660*600 +com.fr.design.data.datapane.preview.dialog=660*600 + diff --git a/designer-base/src/main/resources/com/fr/design/i18n/dimension_zh_TW.properties b/designer-base/src/main/resources/com/fr/design/i18n/dimension_zh_TW.properties index 842dde7fc3..e79bb892d1 100644 --- a/designer-base/src/main/resources/com/fr/design/i18n/dimension_zh_TW.properties +++ b/designer-base/src/main/resources/com/fr/design/i18n/dimension_zh_TW.properties @@ -34,5 +34,7 @@ com.fr.design.mainframe.EastRegionContainerPane.standard=286*400 com.fr.design.ds.column.cellEditor.pane=700*600 com.fr.design.actions.reportWebAttr.dialog=700*630 com.fr.design.actions.printingSetting.dialog=700*600 +com.fr.design.data.datapane.preview.dialog=700*600 + diff --git a/designer-chart/src/main/java/com/fr/design/mainframe/chart/gui/ChartTypeButtonPane.java b/designer-chart/src/main/java/com/fr/design/mainframe/chart/gui/ChartTypeButtonPane.java index 7f3324a2c3..5f2f7790a1 100644 --- a/designer-chart/src/main/java/com/fr/design/mainframe/chart/gui/ChartTypeButtonPane.java +++ b/designer-chart/src/main/java/com/fr/design/mainframe/chart/gui/ChartTypeButtonPane.java @@ -457,8 +457,8 @@ public class ChartTypeButtonPane extends BasicBeanPane implemen private class ChartChangeButton extends UIToggleButton { - private static final double DEL_WIDTH = 9; - private Icon closeIcon = new LazyIcon("closeTag", 8); + private final double DEL_WIDTH = scale(9); + private final Icon closeIcon = new LazyIcon("closeTag", 8); private boolean isMoveOn = false; private String buttonName = ""; @@ -506,7 +506,7 @@ public class ChartTypeButtonPane extends BasicBeanPane implemen private void paintDeleteButton(Graphics g2d) { Rectangle2D bounds = this.getBounds(); int x = (int) (bounds.getWidth() - DEL_WIDTH); - closeIcon.paintIcon(this, g2d, scale(x), scale(1)); + closeIcon.paintIcon(this, g2d, x, scale(1)); } @Override diff --git a/designer-chart/src/main/java/com/fr/van/chart/custom/VanChartCustomPlotPane.java b/designer-chart/src/main/java/com/fr/van/chart/custom/VanChartCustomPlotPane.java index c3dcf73909..9a41401b0b 100644 --- a/designer-chart/src/main/java/com/fr/van/chart/custom/VanChartCustomPlotPane.java +++ b/designer-chart/src/main/java/com/fr/van/chart/custom/VanChartCustomPlotPane.java @@ -3,7 +3,6 @@ package com.fr.van.chart.custom; import com.fr.base.chart.chartdata.TopDefinitionProvider; import com.fr.chart.base.DataSeriesCondition; import com.fr.chart.chartattr.Chart; -import com.fr.chart.chartattr.ChartCollection; import com.fr.chart.chartattr.Plot; import com.fr.chart.chartglyph.ConditionAttr; import com.fr.chart.chartglyph.ConditionCollection; @@ -11,9 +10,7 @@ import com.fr.chartx.attr.ChartProvider; import com.fr.chartx.data.AbstractDataDefinition; import com.fr.chartx.data.ChartDataDefinitionProvider; import com.fr.chartx.data.CustomChartDataDefinition; -import com.fr.design.ChartTypeInterfaceManager; -import com.fr.design.layout.TableLayout; -import com.fr.design.layout.TableLayoutHelper; +import com.fr.design.constants.LayoutConstants; import com.fr.design.mainframe.chart.gui.type.ChartImagePane; import com.fr.design.mainframe.chart.mode.ChartEditContext; import com.fr.log.FineLoggerFactory; @@ -39,6 +36,9 @@ import java.util.HashMap; import java.util.LinkedHashMap; import java.util.Map; +import static com.fine.swing.ui.layout.Layouts.cell; +import static com.fine.swing.ui.layout.Layouts.column; + /** * Created by Mitisky on 16/2/16. */ @@ -88,22 +88,9 @@ public class VanChartCustomPlotPane extends AbstractVanChartTypePane { private void initContent() { - double p = TableLayout.PREFERRED; - double f = TableLayout.FILL; - autoPane = new JPanel(); - customSelectPane = new VanChartCustomPlotSelectPane(); - - Component[][] components = new Component[][]{ - new Component[]{new JSeparator()}, - new Component[]{customSelectPane} - }; - - double[] columnSize = {p, f}; - double[] rowSize = {p, p}; - customPane = TableLayoutHelper.createTableLayoutPane(components, rowSize, columnSize); - + customPane = column(LayoutConstants.VERTICAL_GAP, cell(new JSeparator()), cell(customSelectPane)).getComponent(); contentPane = new JPanel(new CardLayout()) { @Override public Dimension getPreferredSize() { diff --git a/designer-chart/src/main/java/com/fr/van/chart/designer/component/VanChartLabelContentPane.java b/designer-chart/src/main/java/com/fr/van/chart/designer/component/VanChartLabelContentPane.java index 87605db336..0002b3aceb 100644 --- a/designer-chart/src/main/java/com/fr/van/chart/designer/component/VanChartLabelContentPane.java +++ b/designer-chart/src/main/java/com/fr/van/chart/designer/component/VanChartLabelContentPane.java @@ -34,9 +34,7 @@ public class VanChartLabelContentPane extends VanChartTooltipContentPane { if (isInCondition() || !ChartEditContext.supportTheme()) { return super.createCommonStylePane(); } - // 颜色图标统一使用UIColorButton - setTextAttrPane(new ChartTextAttrPaneWithThemeStyle()); - + setTextAttrPane(new LabelAttrPaneWithThemeStyle()); JPanel stylePanel = new JPanel(new BorderLayout()); stylePanel.add(getTextAttrPane(), BorderLayout.CENTER); diff --git a/designer-chart/src/main/java/com/fr/van/chart/designer/other/AutoRefreshPane.java b/designer-chart/src/main/java/com/fr/van/chart/designer/other/AutoRefreshPane.java index 77c7be9dd8..e559f5f42a 100644 --- a/designer-chart/src/main/java/com/fr/van/chart/designer/other/AutoRefreshPane.java +++ b/designer-chart/src/main/java/com/fr/van/chart/designer/other/AutoRefreshPane.java @@ -84,10 +84,9 @@ public class AutoRefreshPane extends BasicBeanPane { initTooltipSet(); JPanel tipPane = getTooltipPane(); - - JPanel moreLabelPane = FineLayoutBuilder.createHorizontalLayout(0, new double[]{1.2, 3}, - new UILabel(com.fr.design.i18n.Toolkit.i18nText("Fine-Design_Chart_More_Label")), moreLabel); - + UILabel backgroundDetectionLabel = new UILabel(com.fr.design.i18n.Toolkit.i18nText("Fine-Design_Chart_More_Label")); + backgroundDetectionLabel.setToolTipText(com.fr.design.i18n.Toolkit.i18nText("Fine-Design_Chart_More_Label")); + JPanel moreLabelPane = FineLayoutBuilder.createHorizontalLayout(0, new double[]{1.2, 3}, backgroundDetectionLabel, moreLabel); Component[][] components = initComponent(tipPane); contentPane = new JPanel(new BorderLayout()); diff --git a/designer-chart/src/main/java/com/fr/van/chart/designer/style/axis/component/VanChartCategoryStylePaneWithCheckBox.java b/designer-chart/src/main/java/com/fr/van/chart/designer/style/axis/component/VanChartCategoryStylePaneWithCheckBox.java index d723fb422b..7c865bd052 100644 --- a/designer-chart/src/main/java/com/fr/van/chart/designer/style/axis/component/VanChartCategoryStylePaneWithCheckBox.java +++ b/designer-chart/src/main/java/com/fr/van/chart/designer/style/axis/component/VanChartCategoryStylePaneWithCheckBox.java @@ -69,7 +69,7 @@ public class VanChartCategoryStylePaneWithCheckBox extends JPanel { Point comPoint = settingButton.getLocationOnScreen(); Point arrowPoint = new Point(comPoint.x +settingButton.getWidth() - 25, comPoint.y + settingButton.getHeight()); Dimension size = settingPane.getPreferredSize(); - ClosableBubbleFloatPane pane = new ClosableBubbleFloatPane(Constants.LEFT, arrowPoint, settingPane, size.width, FineUIScale.scale(240)) { + ClosableBubbleFloatPane pane = new ClosableBubbleFloatPane(Constants.LEFT, arrowPoint, settingPane, size.width, FineUIScale.scale(260)) { @Override public void updateContentPane() {