From c0d9cada810e32518680413547a0136f10bdac3b Mon Sep 17 00:00:00 2001 From: "Richard.Fang" Date: Mon, 12 Aug 2024 17:25:48 +0800 Subject: [PATCH] =?UTF-8?q?REPORT-127436=E3=80=90NewUI=E3=80=91fix:?= =?UTF-8?q?=E8=A7=86=E8=A7=89=E9=AA=8C=E6=94=B6=E9=97=AE=E9=A2=98=E4=BF=AE?= =?UTF-8?q?=E5=A4=8D?= MIME-Version: 1.0 Content-Type: text/plain; charset=UTF-8 Content-Transfer-Encoding: 8bit --- .../actions/file/OpenRecentReportMenuDef.java | 4 +- .../design/actions/file/SwitchExistEnv.java | 4 +- .../fr/design/constants/LayoutConstants.java | 4 ++ .../datapane/TableDataCreatorProducer.java | 4 ++ .../data/datapane/TreeTableDataDictPane.java | 46 +++++++++++-------- .../tabledatapane/FileTableDataPane.java | 2 +- .../AbstractTemplateServerSettingPane.java | 9 ++-- .../com/fr/design/editor/ValueEditorPane.java | 19 ++++++-- .../gui/frpane/EditingStringListPane.java | 9 +--- .../ImageBackgroundQuickPane.java | 8 ++-- .../TextureBackgroundQuickPane.java | 17 +++++-- .../mainframe/toolbar/ToolBarMenuDock.java | 34 ++++++-------- .../action/RemoteDesignAuthManagerAction.java | 4 +- .../com/fr/design/report/WatermarkPane.java | 5 +- .../src/main/java/com/fr/env/EnvListPane.java | 5 +- .../com/fine/theme/icon/cell/cellSelect.svg | 16 +++++++ .../theme/icon/cell/cellSelect_disable.svg | 16 +++++++ .../filetree/filetype/txtFile_disable.svg | 8 ++++ .../com/fine/theme/icon/toolbar/createCpt.svg | 12 ++--- .../theme/icon/toolbar/createCpt_disable.svg | 12 ++--- .../fine/theme/light/ui/fine_light.icon.json | 9 ++++ .../com/fr/design/actions/NewFormAction.java | 3 +- .../java/com/fr/design/mainframe/JForm.java | 3 +- .../online/OnlineWidgetPopupPreviewPane.java | 4 +- .../file/export/ExcelExportAction.java | 4 +- .../file/export/PageExcelExportAction.java | 4 +- .../export/PageToSheetExcelExportAction.java | 4 +- .../actions/file/export/TextExportAction.java | 4 +- .../server/TemplateThemeManagerAction.java | 4 +- .../fr/design/expand/ExpandFatherPane.java | 2 +- .../design/headerfooter/HeaderFooterPane.java | 6 +-- .../com/fr/design/mainframe/JWorkBook.java | 6 +-- .../cell/settingpane/CellExpandAttrPane.java | 11 +++-- .../cell/settingpane/CellOtherSetPane.java | 8 ++-- .../design/sort/common/SortColumnRowPane.java | 5 +- .../sort/common/SortUIExpandablePane.java | 14 ++++-- .../expressionpane/CustomSequencePane.java | 10 ++-- .../fr/design/webattr/PageToolBarPane.java | 17 ++----- .../fr/design/webattr/PageWebSettingPane.java | 18 +++----- .../fr/design/webattr/ServerFitAttrPane.java | 1 - .../com/fr/design/webattr/WebCssPane.java | 8 ++-- .../java/com/fr/design/webattr/WebJsPane.java | 5 +- .../fr/design/webattr/WriteToolBarPane.java | 9 ++-- .../main/java/com/fr/start/MainDesigner.java | 13 +++--- 44 files changed, 234 insertions(+), 176 deletions(-) create mode 100644 designer-base/src/main/resources/com/fine/theme/icon/cell/cellSelect.svg create mode 100644 designer-base/src/main/resources/com/fine/theme/icon/cell/cellSelect_disable.svg create mode 100644 designer-base/src/main/resources/com/fine/theme/icon/filetree/filetype/txtFile_disable.svg mode change 100755 => 100644 designer-base/src/main/resources/com/fine/theme/icon/toolbar/createCpt.svg mode change 100755 => 100644 designer-base/src/main/resources/com/fine/theme/icon/toolbar/createCpt_disable.svg diff --git a/designer-base/src/main/java/com/fr/design/actions/file/OpenRecentReportMenuDef.java b/designer-base/src/main/java/com/fr/design/actions/file/OpenRecentReportMenuDef.java index 7533cb133a..799594c4e1 100644 --- a/designer-base/src/main/java/com/fr/design/actions/file/OpenRecentReportMenuDef.java +++ b/designer-base/src/main/java/com/fr/design/actions/file/OpenRecentReportMenuDef.java @@ -1,10 +1,10 @@ package com.fr.design.actions.file; +import com.fine.theme.icon.LazyIcon; import java.awt.event.ActionEvent; import java.io.File; import java.util.List; -import com.fr.base.BaseUtils; import com.fr.design.DesignerEnvManager; import com.fr.design.actions.UpdateAction; import com.fr.design.gui.imenu.UIMenu; @@ -62,7 +62,7 @@ public class OpenRecentReportMenuDef extends MenuDef { public OpenRecentReportAction(String cptName) { this.setName(cptName); - this.setSmallIcon(BaseUtils.readIcon("/com/fr/base/images/oem/logo.png")); + this.setSmallIcon(new LazyIcon("logo")); } /** diff --git a/designer-base/src/main/java/com/fr/design/actions/file/SwitchExistEnv.java b/designer-base/src/main/java/com/fr/design/actions/file/SwitchExistEnv.java index accb907e20..25070013f3 100644 --- a/designer-base/src/main/java/com/fr/design/actions/file/SwitchExistEnv.java +++ b/designer-base/src/main/java/com/fr/design/actions/file/SwitchExistEnv.java @@ -46,11 +46,11 @@ public class SwitchExistEnv extends MenuDef { DesignerWorkspaceInfo env = DesignerEnvManager.getEnvManager().getWorkspaceInfo(envName); switch (env.getType()) { case Local: { - this.setSmallIcon("com/fr/design/images/data/bind/localconnect"); + this.setSmallIcon(new LazyIcon("localConnect")); break; } case Remote: { - this.setSmallIcon("com/fr/design/images/data/bind/distanceconnect"); + this.setSmallIcon(new LazyIcon("remoteConnect")); break; } } diff --git a/designer-base/src/main/java/com/fr/design/constants/LayoutConstants.java b/designer-base/src/main/java/com/fr/design/constants/LayoutConstants.java index 13bf91003c..8b2fd695a0 100644 --- a/designer-base/src/main/java/com/fr/design/constants/LayoutConstants.java +++ b/designer-base/src/main/java/com/fr/design/constants/LayoutConstants.java @@ -17,6 +17,10 @@ public class LayoutConstants { * 水平间隙 */ public static final int HGAP_SMALL = 1; + /** + * 水平间隙 + */ + public static final int HGAP_MEDIUM = 2; /** * 水平间隙 */ diff --git a/designer-base/src/main/java/com/fr/design/data/datapane/TableDataCreatorProducer.java b/designer-base/src/main/java/com/fr/design/data/datapane/TableDataCreatorProducer.java index f452784acc..1e86bdc6f3 100644 --- a/designer-base/src/main/java/com/fr/design/data/datapane/TableDataCreatorProducer.java +++ b/designer-base/src/main/java/com/fr/design/data/datapane/TableDataCreatorProducer.java @@ -84,6 +84,10 @@ public class TableDataCreatorProducer { return merge(creators, ExtraDesignClassManager.getInstance().getReportTableDataCreators()); } + /** + * 服务器数据集 + * @return TableDataNameObjectCreator[] + */ public TableDataNameObjectCreator[] createServerTableDataCreator() { TableDataNameObjectCreator dataBase = new TableDataNameObjectCreator(com.fr.design.i18n.Toolkit.i18nText("Fine-Design_Basic_DS_Database_Query"), new LazyIcon("server_database"), DBTableData.class, diff --git a/designer-base/src/main/java/com/fr/design/data/datapane/TreeTableDataDictPane.java b/designer-base/src/main/java/com/fr/design/data/datapane/TreeTableDataDictPane.java index 910a4c00c2..040c0ce9fb 100644 --- a/designer-base/src/main/java/com/fr/design/data/datapane/TreeTableDataDictPane.java +++ b/designer-base/src/main/java/com/fr/design/data/datapane/TreeTableDataDictPane.java @@ -34,6 +34,7 @@ import static com.fine.swing.ui.layout.Layouts.cell; import static com.fine.swing.ui.layout.Layouts.column; import static com.fine.swing.ui.layout.Layouts.flex; import static com.fine.swing.ui.layout.Layouts.row; +import static com.fine.swing.ui.layout.Layouts.fix; public class TreeTableDataDictPane extends BasicPane implements Previewable { @@ -52,6 +53,7 @@ public class TreeTableDataDictPane extends BasicPane implements Previewable { private ValueEditorPane originFieldDependsOnParentPane; private ValueEditorPane parentFieldPane; private ValueEditorPane originFieldDependsOnLengthPane; + private static final double TITLE_RATIO = 0.2; public TreeTableDataDictPane() { this(StringUtils.EMPTY); @@ -69,13 +71,13 @@ public class TreeTableDataDictPane extends BasicPane implements Previewable { } }); JPanel tableFlowPane = FRGUIPaneFactory.createBorderLayout_S_Pane(); - tableFlowPane.add(row(LayoutConstants.HGAP_LARGE, - cell(selectTableDataLabel).weight(0.12), + tableFlowPane.add(row( + cell(selectTableDataLabel).weight(TITLE_RATIO), row(LayoutConstants.HGAP_LARGE, - cell(tableDataNameComboBox).weight(0.9), - cell(new PreviewLabel(this)).weight(0.1) - ).weight(0.3), - flex(0.58) + cell(tableDataNameComboBox).weight(1), + cell(new PreviewLabel(this)) + ).weight(0.4), + flex(0.6 - TITLE_RATIO) ).getComponent()); //中心面板 @@ -118,23 +120,27 @@ public class TreeTableDataDictPane extends BasicPane implements Previewable { makeParentEnable(); //树数据集面板 - centerPane.add(column(10, + centerPane.add(column( cell(parentMarkRadio), - row(LayoutConstants.HGAP_LARGE, - cell(originFieldDependsOnParentLabel).weight(0.12), - cell(originFieldDependsOnParentPane).weight(0.3), - flex(0.58) + fix(10), + row( + cell(originFieldDependsOnParentLabel).weight(TITLE_RATIO), + cell(originFieldDependsOnParentPane).weight(0.4), + flex(0.6 - TITLE_RATIO) ), - row(LayoutConstants.HGAP_LARGE, - cell(parentFieldLabel).weight(0.12), - cell(parentFieldPane).weight(0.3), - flex(0.58) + fix(6), + row( + cell(parentFieldLabel).weight(TITLE_RATIO), + cell(parentFieldPane).weight(0.4), + flex(0.6 - TITLE_RATIO) ), + fix(20), cell(lengthMarkRadio), - row(LayoutConstants.HGAP_LARGE, - cell(originFieldDependsOnLengthLabel).weight(0.12), - cell(originFieldDependsOnLengthPane).weight(0.3), - flex(0.58) + fix(10), + row( + cell(originFieldDependsOnLengthLabel).weight(TITLE_RATIO), + cell(originFieldDependsOnLengthPane).weight(0.4), + flex(0.6 - TITLE_RATIO) ) ).getComponent()); @@ -172,7 +178,7 @@ public class TreeTableDataDictPane extends BasicPane implements Previewable { } }); - this.add(column(LayoutConstants.VERTICAL_GAP, cell(tableFlowPane),cell(centerPane), cell(previewPanel)).getComponent()); + this.add(column(LayoutConstants.VGAP_HUGER, cell(tableFlowPane),cell(centerPane), cell(previewPanel)).getComponent()); } protected void setTableDataNameComboBox(String treeName) { diff --git a/designer-base/src/main/java/com/fr/design/data/tabledata/tabledatapane/FileTableDataPane.java b/designer-base/src/main/java/com/fr/design/data/tabledata/tabledatapane/FileTableDataPane.java index 93cd98ffcd..972c65d30c 100644 --- a/designer-base/src/main/java/com/fr/design/data/tabledata/tabledatapane/FileTableDataPane.java +++ b/designer-base/src/main/java/com/fr/design/data/tabledata/tabledatapane/FileTableDataPane.java @@ -219,7 +219,7 @@ public class FileTableDataPane extends AbstractTableDataPane { cell(urlText).weight(urlWidthRatio), cell(testConnection).weight(0.75 - urlWidthRatio) ), - cell(tips).weight(1) + cell(tips) ).with(it -> it.setBorder(new ScaledEmptyBorder(0,0,0,10))).getComponent(); } diff --git a/designer-base/src/main/java/com/fr/design/dialog/AbstractTemplateServerSettingPane.java b/designer-base/src/main/java/com/fr/design/dialog/AbstractTemplateServerSettingPane.java index 6ae979c303..87fc1efa3c 100644 --- a/designer-base/src/main/java/com/fr/design/dialog/AbstractTemplateServerSettingPane.java +++ b/designer-base/src/main/java/com/fr/design/dialog/AbstractTemplateServerSettingPane.java @@ -1,8 +1,6 @@ package com.fr.design.dialog; -import com.fine.theme.utils.FineUIScale; import com.formdev.flatlaf.util.ScaledEmptyBorder; -import com.fr.design.constants.LayoutConstants; import com.fr.design.gui.icombobox.UIComboBox; import com.fr.design.gui.ilable.UILabel; import com.fr.design.utils.gui.GUICoreUtils; @@ -15,6 +13,7 @@ import java.awt.event.ItemListener; import static com.fine.swing.ui.layout.Layouts.cell; import static com.fine.swing.ui.layout.Layouts.column; import static com.fine.swing.ui.layout.Layouts.row; +import static com.fine.swing.ui.layout.Layouts.flex; /** * 封装了"为该模版单独设置、采用服务器设置"选项功能的设置面板 @@ -42,10 +41,10 @@ public abstract class AbstractTemplateServerSettingPane extends BasicPane { chooseComboBox.addItemListener(itemListener); //以下设置,部分面板通用 UILabel belowSetLabel = new UILabel(com.fr.design.i18n.Toolkit.i18nText("Fine-Design_Report_Blow_Set")); - buttonPane = row( - FineUIScale.scale(32), + buttonPane = row(32, cell(belowSetLabel), - cell(chooseComboBox) + cell(chooseComboBox).weight(1), + flex() ).with(it -> it.setBorder(new ScaledEmptyBorder(0,10,0,0))).getComponent(); this.setLayout(new BorderLayout()); this.contentPane = getContentPane(); diff --git a/designer-base/src/main/java/com/fr/design/editor/ValueEditorPane.java b/designer-base/src/main/java/com/fr/design/editor/ValueEditorPane.java index 354dc0313e..5822570e1a 100644 --- a/designer-base/src/main/java/com/fr/design/editor/ValueEditorPane.java +++ b/designer-base/src/main/java/com/fr/design/editor/ValueEditorPane.java @@ -1,5 +1,6 @@ package com.fr.design.editor; +import com.fine.theme.utils.FineUIScale; import com.fr.base.BaseFormula; import com.fr.design.DesignerEnvManager; import com.fr.design.dialog.BasicPane; @@ -22,8 +23,16 @@ import com.fr.general.ComparatorUtils; import com.fr.stable.StringUtils; -import javax.swing.*; -import java.awt.*; +import javax.swing.JPanel; +import javax.swing.JPopupMenu; +import javax.swing.JMenuItem; +import javax.swing.JOptionPane; +import java.awt.Component; +import java.awt.Dimension; +import java.awt.Color; +import java.awt.Rectangle; +import java.awt.BorderLayout; +import java.awt.Container; import java.awt.event.ActionEvent; import java.awt.event.ActionListener; import java.awt.event.MouseAdapter; @@ -61,13 +70,13 @@ public class ValueEditorPane extends BasicPane implements UIObserver, GlobalName this.cards = cards; // Frank:布局 - this.setLayout(new BorderLayout(2, 0)); + this.setLayout(new BorderLayout()); centerPane = FRGUIPaneFactory.createBorderLayout_S_Pane(); arrowButton = new UIButton(); arrowButton.set4ToolbarButton(); setCurrentEditor(0); - centerPane.setPreferredSize(new Dimension(centerPaneWidth, centerPane.getPreferredSize().height)); - arrowButton.setPreferredSize(new Dimension(20, centerPane.getPreferredSize().height)); + centerPane.setPreferredSize(new Dimension(FineUIScale.scale(centerPaneWidth), centerPane.getPreferredSize().height)); + arrowButton.setPreferredSize(new Dimension(FineUIScale.scale(24), centerPane.getPreferredSize().height)); final Color beforeColor = arrowButton.getBackground(); menu = createPopMenu(); diff --git a/designer-base/src/main/java/com/fr/design/gui/frpane/EditingStringListPane.java b/designer-base/src/main/java/com/fr/design/gui/frpane/EditingStringListPane.java index 63d1d8e69f..cd9f7c0367 100644 --- a/designer-base/src/main/java/com/fr/design/gui/frpane/EditingStringListPane.java +++ b/designer-base/src/main/java/com/fr/design/gui/frpane/EditingStringListPane.java @@ -98,13 +98,8 @@ public abstract class EditingStringListPane extends BasicBeanPane> moveDownButton = new UIButton(com.fr.design.i18n.Toolkit.i18nText("Fine-Design_Basic_Utils_Move_Down"), new LazyIcon("move_down")); moveDownButton.setDisabledIcon(new LazyIcon("move_down").disabled()); - return row(LayoutConstants.HORIZONTAL_GAP, - flex(), - cell(addButton), - cell(modifyButton), - cell(removeButton), - cell(moveUpButton), - cell(moveDownButton) + return row(flex(), + row(6, cell(addButton), cell(modifyButton), cell(removeButton), cell(moveUpButton), cell(moveDownButton)) ).getComponent(); } diff --git a/designer-base/src/main/java/com/fr/design/mainframe/backgroundpane/ImageBackgroundQuickPane.java b/designer-base/src/main/java/com/fr/design/mainframe/backgroundpane/ImageBackgroundQuickPane.java index e1496ff3d6..3a6f619e85 100644 --- a/designer-base/src/main/java/com/fr/design/mainframe/backgroundpane/ImageBackgroundQuickPane.java +++ b/designer-base/src/main/java/com/fr/design/mainframe/backgroundpane/ImageBackgroundQuickPane.java @@ -1,10 +1,10 @@ package com.fr.design.mainframe.backgroundpane; +import com.fine.theme.light.ui.FineRoundBorder; +import com.fine.theme.utils.FineUIScale; import com.fr.base.Style; import com.fr.base.background.ImageFileBackground; import com.fr.base.frpx.pack.PictureCollection; -import com.fr.design.border.UIRoundedBorder; -import com.fr.design.constants.UIConstants; import com.fr.design.event.UIObserverListener; import com.fr.design.gui.frpane.ImgChooseWrapper; import com.fr.design.gui.ibutton.UIButton; @@ -52,8 +52,8 @@ public class ImageBackgroundQuickPane extends BackgroundQuickPane { previewPane = new ImagePreviewPane(); JPanel borderPane = FRGUIPaneFactory.createBorderLayout_S_Pane(); - borderPane.setBorder(new UIRoundedBorder(UIConstants.LINE_COLOR, 1, 5)); - borderPane.setPreferredSize(new Dimension(0, 145)); + borderPane.setBorder(new FineRoundBorder()); + borderPane.setPreferredSize(FineUIScale.scale(new Dimension(0, 145))); borderPane.add(previewPane, BorderLayout.CENTER); this.add(borderPane, BorderLayout.NORTH); previewPane.addChangeListener(imageSizeChangeListener); diff --git a/designer-base/src/main/java/com/fr/design/mainframe/backgroundpane/TextureBackgroundQuickPane.java b/designer-base/src/main/java/com/fr/design/mainframe/backgroundpane/TextureBackgroundQuickPane.java index e9aed06acd..4597f8fa93 100644 --- a/designer-base/src/main/java/com/fr/design/mainframe/backgroundpane/TextureBackgroundQuickPane.java +++ b/designer-base/src/main/java/com/fr/design/mainframe/backgroundpane/TextureBackgroundQuickPane.java @@ -1,19 +1,28 @@ package com.fr.design.mainframe.backgroundpane; +import com.fine.theme.light.ui.FineRoundBorder; import com.fr.base.GraphHelper; import com.fr.base.background.TextureBackground; import com.fr.design.constants.UIConstants; -import com.fr.design.border.UIRoundedBorder; import com.fr.design.event.UIObserverListener; import com.fr.design.layout.FRGUIPaneFactory; import com.fr.general.Background; import com.fr.general.ComparatorUtils; -import javax.swing.*; +import javax.swing.JPanel; +import javax.swing.ButtonGroup; +import javax.swing.JToggleButton; +import javax.swing.BorderFactory; import javax.swing.event.ChangeEvent; import javax.swing.event.ChangeListener; -import java.awt.*; +import java.awt.TexturePaint; +import java.awt.BorderLayout; +import java.awt.GridLayout; +import java.awt.Dimension; +import java.awt.Cursor; +import java.awt.Graphics; +import java.awt.Graphics2D; import java.awt.event.ActionEvent; import java.awt.event.ActionListener; import java.awt.geom.Rectangle2D; @@ -27,7 +36,7 @@ public class TextureBackgroundQuickPane extends BackgroundQuickPane { this.setLayout(FRGUIPaneFactory.createBorderLayout()); JPanel borderPane = FRGUIPaneFactory.createBorderLayout_S_Pane(); - borderPane.setBorder(new UIRoundedBorder(UIConstants.LINE_COLOR, 1, 5)); + borderPane.setBorder(new FineRoundBorder()); JPanel contentPane = new JPanel(); borderPane.add(contentPane, BorderLayout.NORTH); this.add(borderPane, BorderLayout.NORTH); diff --git a/designer-base/src/main/java/com/fr/design/mainframe/toolbar/ToolBarMenuDock.java b/designer-base/src/main/java/com/fr/design/mainframe/toolbar/ToolBarMenuDock.java index 83ca502a1e..b5d45a3202 100644 --- a/designer-base/src/main/java/com/fr/design/mainframe/toolbar/ToolBarMenuDock.java +++ b/designer-base/src/main/java/com/fr/design/mainframe/toolbar/ToolBarMenuDock.java @@ -406,8 +406,8 @@ public abstract class ToolBarMenuDock { insertMenu(menuDef, MenuHandler.FILE); return menuDef; } + // 文件 MenuDef menuDef = new MenuDef(com.fr.design.i18n.Toolkit.i18nText("Fine-Design_Basic_File"), 'F'); - ShortCut[] scs = new ShortCut[0]; if (!DesignerMode.isAuthorityEditing()) { scs = createNewFileShortCuts(); @@ -415,12 +415,13 @@ public abstract class ToolBarMenuDock { if (!ArrayUtils.isEmpty(scs)) { menuDef.addShortCut(scs); } - + // 打开 menuDef.addShortCut(openTemplateAction()); - + // 最近打开的 menuDef.addShortCut(new OpenRecentReportMenuDef()); if (!DesignModeContext.isDuchampMode()) { + // 关闭 addCloseCurrentTemplateAction(menuDef); } @@ -491,31 +492,24 @@ public abstract class ToolBarMenuDock { protected MenuDef createServerMenuDef(ToolBarMenuDockPlus plus) { MenuDef menuDef = new MenuDef(com.fr.design.i18n.Toolkit.i18nText("Fine-Design_Basic__M_Server"), 'S'); - if (!DesignerMode.isAuthorityEditing()) { - menuDef.addShortCut( - new ConnectionListAction(), - createGlobalTDAction() - ); + // 定义数据连接、服务器数据集 + menuDef.addShortCut(new ConnectionListAction(), createGlobalTDAction()); } - - - menuDef.addShortCut( - new PlatformManagerAction() - ); - + // 报表平台管理 + menuDef.addShortCut(new PlatformManagerAction()); if (shouldShowRemoteAuth()) { + // 远程设计权限管理 menuDef.addShortCut(new RemoteDesignAuthManagerAction()); } - if (!DesignerMode.isAuthorityEditing()) { + // 插件管理 addPluginManagerAction(menuDef); + // 函数管理器 menuDef.addShortCut(new FunctionManagerAction()); - + // 全局参数 menuDef.addShortCut(new GlobalParameterAction()); } - - return menuDef; } @@ -530,9 +524,7 @@ public abstract class ToolBarMenuDock { } } if (shouldShowPlugin()) { - menuDef.addShortCut( - new PluginManagerAction() - ); + menuDef.addShortCut(new PluginManagerAction()); } } diff --git a/designer-base/src/main/java/com/fr/design/remote/action/RemoteDesignAuthManagerAction.java b/designer-base/src/main/java/com/fr/design/remote/action/RemoteDesignAuthManagerAction.java index 30112dc7a3..5b00029226 100644 --- a/designer-base/src/main/java/com/fr/design/remote/action/RemoteDesignAuthManagerAction.java +++ b/designer-base/src/main/java/com/fr/design/remote/action/RemoteDesignAuthManagerAction.java @@ -1,6 +1,6 @@ package com.fr.design.remote.action; -import com.fr.base.svg.IconUtils; +import com.fine.theme.icon.LazyIcon; import com.fr.design.actions.UpdateAction; import com.fr.design.dialog.BasicDialog; import com.fr.design.dialog.DialogActionAdapter; @@ -27,7 +27,7 @@ public class RemoteDesignAuthManagerAction extends UpdateAction { public RemoteDesignAuthManagerAction() { this.setName(Toolkit.i18nText("Fine-Design_Basic_Remote_Design_Authority_Manager")); // 远程设计权限管理 - this.setSmallIcon("com/fr/design/remote/images/icon_Remote_Design_Auth_Manager_normal@1x"); + this.setSmallIcon(new LazyIcon("remoteDesignAuthManager")); } diff --git a/designer-base/src/main/java/com/fr/design/report/WatermarkPane.java b/designer-base/src/main/java/com/fr/design/report/WatermarkPane.java index 3f8cd7cc84..1a16042124 100644 --- a/designer-base/src/main/java/com/fr/design/report/WatermarkPane.java +++ b/designer-base/src/main/java/com/fr/design/report/WatermarkPane.java @@ -1,7 +1,6 @@ package com.fr.design.report; import com.fine.theme.light.ui.FineRoundBorder; -import com.fine.theme.utils.FineUIScale; import com.formdev.flatlaf.ui.FlatUIUtils; import com.formdev.flatlaf.util.ScaledEmptyBorder; import com.fr.base.BaseFormula; @@ -52,7 +51,6 @@ import static com.fine.theme.utils.FineUIUtils.wrapComponentWithTitle; * Created by plough on 2018/5/15. */ public class WatermarkPane extends BasicPane { - private static final int MAX_WIDTH = 216; // 水印预览面板 private WatermarkPreviewPane watermarkPreviewPane; @@ -88,7 +86,6 @@ public class WatermarkPane extends BasicPane { JPanel previewPaneWrapper = FRGUIPaneFactory.createBorderLayout_S_Pane(); //预览外边框,宽度跟随全局权重 previewPaneWrapper.setBorder(new FineRoundBorder()); - previewPaneWrapper.setPreferredSize(FineUIScale.scale(new Dimension(-1,415))); previewPaneWrapper.setBackground(FlatUIUtils.getUIColor("background.normal", Color.WHITE)); watermarkPreviewPane = new WatermarkPreviewPane(); watermarkPreviewPane.setOpaque(false); @@ -96,7 +93,7 @@ public class WatermarkPane extends BasicPane { leftPane = column( LayoutConstants.VGAP_SMALL, cell(new UILabel(com.fr.design.i18n.Toolkit.i18nText("Fine-Design_Basic_Widget_Style_Preview"))), - cell(previewPaneWrapper) + cell(previewPaneWrapper).weight(1) ).getComponent(); // 分割线下方,左侧预览,右侧配置 diff --git a/designer-base/src/main/java/com/fr/env/EnvListPane.java b/designer-base/src/main/java/com/fr/env/EnvListPane.java index 454388e124..a9ccf08b8c 100644 --- a/designer-base/src/main/java/com/fr/env/EnvListPane.java +++ b/designer-base/src/main/java/com/fr/env/EnvListPane.java @@ -1,5 +1,6 @@ package com.fr.env; +import com.fine.theme.icon.LazyIcon; import com.fr.design.DesignerEnvManager; import com.fr.design.dialog.FineJOptionPane; import com.fr.design.env.DesignerWorkspaceInfo; @@ -57,9 +58,9 @@ public class EnvListPane extends JListControlPane { */ @Override public NameableCreator[] createNameableCreators() { - NameableCreator local = new NameObjectCreator(com.fr.design.i18n.Toolkit.i18nText("Fine-Design_Basic_Local_Workspace"), "com/fr/design/images/data/bind/localconnect.png", + NameableCreator local = new NameObjectCreator(com.fr.design.i18n.Toolkit.i18nText("Fine-Design_Basic_Local_Workspace"), new LazyIcon("localConnect"), LocalDesignerWorkspaceInfo.class, LocalEnvPane.class); - NameableCreator remote = new NameObjectCreator(com.fr.design.i18n.Toolkit.i18nText("Fine-Design_Basic_Env_Remote_Server"), "com/fr/design/images/data/bind/distanceconnect.png", + NameableCreator remote = new NameObjectCreator(com.fr.design.i18n.Toolkit.i18nText("Fine-Design_Basic_Env_Remote_Server"), new LazyIcon("remoteConnect"), RemoteDesignerWorkspaceInfo.class, RemoteEnvPane.class); return new NameableCreator[]{local, remote}; } diff --git a/designer-base/src/main/resources/com/fine/theme/icon/cell/cellSelect.svg b/designer-base/src/main/resources/com/fine/theme/icon/cell/cellSelect.svg new file mode 100644 index 0000000000..46c490c2e5 --- /dev/null +++ b/designer-base/src/main/resources/com/fine/theme/icon/cell/cellSelect.svg @@ -0,0 +1,16 @@ + + + + + + + + + + + + + + + + diff --git a/designer-base/src/main/resources/com/fine/theme/icon/cell/cellSelect_disable.svg b/designer-base/src/main/resources/com/fine/theme/icon/cell/cellSelect_disable.svg new file mode 100644 index 0000000000..f1c2d764ca --- /dev/null +++ b/designer-base/src/main/resources/com/fine/theme/icon/cell/cellSelect_disable.svg @@ -0,0 +1,16 @@ + + + + + + + + + + + + + + + + diff --git a/designer-base/src/main/resources/com/fine/theme/icon/filetree/filetype/txtFile_disable.svg b/designer-base/src/main/resources/com/fine/theme/icon/filetree/filetype/txtFile_disable.svg new file mode 100644 index 0000000000..122eceed9a --- /dev/null +++ b/designer-base/src/main/resources/com/fine/theme/icon/filetree/filetype/txtFile_disable.svg @@ -0,0 +1,8 @@ + + + + + + + + diff --git a/designer-base/src/main/resources/com/fine/theme/icon/toolbar/createCpt.svg b/designer-base/src/main/resources/com/fine/theme/icon/toolbar/createCpt.svg old mode 100755 new mode 100644 index 819a90d662..ef1d588c06 --- a/designer-base/src/main/resources/com/fine/theme/icon/toolbar/createCpt.svg +++ b/designer-base/src/main/resources/com/fine/theme/icon/toolbar/createCpt.svg @@ -1,11 +1,5 @@ - - - + + + diff --git a/designer-base/src/main/resources/com/fine/theme/icon/toolbar/createCpt_disable.svg b/designer-base/src/main/resources/com/fine/theme/icon/toolbar/createCpt_disable.svg old mode 100755 new mode 100644 index 3fbc7e166d..d1eeea5d78 --- a/designer-base/src/main/resources/com/fine/theme/icon/toolbar/createCpt_disable.svg +++ b/designer-base/src/main/resources/com/fine/theme/icon/toolbar/createCpt_disable.svg @@ -1,11 +1,5 @@ - - - + + + 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 d51a85d4d5..f33c0d53d3 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 @@ -96,6 +96,7 @@ "xmlFile": "filetree/filetype/xmlFile.svg", "csvFile": "filetree/filetype/csvFile.svg", "svgFile": "filetree/filetype/svgFile.svg", + "txtFile": "filetree/filetype/txtFile.svg", "cellattr": "propertiestab/cellattr.svg", "cellattr_disabled": "propertiestab/cellattr_disabled.svg", "cellattr_selected": "propertiestab/cellattr_selected.svg", @@ -106,6 +107,7 @@ "conditionattr_disabled": "propertiestab/conditionattr_disabled.svg", "conditionattr_selected": "propertiestab/conditionattr_selected.svg", "floatelement": "propertiestab/floatelement.svg", + "floatelement_disabled": "propertiestab/floatelement_disabled.svg", "floatelement_popup": "propertiestab/floatelement_popup.svg", "floatelement_selected": "propertiestab/floatelement_selected.svg", "hyperlink": "propertiestab/hyperlink.svg", @@ -195,9 +197,13 @@ "notification": "notification/notification.svg", "notification_dot": "notification/notification_dot.svg", "createCpt": "toolbar/createCpt.svg", + "createFvs": "toolbar/createFvs.svg", "createOther": "toolbar/createOther.svg", + "createFrm": "toolbar/createFrm.svg", "openTemplate": "toolbar/openTemplate.svg", "switchEnv": "toolbar/switchEnv.svg", + "localConnect": "toolbar/localConnect.svg", + "remoteConnect": "toolbar/remoteConnect.svg", "export": "toolbar/export.svg", "monochrome_undo": "toolbar/monochrome_undo.svg", "monochrome_redo": "toolbar/monochrome_redo.svg", @@ -227,6 +233,7 @@ "replace": "toolbar/replace.svg", "monochromeServerDatabase": "toolbar/monochromeServerDatabase.svg", "platform": "toolbar/platform.svg", + "remoteDesignAuthManager": "toolbar/remoteDesignAuthManager.svg", "pluginManager": "toolbar/pluginManager.svg", "functionManager": "toolbar/functionManager.svg", "serverConfigManager": "toolbar/serverConfigManager.svg", @@ -263,6 +270,7 @@ "pages": "toolbar/pages.svg", "new_line": "toolbar/newLine.svg", "selected_all": "toolbar/selectedAll.svg", + "templateThemeManager": "toolbar/templateThemeManager.svg", "cellelement_small": "cellelement.svg", "forbid": "expand/forbid.svg", "horizontal_expand": "expand/horizontal.svg", @@ -300,6 +308,7 @@ "cellHyperLinkAttr": "cell/cellHyperLinkAttr.svg", "cellPresentAttr": "cell/cellPresentAttr.svg", "cellElementAttr": "cell/cellElementAttr.svg", + "cellSelect": "cell/cellSelect.svg", "move": "filetree/move.svg", "monochrome_copy": "filetree/monochrome_copy.svg", "monochrome_paste": "filetree/monochrome_paste.svg", diff --git a/designer-form/src/main/java/com/fr/design/actions/NewFormAction.java b/designer-form/src/main/java/com/fr/design/actions/NewFormAction.java index d619c73007..e11cd71a15 100644 --- a/designer-form/src/main/java/com/fr/design/actions/NewFormAction.java +++ b/designer-form/src/main/java/com/fr/design/actions/NewFormAction.java @@ -1,6 +1,7 @@ package com.fr.design.actions; +import com.fine.theme.icon.LazyIcon; import com.fr.design.menu.MenuKeySet; import com.fr.design.widget.ui.designer.NewFormPane; @@ -12,7 +13,7 @@ public class NewFormAction extends UpdateAction { public NewFormAction() { this.setMenuKeySet(NEW_FORM); this.setName(getMenuKeySet().getMenuName()); - this.setSmallIcon("/com/fr/design/images/buttonicon/new_form3"); + this.setSmallIcon(new LazyIcon("createFrm")); this.setAccelerator(getMenuKeySet().getKeyStroke()); } diff --git a/designer-form/src/main/java/com/fr/design/mainframe/JForm.java b/designer-form/src/main/java/com/fr/design/mainframe/JForm.java index 7b4206fc87..ea379cde1e 100644 --- a/designer-form/src/main/java/com/fr/design/mainframe/JForm.java +++ b/designer-form/src/main/java/com/fr/design/mainframe/JForm.java @@ -291,9 +291,8 @@ public class JForm extends JTemplate implements BaseJForm { private MenuDef createWorkBookExportMenu() { MenuDef excelExportMenuDef = new MenuDef(KeySetUtils.EXCEL_EXPORT.getMenuKeySetName(), KeySetUtils.EXCEL_EXPORT.getMnemonic()); - excelExportMenuDef.setIcon(new LazyIcon("excel_icon")); - excelExportMenuDef - .addShortCut(new PageExcelExportAction(this), new ExcelExportAction(this), new PageToSheetExcelExportAction(this)); + excelExportMenuDef.setIcon(new LazyIcon("excelFile")); + // 分页导出、原样导出、分页分Sheet导出 + excelExportMenuDef.addShortCut(new PageExcelExportAction(this), new ExcelExportAction(this), new PageToSheetExcelExportAction(this)); // Export - MenuDef MenuDef exportMenuDef = new MenuDef(KeySetUtils.EXPORT.getMenuName()); exportMenuDef.setIcon(new LazyIcon("export")); diff --git a/designer-realize/src/main/java/com/fr/design/mainframe/cell/settingpane/CellExpandAttrPane.java b/designer-realize/src/main/java/com/fr/design/mainframe/cell/settingpane/CellExpandAttrPane.java index 0d04bb77a4..b56d968a67 100644 --- a/designer-realize/src/main/java/com/fr/design/mainframe/cell/settingpane/CellExpandAttrPane.java +++ b/designer-realize/src/main/java/com/fr/design/mainframe/cell/settingpane/CellExpandAttrPane.java @@ -14,7 +14,6 @@ import com.fr.design.i18n.Toolkit; import com.fr.design.mainframe.theme.utils.DefaultThemedTemplateCellElementCase; import com.fr.design.sort.cellexpand.CellExpandSortPane; import com.fr.general.ComparatorUtils; -import com.fr.general.IOUtils; import com.fr.report.cell.TemplateCellElement; import com.fr.report.cell.cellattr.CellExpandAttr; import com.fr.report.elementcase.TemplateElementCase; @@ -30,6 +29,7 @@ import java.awt.Rectangle; 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.column; import static com.fine.swing.ui.layout.Layouts.fix; /** @@ -110,12 +110,17 @@ public class CellExpandAttrPane extends AbstractCellAttrPane { UILabel up = new UILabel(Toolkit.i18nText("Fine-Design_Report_ExpandD_Up_Father_Cell"), SwingConstants.LEFT); return Layouts.column(LayoutConstants.VERTICAL_GAP, row(cell(direction).weight(1.2), cell(expandDirectionButton).weight(3.0)), - row(cell(left).weight(1.2), cell(leftFatherPane).weight(3.0)), - row(cell(up).weight(1.2), cell(rightFatherPane).weight(3.0)) + row(cell(getTopAlignLabelPane(left)).weight(1.2), cell(leftFatherPane).weight(3.0)), + row(cell(getTopAlignLabelPane(up)).weight(1.2), cell(rightFatherPane).weight(3.0)) ).with(it -> it.setBorder(new ScaledEmptyBorder(0, 0, 10, 0)) ).getComponent(); } + private JPanel getTopAlignLabelPane(UILabel label) { + return column(LayoutConstants.VERTICAL_GAP, cell(label)) + .with(it -> it.setBorder(new ScaledEmptyBorder(3, 0, 0, 0))).getComponent(); + } + private JPanel seniorPane() { return Layouts.column(LayoutConstants.VERTICAL_GAP, cell(horizontalExpandableCheckBox), diff --git a/designer-realize/src/main/java/com/fr/design/mainframe/cell/settingpane/CellOtherSetPane.java b/designer-realize/src/main/java/com/fr/design/mainframe/cell/settingpane/CellOtherSetPane.java index 150b4d8512..0483a4662d 100644 --- a/designer-realize/src/main/java/com/fr/design/mainframe/cell/settingpane/CellOtherSetPane.java +++ b/designer-realize/src/main/java/com/fr/design/mainframe/cell/settingpane/CellOtherSetPane.java @@ -1,6 +1,7 @@ package com.fr.design.mainframe.cell.settingpane; import com.fine.swing.ui.layout.Layouts; +import com.fine.theme.utils.FineUIStyle; import com.fine.theme.utils.FineUIUtils; import com.formdev.flatlaf.util.ScaledEmptyBorder; import com.fr.base.Style; @@ -151,10 +152,11 @@ public class CellOtherSetPane extends AbstractCellAttrPane { JPanel scopePane = initScopePane(); // 带超链的提示信息 - UILabel label = new UILabel(); + UILabel label = new UILabel(Toolkit.i18nText("Fine-Design_Report_Desensitization_Tip")); + FineUIStyle.setStyle(label, FineUIStyle.LABEL_TIP); LocaleMark dataMaskMark = LocaleCenter.getMark(DataMaskMark.class); MessageWithLink hyperlink = new MessageWithLink( - Toolkit.i18nText("Fine-Design_Report_Desensitization_Tip"), + "", Toolkit.i18nText("Fine-Design_Report_Desensitization_Hyperlink"), dataMaskMark.getValue(), StringUtils.EMPTY, @@ -166,7 +168,7 @@ public class CellOtherSetPane extends AbstractCellAttrPane { groupsPane = new CellDesensitizationGroupsPane(this); return Layouts.column(LayoutConstants.VERTICAL_GAP, cell(scopePane), - cell(hyperlink), + row(cell(label), cell(hyperlink)), cell(groupsPane) ).getComponent(); } diff --git a/designer-realize/src/main/java/com/fr/design/sort/common/SortColumnRowPane.java b/designer-realize/src/main/java/com/fr/design/sort/common/SortColumnRowPane.java index eaf2bbdd00..ae91d1c2cf 100644 --- a/designer-realize/src/main/java/com/fr/design/sort/common/SortColumnRowPane.java +++ b/designer-realize/src/main/java/com/fr/design/sort/common/SortColumnRowPane.java @@ -4,7 +4,6 @@ import com.fine.swing.ui.layout.Layouts; import com.fine.theme.icon.LazyIcon; import com.fr.base.Style; import com.fr.base.background.ColorBackground; -import com.fr.base.svg.IconUtils; import com.fr.design.event.UIObserver; import com.fr.design.event.UIObserverListener; import com.fr.design.file.HistoryTemplateListCache; @@ -48,8 +47,8 @@ public class SortColumnRowPane extends JPanel implements UIObserver { private CellSelection oldSelection; private SelectionListener gridSelectionChangeListener; UIObserverListener uiObserverListener; - private final static Icon DISABLED_ICON = IconUtils.readIcon("/com/fr/design/images/buttonicon/select_disabled.svg"); - private final static Icon ENABLE_ICON = IconUtils.readIcon("/com/fr/design/images/buttonicon/select_normal.svg"); + private final static Icon DISABLED_ICON = new LazyIcon("cellSelect").disabled(); + private final static Icon ENABLE_ICON = new LazyIcon("cellSelect"); private boolean enabled; SelectActionListener selectActionListener; diff --git a/designer-realize/src/main/java/com/fr/design/sort/common/SortUIExpandablePane.java b/designer-realize/src/main/java/com/fr/design/sort/common/SortUIExpandablePane.java index 99aa57a4a6..f9d34df0f3 100644 --- a/designer-realize/src/main/java/com/fr/design/sort/common/SortUIExpandablePane.java +++ b/designer-realize/src/main/java/com/fr/design/sort/common/SortUIExpandablePane.java @@ -2,7 +2,6 @@ package com.fr.design.sort.common; import com.fine.swing.ui.layout.Layouts; import com.fine.theme.icon.LazyIcon; -import com.fine.theme.light.ui.FineRoundBorder; import com.fine.theme.utils.FineUIScale; import com.formdev.flatlaf.util.ScaledEmptyBorder; import com.fr.design.border.FineBorderFactory; @@ -12,13 +11,17 @@ import com.fr.design.event.UIObserverListener; import com.fr.design.gui.ilable.UILabel; import com.fr.design.i18n.Toolkit; -import javax.swing.*; -import java.awt.*; +import javax.swing.JPanel; +import javax.swing.BorderFactory; +import java.awt.BorderLayout; +import java.awt.Color; +import java.awt.Dimension; import java.awt.event.MouseAdapter; import java.awt.event.MouseEvent; import static com.fine.swing.ui.layout.Layouts.cell; import static com.fine.swing.ui.layout.Layouts.flex; +import static com.fine.swing.ui.layout.Layouts.fix; public class SortUIExpandablePane extends JPanel { @@ -42,7 +45,6 @@ public class SortUIExpandablePane extends JPanel { this.contentPane = contentPane; initComponents(); wrapPane.setBorder(FineBorderFactory.createWrappedRoundBorder()); - wrapPane.setBackground(Color.WHITE); } @@ -103,7 +105,9 @@ public class SortUIExpandablePane extends JPanel { }); this.setLayout(new BorderLayout()); this.add(Layouts.row( - cell(iconUiLabel), cell(tipUILabel), flex(), cell(closeButton) + fix(LayoutConstants.HGAP_LARGE), + cell(iconUiLabel), fix(LayoutConstants.HGAP_MEDIUM), cell(tipUILabel), flex(), cell(closeButton), + fix(LayoutConstants.HGAP_LARGE) ) .getComponent(), BorderLayout.CENTER); this.setPreferredSize(new Dimension(contentPane.sortItemPaneWidth + FineUIScale.scale(7), FineUIScale.scale(24))); diff --git a/designer-realize/src/main/java/com/fr/design/sort/expressionpane/CustomSequencePane.java b/designer-realize/src/main/java/com/fr/design/sort/expressionpane/CustomSequencePane.java index a67cd5aa6f..c5beaa1f6e 100644 --- a/designer-realize/src/main/java/com/fr/design/sort/expressionpane/CustomSequencePane.java +++ b/designer-realize/src/main/java/com/fr/design/sort/expressionpane/CustomSequencePane.java @@ -3,19 +3,23 @@ package com.fr.design.sort.expressionpane; import com.fine.swing.ui.layout.Layouts; import com.fine.theme.icon.LazyIcon; import com.fine.theme.utils.FineUIScale; +import com.fr.design.constants.LayoutConstants; import com.fr.design.dialog.DialogActionAdapter; import com.fr.design.gui.ibutton.UIButton; import com.fr.design.gui.itextfield.UITextField; import com.fr.design.mainframe.DesignerContext; import com.fr.report.core.sort.sortexpression.CustomSequenceSortExpression; -import javax.swing.*; -import java.awt.*; +import javax.swing.JPanel; +import java.awt.BorderLayout; +import java.awt.Cursor; +import java.awt.Dimension; import java.awt.event.MouseAdapter; import java.awt.event.MouseEvent; import java.util.List; import static com.fine.swing.ui.layout.Layouts.cell; +import static com.fine.swing.ui.layout.Layouts.fix; public class CustomSequencePane extends JPanel { @@ -51,7 +55,7 @@ public class CustomSequencePane extends JPanel { button.addMouseListener(mouseAdapter); textField.addMouseListener(mouseAdapter); this.add(Layouts.row( - cell(textField).weight(6), cell(button).weight(1) + cell(textField).weight(6), fix(LayoutConstants.HGAP_LARGE), cell(button).weight(1) ).getComponent()); } diff --git a/designer-realize/src/main/java/com/fr/design/webattr/PageToolBarPane.java b/designer-realize/src/main/java/com/fr/design/webattr/PageToolBarPane.java index 4667755370..181bb9dc26 100644 --- a/designer-realize/src/main/java/com/fr/design/webattr/PageToolBarPane.java +++ b/designer-realize/src/main/java/com/fr/design/webattr/PageToolBarPane.java @@ -28,7 +28,6 @@ import com.fr.web.attr.ReportWebAttr; import com.fr.design.i18n.Toolkit; import java.awt.BorderLayout; -import java.awt.Color; import java.awt.event.ActionEvent; import java.awt.event.ActionListener; import java.awt.event.InputMethodEvent; @@ -48,6 +47,7 @@ import static com.fine.swing.ui.layout.Layouts.cell; import static com.fine.swing.ui.layout.Layouts.column; import static com.fine.swing.ui.layout.Layouts.flex; import static com.fine.swing.ui.layout.Layouts.row; +import static com.fine.swing.ui.layout.Layouts.fix; import static com.fine.theme.utils.FineUIUtils.wrapBoldLabelWithUnderline; public class PageToolBarPane extends AbstractEditToolBarPane { @@ -110,23 +110,16 @@ public class PageToolBarPane extends AbstractEditToolBarPane { JPanel northPanel = column(LayoutConstants.VERTICAL_GAP, //报表显示位置:居中展示-左展示 row(cell(new UILabel(com.fr.design.i18n.Toolkit.i18nText("Fine-Design_Report_Show_Location"))).weight(0.15), - cell(centerRadioButton).weight(0.2), - cell(leftRadioButton).weight(0.15), - flex(0.5) + row(cell(centerRadioButton), fix(12), cell(leftRadioButton), flex()).weight(0.85) ), //页面:以图片方式显示-iframe嵌入时自动缩放-重方式输出格子 row(cell(new UILabel(com.fr.design.i18n.Toolkit.i18nText("Fine-Design_Report_PageSetup_Page"))).weight(0.15), - cell(isShowAsImageBox).weight(0.2), - cell(isAutoScaleBox).weight(0.25), - cell(isTDHeavyBox).weight(0.2), - flex(0.2) + row(cell(isShowAsImageBox), fix(12), cell(isAutoScaleBox), fix(12), cell(isTDHeavyBox),flex()).weight(0.85) ), //分页设置:按行分页-每页显示行数 row(cell(new UILabel(com.fr.design.i18n.Toolkit.i18nText("Fine-Design_Report_Paging_Settings"))).weight(0.15), - cell(isPageFixedRowBox).weight(0.2), - cell(new UILabel(Toolkit.i18nText("Fine-Design_Report_Rows_Per_Page"))).weight(0.15), - cell(pageFixedRowCountTextField).weight(0.2), - flex(0.3) + row(cell(isPageFixedRowBox), fix(20), cell(new UILabel(Toolkit.i18nText("Fine-Design_Report_Rows_Per_Page"))), + fix(10), cell(pageFixedRowCountTextField),flex()).weight(0.85) ), //提示 cell(tipLabel), diff --git a/designer-realize/src/main/java/com/fr/design/webattr/PageWebSettingPane.java b/designer-realize/src/main/java/com/fr/design/webattr/PageWebSettingPane.java index 1adc107ed2..f4fd1ec66e 100644 --- a/designer-realize/src/main/java/com/fr/design/webattr/PageWebSettingPane.java +++ b/designer-realize/src/main/java/com/fr/design/webattr/PageWebSettingPane.java @@ -33,6 +33,7 @@ import static com.fine.swing.ui.layout.Layouts.cell; import static com.fine.swing.ui.layout.Layouts.column; import static com.fine.swing.ui.layout.Layouts.flex; import static com.fine.swing.ui.layout.Layouts.row; +import static com.fine.swing.ui.layout.Layouts.fix; public class PageWebSettingPane extends WebSettingPane { private UIRadioButton centerRadioButton; @@ -110,23 +111,18 @@ public class PageWebSettingPane extends WebSettingPane { //报表显示位置 row( cell(new UILabel(com.fr.design.i18n.Toolkit.i18nText("Fine-Design_Report_Show_Location"))).weight(0.15), - cell(centerRadioButton).weight(0.2), - cell(leftRadioButton).weight(0.15), - flex(0.5) + row( cell(centerRadioButton), fix(12), cell(leftRadioButton), flex()).weight(0.85) + ), //页面 row(cell(new UILabel(com.fr.design.i18n.Toolkit.i18nText("Fine-Design_Report_PageSetup_Page"))).weight(0.15), - cell(isShowAsImageBox).weight(0.2), - cell(isAutoScaleBox).weight(0.25), - cell(isTDHeavyBox).weight(0.2), - flex(0.2) + row(cell(isShowAsImageBox), fix(12), cell(isAutoScaleBox), fix(12), cell(isTDHeavyBox), flex()).weight(0.85) ), //分页设置 row( - cell(new UILabel(com.fr.design.i18n.Toolkit.i18nText("Fine-Design_Report_Paging_Settings"))).weight(0.15), cell(isPageFixedRowBox).weight(0.2), - cell(new UILabel(Toolkit.i18nText("Fine-Design_Report_Rows_Per_Page"))).weight(0.15), - cell(pageFixedRowCountTextField).weight(0.2), - flex(0.3) + cell(new UILabel(com.fr.design.i18n.Toolkit.i18nText("Fine-Design_Report_Paging_Settings"))).weight(0.15), + row(cell(isPageFixedRowBox), fix(20), cell(new UILabel(Toolkit.i18nText("Fine-Design_Report_Rows_Per_Page"))) + , fix(12), cell(pageFixedRowCountTextField), flex()).weight(0.85) ), //提示 cell(tipLabel) diff --git a/designer-realize/src/main/java/com/fr/design/webattr/ServerFitAttrPane.java b/designer-realize/src/main/java/com/fr/design/webattr/ServerFitAttrPane.java index 4e2245bb44..33da70327f 100644 --- a/designer-realize/src/main/java/com/fr/design/webattr/ServerFitAttrPane.java +++ b/designer-realize/src/main/java/com/fr/design/webattr/ServerFitAttrPane.java @@ -13,7 +13,6 @@ import com.fr.report.fit.ReportFitConfig; import com.fr.transaction.Configurations; import com.fr.transaction.Worker; -import java.awt.*; import java.awt.event.ItemEvent; import java.awt.event.ItemListener; diff --git a/designer-realize/src/main/java/com/fr/design/webattr/WebCssPane.java b/designer-realize/src/main/java/com/fr/design/webattr/WebCssPane.java index 992fa8b289..01226abb5b 100644 --- a/designer-realize/src/main/java/com/fr/design/webattr/WebCssPane.java +++ b/designer-realize/src/main/java/com/fr/design/webattr/WebCssPane.java @@ -29,6 +29,7 @@ import java.util.List; import static com.fine.swing.ui.layout.Layouts.cell; import static com.fine.swing.ui.layout.Layouts.column; import static com.fine.swing.ui.layout.Layouts.row; +import static com.fine.swing.ui.layout.Layouts.fix; public class WebCssPane extends BasicPane { private UITextField localText; @@ -63,9 +64,10 @@ public class WebCssPane extends BasicPane { JPanel workPanel = new JPanel(new BorderLayout()); workPanel.add(column(LayoutConstants.VERTICAL_GAP, - row(LayoutConstants.VERTICAL_GAP, - cell(new UILabel(com.fr.design.i18n.Toolkit.i18nText("Fine-Design_Report_Disk_File"))), - cell(localText).weight(0.8), + row(cell(new UILabel(com.fr.design.i18n.Toolkit.i18nText("Fine-Design_Report_Disk_File"))), + fix(LayoutConstants.HORIZONTAL_GAP), + cell(localText).weight(1), + fix(LayoutConstants.HGAP_LARGE), cell(chooseFile) ), cell(info), diff --git a/designer-realize/src/main/java/com/fr/design/webattr/WebJsPane.java b/designer-realize/src/main/java/com/fr/design/webattr/WebJsPane.java index 230af34a8e..6d05c9e550 100644 --- a/designer-realize/src/main/java/com/fr/design/webattr/WebJsPane.java +++ b/designer-realize/src/main/java/com/fr/design/webattr/WebJsPane.java @@ -43,6 +43,7 @@ import java.util.List; import static com.fine.swing.ui.layout.Layouts.cell; import static com.fine.swing.ui.layout.Layouts.column; import static com.fine.swing.ui.layout.Layouts.row; +import static com.fine.swing.ui.layout.Layouts.fix; public class WebJsPane extends BasicPane { private UITextField localText; @@ -98,9 +99,9 @@ public class WebJsPane extends BasicPane { info2 = new UILabel(com.fr.design.i18n.Toolkit.i18nText("Fine-Design_Report_JS_WARNING2", ProjectConstants.WEBAPP_NAME)); FineUIStyle.setStyle(info2, FineUIStyle.LABEL_WARNING_TIP); JPanel outNorth = column(LayoutConstants.VERTICAL_GAP, - row(LayoutConstants.HORIZONTAL_GAP, cell(localFileRadioButton), cell(localText).weight(0.8), cell(chooseFile)), + row(cell(localFileRadioButton), fix(LayoutConstants.HORIZONTAL_GAP), cell(localText).weight(1), fix(LayoutConstants.HGAP_LARGE), cell(chooseFile)), cell(info1), - row(LayoutConstants.HORIZONTAL_GAP, cell(urlFileRadioButton), cell(urlText).weight(0.8), cell(testConnection)), + row(cell(urlFileRadioButton), fix(LayoutConstants.HORIZONTAL_GAP), cell(urlText).weight(1), fix(LayoutConstants.HGAP_LARGE), cell(testConnection)), cell(info2) ).getComponent(); JPanel workPanel = new JPanel(new BorderLayout()); diff --git a/designer-realize/src/main/java/com/fr/design/webattr/WriteToolBarPane.java b/designer-realize/src/main/java/com/fr/design/webattr/WriteToolBarPane.java index 1a6ecb0da8..37641c18a1 100644 --- a/designer-realize/src/main/java/com/fr/design/webattr/WriteToolBarPane.java +++ b/designer-realize/src/main/java/com/fr/design/webattr/WriteToolBarPane.java @@ -1,7 +1,6 @@ package com.fr.design.webattr; import com.fine.theme.icon.LazyIcon; -import com.formdev.flatlaf.util.ScaledEmptyBorder; import com.fr.base.ConfigManager; import com.fr.config.Configuration; import com.fr.design.ExtraDesignClassManager; @@ -27,9 +26,11 @@ import com.fr.transaction.Configurations; import com.fr.transaction.Worker; import com.fr.web.attr.ReportWebAttr; -import javax.swing.*; +import javax.swing.ButtonGroup; +import javax.swing.JPanel; +import javax.swing.SwingUtilities; -import java.awt.*; +import java.awt.BorderLayout; import java.awt.event.ActionEvent; import java.awt.event.ActionListener; import java.util.ArrayList; @@ -89,7 +90,7 @@ public class WriteToolBarPane extends AbstractEditToolBarPane { colorBox.setSelected(false); colorBox.addActionListener(colorListener); colorButton = new UINoThemeColorButton(new LazyIcon("background")); - JPanel backgroundPane = row(cell(colorBox), fix(LayoutConstants.HGAP_SMALL), cell(colorButton)).getComponent(); + JPanel backgroundPane = row(cell(colorBox), fix(LayoutConstants.HGAP_LARGE), cell(colorButton)).getComponent(); //勾选框 unloadCheck = new UICheckBox(com.fr.design.i18n.Toolkit.i18nText("Fine-Design_Report_Unload_Check")); diff --git a/designer-realize/src/main/java/com/fr/start/MainDesigner.java b/designer-realize/src/main/java/com/fr/start/MainDesigner.java index 8ab42ec873..7190c450d0 100644 --- a/designer-realize/src/main/java/com/fr/start/MainDesigner.java +++ b/designer-realize/src/main/java/com/fr/start/MainDesigner.java @@ -250,18 +250,17 @@ public class MainDesigner extends BaseDesigner { if (!DesignerMode.isAuthorityEditing()) { menuDef.addShortCut(SeparatorDef.DEFAULT); - if (WorkContext.getCurrent().isRoot()) { - menuDef.addShortCut( - new ServerConfigManagerAction() - ); + // 服务器配置 + menuDef.addShortCut(new ServerConfigManagerAction()); JTemplate jt = HistoryTemplateListCache.getInstance().getCurrentEditingTemplate(); if (JTemplate.isValid(jt)) { + // 模板主题管理 menuDef.addShortCut(new TemplateThemeManagerAction()); } - menuDef.addShortCut( - new WidgetManagerAction() - ); + // 控件管理 + menuDef.addShortCut(new WidgetManagerAction()); + // 图标预定义配色、图标空数据提示、地图配置 menuDef.addShortCut(new ChartPreStyleAction(), new ChartEmptyDataStyleAction(), new ChartMapEditorAction()); }