Browse Source

Fixed merge conflict

fbp/release
Renekton-张世豪 3 months ago
parent
commit
a17029f4ad
  1. 5
      designer-base/src/main/java/com/fr/design/data/datapane/connect/ConnectionListPane.java
  2. 3
      designer-base/src/main/java/com/fr/design/data/datapane/connect/JDBCDefPane.java
  3. 6
      designer-base/src/main/java/com/fr/design/data/datapane/preview/PreviewTablePane.java
  4. 2
      designer-base/src/main/java/com/fr/design/data/datapane/preview/desensitization/view/setting/TableDataDesensitizationTableModel.java
  5. 59
      designer-base/src/main/java/com/fr/design/data/tabledata/datacenter/DCTableDataPane.java
  6. 2
      designer-base/src/main/java/com/fr/design/data/tabledata/tabledatapane/MultiTDTableDataPane.java
  7. 46
      designer-base/src/main/java/com/fr/design/data/tabledata/tabledatapane/TableDataPaneHelper.java
  8. 14
      designer-base/src/main/java/com/fr/design/data/tabledata/wrapper/TableDataFactory.java
  9. 9
      designer-base/src/main/java/com/fr/design/editlock/EditLockUtils.java
  10. 4
      designer-base/src/main/java/com/fr/design/editor/editor/ColumnSelectedEditor.java
  11. 5
      designer-base/src/main/java/com/fr/design/editor/editor/CursorEditor.java
  12. 2
      designer-base/src/main/java/com/fr/design/file/MultiTemplateTabPane.java
  13. 2
      designer-base/src/main/java/com/fr/design/formula/DefaultTinyFormulaPane.java
  14. 17
      designer-base/src/main/java/com/fr/design/gui/controlpane/JControlUpdatePane.java
  15. 21
      designer-base/src/main/java/com/fr/design/gui/frpane/FineTabbedPane.java
  16. 7
      designer-base/src/main/java/com/fr/design/gui/frpane/UIBubbleFloatPane.java
  17. 14
      designer-base/src/main/java/com/fr/design/gui/ibutton/UIButtonGroup.java
  18. 3
      designer-base/src/main/java/com/fr/design/gui/ibutton/UIColorButtonWithAuto.java
  19. 21
      designer-base/src/main/java/com/fr/design/jxbrowser/JxUIPane.java
  20. 5
      designer-base/src/main/java/com/fr/design/mainframe/JTemplate.java
  21. 12
      designer-base/src/main/java/com/fr/design/mainframe/authority/JTemplateAuthorityChecker.java
  22. 8
      designer-base/src/main/java/com/fr/design/mainframe/backgroundpane/PatternBackgroundQuickPane.java
  23. 4
      designer-base/src/main/resources/com/fine/theme/icon/dataset/connection_locked.svg
  24. 4
      designer-base/src/main/resources/com/fine/theme/icon/dataset/connection_locked_disable.svg
  25. 3
      designer-base/src/main/resources/com/fine/theme/icon/editor/type_cursor.svg
  26. 7
      designer-base/src/main/resources/com/fine/theme/icon/font/autoForeground.svg
  27. 7
      designer-base/src/main/resources/com/fine/theme/icon/font/autoForeground_disable.svg
  28. 3
      designer-base/src/main/resources/com/fine/theme/light/ui/fine_light.icon.json
  29. 80
      designer-base/src/main/resources/com/fr/design/data/tabledata/datacenter/web/data-choose.main.js
  30. 4
      designer-base/src/main/resources/com/fr/design/i18n/dimension_en.properties
  31. 2
      designer-base/src/main/resources/com/fr/design/i18n/dimension_ja_JP.properties
  32. 2
      designer-base/src/main/resources/com/fr/design/i18n/dimension_ko_KR.properties
  33. 2
      designer-base/src/main/resources/com/fr/design/i18n/dimension_zh.properties
  34. 2
      designer-base/src/main/resources/com/fr/design/i18n/dimension_zh_TW.properties
  35. 29
      designer-base/src/test/java/com/fr/design/ui/report/ReportServerParamDemo.java
  36. 8
      designer-chart/src/main/java/com/fr/design/mainframe/chart/gui/ChartTypeButtonPane.java
  37. 23
      designer-chart/src/main/java/com/fr/van/chart/custom/VanChartCustomPlotPane.java
  38. 4
      designer-chart/src/main/java/com/fr/van/chart/designer/component/VanChartLabelContentPane.java
  39. 7
      designer-chart/src/main/java/com/fr/van/chart/designer/other/AutoRefreshPane.java
  40. 2
      designer-chart/src/main/java/com/fr/van/chart/designer/style/axis/component/VanChartCategoryStylePaneWithCheckBox.java

5
designer-base/src/main/java/com/fr/design/data/datapane/connect/ConnectionListPane.java

@ -262,7 +262,12 @@ public class ConnectionListPane extends JListControlPane implements ConnectionSh
*/
private boolean needUpdate0(Connection origin, Connection connection) {
// 先不考虑插件
try {
return !connection.equals(origin);
} catch (Exception e) {
FineLoggerFactory.getLogger().error(e.getMessage(), e);
return false;
}
}
/**

3
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();

6
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);

2
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<Tabl
this.setDefaultEditor(EffectedRolesChooser.class, effectedRolesChooser);
this.setDefaultEditor(DesensitizationRuleStatusPane.class, new DesensitizationRuleStatusPane());
this.setDefaultRenderer(DesensitizationRuleStatusPane.class, new DesensitizationRuleStatusPane());
this.createTable().getColumnModel().getColumn(TableSequences.DesensitizationRuleStatus.getNum()).setMaxWidth(60);
}
@Override

59
designer-base/src/main/java/com/fr/design/data/tabledata/datacenter/DCTableDataPane.java

@ -6,8 +6,6 @@ import com.fr.datacenters.tabledata.bean.DCNameBean;
import com.fr.datacenters.tabledata.bean.DCTableDataBean;
import com.fr.design.data.DesignTableDataManager;
import com.fr.design.data.tabledata.tabledatapane.AbstractTableDataPane;
import com.fr.design.dialog.DialogActionListener;
import com.fr.design.dialog.UIDialog;
import com.fr.design.i18n.Toolkit;
import com.fr.design.jxbrowser.JxEngine;
import com.fr.design.jxbrowser.JxUIPane;
@ -15,15 +13,13 @@ import com.fr.json.revise.EmbedJson;
import com.fr.stable.StringUtils;
import com.fr.third.guava.collect.ImmutableMap;
import com.fr.workspace.WorkContext;
import com.teamdev.jxbrowser.browser.callback.InjectJsCallback;
import javax.swing.SwingUtilities;
import java.awt.BorderLayout;
import java.awt.Window;
import java.util.Arrays;
import static com.fr.design.ui.ModernUIConstants.DOT;
import static com.fr.design.ui.ModernUIConstants.WINDOW;
import static com.fr.design.ui.ModernUIConstants.EMB_TAG;
import static com.fr.design.ui.ModernUIConstants.SCHEME_HEADER;
/**
* 数据中心数据集面板
@ -38,26 +34,40 @@ public class DCTableDataPane extends AbstractTableDataPane<DCTableData> {
private static final String DATA_CENTER = "dc";
private static final String DATA_CENTER_HELPER = "dcHelper";
private static final String DATA_CENTER_INJECT_URL = "fineServletURL";
private static final String DC_INDEX_HTML = "com/fr/design/data/tabledata/datacenter/web/data-choose.prod.html";
private final JxUIPane<String> dataCenterJxUIPane;
private JxTableDataNamePane namePane;
private final JxTableDataNamePane namePane = new JxTableDataNamePane(this);
// 用于复制粘贴场景
private DCTableData dcTableData;
/**
* 用于创建带有名称的面板
*
* @param name 名称
*/
public DCTableDataPane(String name) {
this();
namePane.setObjectName(name);
}
public DCTableDataPane() {
setLayout(new BorderLayout());
dataCenterJxUIPane = getJxUIPane();
add(dataCenterJxUIPane, BorderLayout.CENTER);
dataCenterJxUIPane.addXHRHeaders(ImmutableMap.of("Authorization",
WorkContext.getCurrent().getConnection().getToken()));
// 关联 bridge 和 pane
DCTableDataJSBridge.relationPanel(this);
}
private static JxUIPane<String> getJxUIPane() {
return new JxUIPane.Builder<String>()
.engine(JX_ENGINE)
.namespace(DATA_CENTER)
.bindWindow(DATA_CENTER_HELPER, DCTableDataJSBridge::getBridge)
.withEMB("com/fr/design/data/tabledata/datacenter/web/data-choose.prod.html",
ImmutableMap.of("fineServletURL", getDatacentersUrl()))
.withEMB(DC_INDEX_HTML, ImmutableMap.of(DATA_CENTER_INJECT_URL, getDatacentersUrl()))
.build();
}
@ -72,17 +82,37 @@ public class DCTableDataPane extends AbstractTableDataPane<DCTableData> {
@Override
public NamePane asNamePane() {
return namePane = new JxTableDataNamePane(this);
return namePane;
}
@Override
public void populateBean(DCTableData ob) {
DCTableDataJSBridge.relationPanel(this);
reload();
dcTableData = ob;
dataCenterJxUIPane.populate(EmbedJson.encode(ob.toBean()));
updateTableDataName(dcTableData, namePane.getObjectName());
dataCenterJxUIPane.populate(EmbedJson.encode(dcTableData.toBean()));
setDatasetNames(dcTableData);
}
private void reload() {
dataCenterJxUIPane.redirect(EMB_TAG + SCHEME_HEADER + DC_INDEX_HTML,
ImmutableMap.of(DATA_CENTER_INJECT_URL, getDatacentersUrl()));
}
private static void updateTableDataName(DCTableData dcTableData, String name) {
if (StringUtils.isNotBlank(name)) {
dcTableData.setDsName(name);
dcTableData.setName(name);
}
}
private void setDatasetNames(DCTableData ob) {
String[] allDSNames = DesignTableDataManager.getAllDSNames(DesignTableDataManager.getEditingTableDataSource());
dataCenterJxUIPane.executeJS(DATA_CENTER + DOT + "datasetNames=" + EmbedJson.encode(allDSNames));
String[] allName = Arrays.stream(allDSNames)
.filter(name -> !ob.getDsName().equals(name))
.toArray(String[]::new);
dataCenterJxUIPane.executeJS(DATA_CENTER + DOT + "datasetNames=" + EmbedJson.encode(allName));
}
@ -95,8 +125,7 @@ public class DCTableDataPane extends AbstractTableDataPane<DCTableData> {
return DCTableData.fromBean(tableDataBean);
} else {
// 复制的场景下,不打开界面需要返回数据集,需同步面板的名称
dcTableData.setDsName(namePane.getObjectName());
dcTableData.setName(namePane.getObjectName());
updateTableDataName(dcTableData, namePane.getObjectName());
return dcTableData;
}
}

2
designer-base/src/main/java/com/fr/design/data/tabledata/tabledatapane/MultiTDTableDataPane.java

@ -134,7 +134,7 @@ public class MultiTDTableDataPane extends AbstractTableDataPane<MultiTDTableData
private JPanel initSouthPanel() {
JPanel jpanel = new JPanel();
jpanel.setPreferredSize(new Dimension(-1, 150));
jpanel.setPreferredSize(new Dimension(super.getPreferredSize().width, FineUIScale.scale(150)));
jpanel.setLayout(new BorderLayout());
editorPane = new UITableEditorPane<>(new ParameterTableModel() {

46
designer-base/src/main/java/com/fr/design/data/tabledata/tabledatapane/TableDataPaneHelper.java

@ -0,0 +1,46 @@
package com.fr.design.data.tabledata.tabledatapane;
import com.fr.base.AbstractTableData;
import com.fr.design.data.tabledata.datacenter.DCTableDataPane;
import com.fr.third.guava.collect.Sets;
import java.util.Set;
/**
* 数据集面板帮助类
*
* @author vito
* @since 11.0
* Created on 2024/9/10
*/
public class TableDataPaneHelper {
/**
* 标记优先使用带名称的构造方法
*/
private final static Set<Class<? extends AbstractTableDataPane<? extends AbstractTableData>>> NAMED_TABLE_DATA_PANE =
Sets.newHashSet(
MultiTDTableDataPane.class,
GlobalMultiTDTableDataPane.class,
TreeTableDataPane.class,
GlobalTreeTableDataPane.class,
DCTableDataPane.class);
/**
* 是否为带名称的数据集面板
*
* @param tableDataPaneClass 数据集面板类
* @return 是否为带名称的数据集面板
*/
public static boolean isNamedTableDataPane(Class<?> tableDataPaneClass) {
return NAMED_TABLE_DATA_PANE.contains(tableDataPaneClass);
}
/**
* 注册需要名称的数据集面板
*
* @param tableDataPaneClass 数据集面板类
*/
public static void registerNamedTableDataPane(Class<? extends AbstractTableDataPane<? extends AbstractTableData>> tableDataPaneClass) {
NAMED_TABLE_DATA_PANE.add(tableDataPaneClass);
}
}

14
designer-base/src/main/java/com/fr/design/data/tabledata/wrapper/TableDataFactory.java

@ -16,6 +16,7 @@ import com.fr.datacenters.tabledata.DCTableData;
import com.fr.decision.webservice.bean.dataset.ServerDataSetBean;
import com.fr.design.data.datapane.TableDataNameObjectCreator;
import com.fr.design.data.datapane.preview.ConnectionInfoBeanHelper;
import com.fr.design.data.datapane.preview.TableDataBeanHelper;
import com.fr.design.data.tabledata.datacenter.DCTableDataPane;
import com.fr.design.data.tabledata.tabledatapane.AbstractTableDataPane;
import com.fr.design.data.tabledata.tabledatapane.ClassTableDataPane;
@ -25,13 +26,12 @@ import com.fr.design.data.tabledata.tabledatapane.EmbeddedTableDataPane;
import com.fr.design.data.tabledata.tabledatapane.FileTableDataPane;
import com.fr.design.data.tabledata.tabledatapane.MultiTDTableDataPane;
import com.fr.design.data.tabledata.tabledatapane.ProcedureDataPane;
import com.fr.design.data.tabledata.tabledatapane.TableDataPaneHelper;
import com.fr.design.data.tabledata.tabledatapane.TreeTableDataPane;
import com.fr.general.ComparatorUtils;
import com.fr.log.FineLoggerFactory;
import com.fr.stable.ArrayUtils;
import com.fr.stable.StringUtils;
import com.fr.workspace.server.repository.connection.ConnectionRepository;
import com.fr.design.data.datapane.preview.TableDataBeanHelper;
import com.fr.workspace.server.repository.tabledata.TableDataRepository;
import javax.swing.Icon;
@ -56,7 +56,7 @@ public abstract class TableDataFactory {
/**
* 有顺序的,用来排序用
*/
private static Map<String, TableDataNameObjectCreator> map = new java.util.LinkedHashMap<>();
private static Map<String, TableDataNameObjectCreator> map = new LinkedHashMap<>();
private static Map<String, TableDataNameObjectCreator> defaultMap = new LinkedHashMap<>();
@ -129,12 +129,12 @@ public abstract class TableDataFactory {
AbstractTableDataPane datapane = null;
TableDataNameObjectCreator tableDataNameObjectCreator = getTableDataNameObjectCreator(tabledata);
Class<? extends AbstractTableDataPane<?>> creatorClass = (Class<AbstractTableDataPane<?>>) tableDataNameObjectCreator.getUpdatePane();
if (tableDataNameObjectCreator != null && creatorClass != null) {
if (creatorClass != null) {
try {
if (ComparatorUtils.equals(creatorClass, MultiTDTableDataPane.class) || ComparatorUtils.equals(creatorClass, TreeTableDataPane.class)) {
Constructor constructor = creatorClass.getDeclaredConstructor(new Class[]{String.class});
if (TableDataPaneHelper.isNamedTableDataPane(creatorClass)) {
Constructor<? extends AbstractTableDataPane<?>> constructor = creatorClass.getDeclaredConstructor(String.class);
constructor.setAccessible(true);
datapane = (AbstractTableDataPane) constructor.newInstance(name);
datapane = constructor.newInstance(name);
} else {
datapane = creatorClass.newInstance();
}

9
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");
/**
* 数据连接锁定中

4
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<SimpleDSColumn> 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

5
designer-base/src/main/java/com/fr/design/editor/editor/CursorEditor.java

@ -28,6 +28,11 @@ public class CursorEditor extends Editor<CursorEditor> {
return "type_cursor";
}
@Override
public String getIconId() {
return "type_cursor";
}
@Override
public boolean accept(Object object) {
return object instanceof CursorEditor ;

2
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;
}

2
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();
}
}

17
designer-base/src/main/java/com/fr/design/gui/controlpane/JControlUpdatePane.java

@ -3,16 +3,12 @@ package com.fr.design.gui.controlpane;
import com.fr.data.impl.Connection;
import com.fr.design.DesignerEnvManager;
import com.fr.design.beans.BasicBeanPane;
import com.fr.design.data.tabledata.tabledatapane.GlobalMultiTDTableDataPane;
import com.fr.design.data.tabledata.tabledatapane.GlobalTreeTableDataPane;
import com.fr.design.data.tabledata.tabledatapane.MultiTDTableDataPane;
import com.fr.design.data.tabledata.tabledatapane.TreeTableDataPane;
import com.fr.design.data.tabledata.tabledatapane.TableDataPaneHelper;
import com.fr.design.env.DesignerWorkspaceInfo;
import com.fr.design.env.RemoteDesignerWorkspaceInfo;
import com.fr.design.gui.ilist.ListModelElement;
import com.fr.design.layout.FRGUIPaneFactory;
import com.fr.form.event.Listener;
import com.fr.general.ComparatorUtils;
import com.fr.log.FineLoggerFactory;
import javax.swing.JPanel;
@ -70,7 +66,7 @@ class JControlUpdatePane extends JPanel {
Object ob2Populate = creators[i].acceptObject2Populate(el.wrapper);
if (ob2Populate != null) {
if (updatePanes[i] == null) {
if (isMulti(creators[i].getUpdatePane()) || isTree(creators[i].getUpdatePane())) {
if (TableDataPaneHelper.isNamedTableDataPane(creators[i].getUpdatePane())) {
updatePanes[i] = listControlPane.createPaneByCreators(creators[i], el.wrapper.getName());
} else {
updatePanes[i] = listControlPane.createPaneByCreators(creators[i]);
@ -94,15 +90,6 @@ class JControlUpdatePane extends JPanel {
}
}
public boolean isMulti(Class _class) {
return ComparatorUtils.equals(_class, GlobalMultiTDTableDataPane.class) || ComparatorUtils.equals(_class, MultiTDTableDataPane.class);
}
public boolean isTree(Class _class) {
return ComparatorUtils.equals(_class, GlobalTreeTableDataPane.class) || ComparatorUtils.equals(_class, TreeTableDataPane.class);
}
public void update() {
NameableCreator[] creators = listControlPane.creators();
for (int i = 0; i < updatePanes.length; i++) {

21
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<UIToggleButton> 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() {

7
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<T> extends BasicBeanPane<T> {
}
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() {

14
designer-base/src/main/java/com/fr/design/gui/ibutton/UIButtonGroup.java

@ -181,6 +181,7 @@ public class UIButtonGroup<T> extends Column implements GlobalNameObserver, UIOb
}
setBorder(new FineRoundBorder());
initLayout(getCols());
initTabListeners();
}
public UIButtonGroup(String[] textArray, T[] objects) {
@ -192,6 +193,19 @@ public class UIButtonGroup<T> 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());
}
}
});
}
}
/**
* 计算按钮组的列布局;支持自定义布局
*

3
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);

21
designer-base/src/main/java/com/fr/design/jxbrowser/JxUIPane.java

@ -29,6 +29,7 @@ import java.util.Objects;
import java.util.Optional;
import java.util.concurrent.ExecutorService;
import java.util.concurrent.Executors;
import java.util.function.Consumer;
import static com.fr.design.ui.ModernUIConstants.COMPONENT_TAG;
import static com.fr.design.ui.ModernUIConstants.DEFAULT_EXPRESSION;
@ -191,6 +192,14 @@ public class JxUIPane<T> extends BasicPane {
.ifPresent(ns -> ns.putProperty(variable, t));
return InjectJsCallback.Response.proceed();
});
if (browser.mainFrame().isPresent()) {
executeJavaScript(WINDOW + DOT + namespace,
(Consumer<JsObject>) jsObject -> {
if (Objects.nonNull(jsObject)) {
jsObject.putProperty(variable, t);
}
});
}
}
@Nullable
@ -235,6 +244,18 @@ public class JxUIPane<T> extends BasicPane {
}
}
/**
* 执行一段js
*
* @param javaScript 待执行的js脚本
* @see JxUIPane#executeJS(String)
*/
public <T> void executeJavaScript(String javaScript, Consumer<T> consumer) {
if (browser != null) {
browser.mainFrame().ifPresent(frame -> frame.executeJavaScript(javaScript, consumer));
}
}
/**
* 获取js对象
* 注意类内部使用用于简化编码提供 Optional 包装

5
designer-base/src/main/java/com/fr/design/mainframe/JTemplate.java

@ -1,5 +1,6 @@
package com.fr.design.mainframe;
import com.fanruan.datasource.web.bean.ConnectionAuthorityConfigBean;
import com.fanruan.product.ProductConstants;
import com.fine.theme.icon.LazyIcon;
import com.fr.base.Parameter;
@ -101,6 +102,7 @@ import com.fr.widgettheme.designer.WidgetThemeDisplayAction;
import com.fr.workspace.WorkContext;
import com.fr.workspace.server.lock.TplOperator;
import com.fr.workspace.server.repository.WorkplaceConstants;
import com.fr.workspace.server.repository.connection.ConnectionRepository;
import com.fr.workspace.server.repository.template.TemplateRepository;
import javax.swing.BorderFactory;
@ -1749,7 +1751,8 @@ public abstract class JTemplate<T extends BaseBook, U extends BaseUndoState<?>>
}
private boolean checkJTemplateAuthority() {
if (!WorkplaceConstants.isConnectionEditAuth()) {
ConnectionAuthorityConfigBean bean = ConnectionRepository.getInstance().getConnectionAuthorityConfig();
if (!(bean !=null && bean.isConnectionEditAuth())) {
return true;
}
JTemplateAuthorityChecker jTemplateAuthorityChecker = new JTemplateAuthorityChecker(this);

12
designer-base/src/main/java/com/fr/design/mainframe/authority/JTemplateAuthorityChecker.java

@ -29,9 +29,7 @@ import static javax.swing.JOptionPane.WARNING_MESSAGE;
public class JTemplateAuthorityChecker {
JTemplate<?, ?> jTemplate;
Set<String> allConnectionNames;
Set<String> authConnectionNames;
Set<String> allDatasetNames;
Set<String> authDatasetNames;
Map<String, ElementAuthorityChecker> checkerMap = new HashMap<>();
Set<String> authFailConnectionNames = new HashSet<>();
@ -47,13 +45,7 @@ public class JTemplateAuthorityChecker {
}
private void initAuthNames() {
allDatasetNames = new HashSet<>();
for (String authServerDataSetName : TableDataConfigProviderFactory.getInstance().getTableDatas().keySet()) {
allDatasetNames.add(authServerDataSetName);
}
allConnectionNames = ConnectionConfigProviderFactory.getConfigProvider().getConnections().keySet();
// 无需获取所有数据集和数据连接了,当前只能获取自己有权限的
Map<String, Set<String>> authNamesMap = RemoteAuthorityRepository.getInstance().getAuthServerDataSetAndConnectionNames(WorkContext.getCurrent().getConnection().getUserName());
if (authNamesMap != null) {
//有权限的数据连接名称
@ -95,8 +87,6 @@ public class JTemplateAuthorityChecker {
}
}
}
authFailConnectionNames.retainAll(allConnectionNames);
authFailDatasetNames.retainAll(allDatasetNames);
FineLoggerFactory.getLogger().info("JTemplateAuthorityChecker check time consume:" + (System.currentTimeMillis() - s));
return authFailConnectionNames.size() == 0 && authFailDatasetNames.size() == 0;
}

8
designer-base/src/main/java/com/fr/design/mainframe/backgroundpane/PatternBackgroundQuickPane.java

@ -59,6 +59,11 @@ 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))
@ -67,7 +72,8 @@ public class PatternBackgroundQuickPane extends BackgroundQuickPane {
row(
cell(new UILabel(com.fr.design.i18n.Toolkit.i18nText("Fine-Design_Basic_Background"), UILabel.LEFT))
.with(it -> it.setToolTipText(com.fr.design.i18n.Toolkit.i18nText("Fine-Design_Basic_Background"))).weight(1),
cell(backgroundColorPane).weight(4))
cell(backgroundColorPane).weight(4)),
row(cell(foregroundLabel).weight(1), cell(foregroundColorPane).weight(4)),
).with(it -> it.setBorder(new ScaledEmptyBorder(LayoutConstants.VERTICAL_GAP, 0, 0, 0))).getComponent(), BorderLayout.CENTER);
foregroundColorPane.addSelectChangeListener(colorChangeListener);
backgroundColorPane.addSelectChangeListener(colorChangeListener);

4
designer-base/src/main/resources/com/fine/theme/icon/dataset/connection_locked.svg

@ -0,0 +1,4 @@
<svg width="32" height="32" viewBox="0 0 32 32" fill="none" xmlns="http://www.w3.org/2000/svg">
<path fill-rule="evenodd" clip-rule="evenodd" d="M2 4C2 2.89543 2.89543 2 4 2H28C28.5523 2 29 2.44772 29 3V12H21.4H4V18H14.6617C14.6542 18.0108 14.6469 18.0216 14.6395 18.0324C13.707 18.2021 13 19.0185 13 20V20H4V26H13V28C13 28 13 28 13 28H4C2.89543 28 2 27.1046 2 26V4ZM4 4H27V10H4V4ZM7 8C7.55228 8 8 7.55228 8 7C8 6.44772 7.55228 6 7 6C6.44772 6 6 6.44772 6 7C6 7.55228 6.44772 8 7 8ZM11 8C11.5523 8 12 7.55228 12 7C12 6.44772 11.5523 6 11 6C10.4477 6 10 6.44772 10 7C10 7.55228 10.4477 8 11 8Z" fill="#0A1C38" fill-opacity="0.9"/>
<path fill-rule="evenodd" clip-rule="evenodd" d="M25.2 18V19H20.8V18C20.8 16.785 21.785 15.8 23 15.8C24.215 15.8 25.2 16.785 25.2 18ZM28 19H27V18C27 15.7909 25.2091 14 23 14C20.7909 14 19 15.7909 19 18V19H18C16.8954 19 16 19.8954 16 21V27C16 28.1046 16.8954 29 18 29H28C29.1046 29 30 28.1046 30 27V21C30 19.8954 29.1046 19 28 19ZM28.2 21.8C28.2 21.2477 27.7523 20.8 27.2 20.8H18.8C18.2477 20.8 17.8 21.2477 17.8 21.8V26.2C17.8 26.7523 18.2477 27.2 18.8 27.2H27.2C27.7523 27.2 28.2 26.7523 28.2 26.2V21.8ZM23 22C22.4477 22 22 22.4477 22 23V25C22 25.5523 22.4477 26 23 26C23.5523 26 24 25.5523 24 25V23C24 22.4477 23.5523 22 23 22Z" fill="#F1393C"/>
</svg>

After

Width:  |  Height:  |  Size: 1.3 KiB

4
designer-base/src/main/resources/com/fine/theme/icon/dataset/connection_locked_disable.svg

@ -0,0 +1,4 @@
<svg width="32" height="32" viewBox="0 0 32 32" fill="none" xmlns="http://www.w3.org/2000/svg">
<path fill-rule="evenodd" clip-rule="evenodd" d="M2 4C2 2.89543 2.89543 2 4 2H28C28.5523 2 29 2.44772 29 3V12H21.4H4V18H14.6617C14.6542 18.0108 14.6469 18.0216 14.6395 18.0324C13.707 18.2021 13 19.0185 13 20V20H4V26H13V28C13 28 13 28 13 28H4C2.89543 28 2 27.1046 2 26V4ZM4 4H27V10H4V4ZM7 8C7.55228 8 8 7.55228 8 7C8 6.44772 7.55228 6 7 6C6.44772 6 6 6.44772 6 7C6 7.55228 6.44772 8 7 8ZM11 8C11.5523 8 12 7.55228 12 7C12 6.44772 11.5523 6 11 6C10.4477 6 10 6.44772 10 7C10 7.55228 10.4477 8 11 8Z" fill="#A6ABB2"/>
<path fill-rule="evenodd" clip-rule="evenodd" d="M25.2 18V19H20.8V18C20.8 16.785 21.785 15.8 23 15.8C24.215 15.8 25.2 16.785 25.2 18ZM28 19H27V18C27 15.7909 25.2091 14 23 14C20.7909 14 19 15.7909 19 18V19H18C16.8954 19 16 19.8954 16 21V27C16 28.1046 16.8954 29 18 29H28C29.1046 29 30 28.1046 30 27V21C30 19.8954 29.1046 19 28 19ZM28.2 21.8C28.2 21.2477 27.7523 20.8 27.2 20.8H18.8C18.2477 20.8 17.8 21.2477 17.8 21.8V26.2C17.8 26.7523 18.2477 27.2 18.8 27.2H27.2C27.7523 27.2 28.2 26.7523 28.2 26.2V21.8ZM23 22C22.4477 22 22 22.4477 22 23V25C22 25.5523 22.4477 26 23 26C23.5523 26 24 25.5523 24 25V23C24 22.4477 23.5523 22 23 22Z" fill="#A6ABB2"/>
</svg>

After

Width:  |  Height:  |  Size: 1.2 KiB

3
designer-base/src/main/resources/com/fine/theme/icon/editor/type_cursor.svg

@ -0,0 +1,3 @@
<svg width="16" height="16" viewBox="0 0 16 16" fill="none" xmlns="http://www.w3.org/2000/svg">
<path fill-rule="evenodd" clip-rule="evenodd" d="M8 5.66667C11.3137 5.66667 14 4.622 14 3.33333C14 2.04467 11.3137 1 8 1C4.68629 1 2 2.04467 2 3.33333C2 4.622 4.68629 5.66667 8 5.66667ZM14 4.5C14 5.78866 11.3137 6.83333 8 6.83333C4.68629 6.83333 2 5.78866 2 4.5V8C2 9.28866 4.68629 10.3333 8 10.3333C11.3137 10.3333 14 9.28866 14 8V4.5ZM8 11.5C11.3137 11.5 14 10.4553 14 9.16667V12.6667C14 13.9553 11.3137 15 8 15C4.68629 15 2 13.9553 2 12.6667V9.16667C2 10.4553 4.68629 11.5 8 11.5Z" fill="#0A1C38" fill-opacity="0.9"/>
</svg>

After

Width:  |  Height:  |  Size: 624 B

7
designer-base/src/main/resources/com/fine/theme/icon/font/autoForeground.svg

@ -0,0 +1,7 @@
<svg width="32" height="32" viewBox="0 0 32 32" fill="none" xmlns="http://www.w3.org/2000/svg">
<path d="M7.9488 22.9491C7.9488 22.3968 8.39651 21.9491 8.9488 21.9491H22.9488C23.5011 21.9491 23.9488 22.3968 23.9488 22.9491C23.9488 23.5014 23.5011 23.9491 22.9488 23.9491H8.9488C8.39651 23.9491 7.9488 23.5014 7.9488 22.9491Z" fill="#23334C"/>
<path fill-rule="evenodd" clip-rule="evenodd" d="M16.857 6.53016C16.6935 6.17601 16.3391 5.94922 15.949 5.94922C15.559 5.94922 15.2045 6.17601 15.0411 6.53016L9.04108 19.5302C8.80964 20.0316 9.02853 20.6257 9.52998 20.8572C10.0314 21.0886 10.6256 20.8697 10.857 20.3683L12.435 16.9492H19.4631L21.0411 20.3683C21.2725 20.8697 21.8666 21.0886 22.3681 20.8572C22.8696 20.6257 23.0884 20.0316 22.857 19.5302L16.857 6.53016ZM18.54 14.9492L15.949 9.33552L13.3581 14.9492H18.54Z" fill="#23334C"/>
<path d="M6.25704 23.3785C5.97259 24.16 5.10845 24.563 4.32693 24.2785L1.04351 23.0836C0.524528 22.8947 0.256941 22.3208 0.445833 21.8019C0.634726 21.2829 1.20857 21.0153 1.72755 21.2042L4.54661 22.2303L5.57271 19.4111C5.7616 18.8921 6.33545 18.6245 6.85443 18.8134C7.3734 19.0023 7.64099 19.5761 7.4521 20.0951L6.25704 23.3785Z" fill="#0A1C38" fill-opacity="0.9"/>
<path d="M30.8544 8.81349C31.3734 9.00238 31.641 9.57622 31.4521 10.0952C31.2632 10.6142 30.6894 10.8818 30.1704 10.6929L27.3513 9.66682L26.3252 12.486C26.1363 13.005 25.5625 13.2726 25.0435 13.0837C24.5245 12.8948 24.2569 12.3209 24.4458 11.802L25.8615 7.91257C26.0241 7.46574 26.5182 7.23535 26.965 7.39798L30.8544 8.81349Z" fill="#23334C"/>
<path fill-rule="evenodd" clip-rule="evenodd" d="M27.9487 15.9489C27.9487 22.5763 22.5761 27.9489 15.9487 27.9489C13.7838 27.9489 11.7528 27.3756 9.99928 26.3725C9.57918 26.1322 9.04509 26.1809 8.70287 26.5231C8.25873 26.9673 8.3201 27.7066 8.86151 28.025C10.9403 29.2477 13.3626 29.9489 15.9487 29.9489C23.6807 29.9489 29.9487 23.6808 29.9487 15.9489C29.9487 13.5032 29.3216 11.204 28.2194 9.20329C27.9623 8.73652 27.7557 9.3812 27.4487 8.94885L25.9343 9.29167C27.2068 11.1966 27.9487 13.4861 27.9487 15.9489ZM23.6967 4.28646C24.2 4.62148 24.2401 5.32909 23.8126 5.7566C23.4558 6.11336 22.8929 6.14803 22.4696 5.8735C20.5922 4.65593 18.353 3.94885 15.9487 3.94885C9.32131 3.94885 3.94873 9.32144 3.94873 15.9489C3.94873 18.2179 4.57851 20.3399 5.6728 22.1495C5.90663 22.5362 5.5839 23.056 5.1383 22.9808C5.01629 22.9603 4.91565 22.8769 4.80319 22.8253C4.44537 22.6611 4.11939 23.4635 3.82168 22.9489C2.63049 20.8896 1.94873 18.4989 1.94873 15.9489C1.94873 8.21687 8.21674 1.94885 15.9487 1.94885C18.8139 1.94885 21.478 2.80953 23.6967 4.28646Z" fill="#23334C"/>
</svg>

After

Width:  |  Height:  |  Size: 2.6 KiB

7
designer-base/src/main/resources/com/fine/theme/icon/font/autoForeground_disable.svg

@ -0,0 +1,7 @@
<svg width="32" height="32" viewBox="0 0 32 32" fill="none" xmlns="http://www.w3.org/2000/svg">
<path d="M7.9488 22.9491C7.9488 22.3968 8.39651 21.9491 8.9488 21.9491H22.9488C23.5011 21.9491 23.9488 22.3968 23.9488 22.9491C23.9488 23.5014 23.5011 23.9491 22.9488 23.9491H8.9488C8.39651 23.9491 7.9488 23.5014 7.9488 22.9491Z" fill="#B8BDC5"/>
<path fill-rule="evenodd" clip-rule="evenodd" d="M16.857 6.53016C16.6935 6.17601 16.3391 5.94922 15.949 5.94922C15.559 5.94922 15.2045 6.17601 15.0411 6.53016L9.04108 19.5302C8.80964 20.0316 9.02853 20.6257 9.52998 20.8572C10.0314 21.0886 10.6256 20.8697 10.857 20.3683L12.435 16.9492H19.4631L21.0411 20.3683C21.2725 20.8697 21.8666 21.0886 22.3681 20.8572C22.8696 20.6257 23.0884 20.0316 22.857 19.5302L16.857 6.53016ZM18.54 14.9492L15.949 9.33552L13.3581 14.9492H18.54Z" fill="#B8BDC5"/>
<path d="M6.25704 23.3785C5.97259 24.16 5.10845 24.563 4.32693 24.2785L1.04351 23.0836C0.524528 22.8947 0.256941 22.3208 0.445833 21.8019C0.634726 21.2829 1.20857 21.0153 1.72755 21.2042L4.54661 22.2303L5.57271 19.4111C5.7616 18.8921 6.33545 18.6245 6.85443 18.8134C7.3734 19.0023 7.64099 19.5761 7.4521 20.0951L6.25704 23.3785Z" fill="#B8BDC5"/>
<path d="M30.8544 8.81349C31.3734 9.00238 31.641 9.57622 31.4521 10.0952C31.2632 10.6142 30.6894 10.8818 30.1704 10.6929L27.3513 9.66682L26.3252 12.486C26.1363 13.005 25.5625 13.2726 25.0435 13.0837C24.5245 12.8948 24.2569 12.3209 24.4458 11.802L25.8615 7.91257C26.0241 7.46574 26.5182 7.23535 26.965 7.39798L30.8544 8.81349Z" fill="#B8BDC5"/>
<path fill-rule="evenodd" clip-rule="evenodd" d="M27.9487 15.9489C27.9487 22.5763 22.5761 27.9489 15.9487 27.9489C13.7838 27.9489 11.7528 27.3756 9.99928 26.3725C9.57918 26.1322 9.04509 26.1809 8.70287 26.5231C8.25873 26.9673 8.3201 27.7066 8.86151 28.025C10.9403 29.2477 13.3626 29.9489 15.9487 29.9489C23.6807 29.9489 29.9487 23.6808 29.9487 15.9489C29.9487 13.5032 29.3216 11.204 28.2194 9.20329C27.9623 8.73652 27.7557 9.3812 27.4487 8.94885L25.9343 9.29167C27.2068 11.1966 27.9487 13.4861 27.9487 15.9489ZM23.6967 4.28646C24.2 4.62148 24.2401 5.32909 23.8126 5.7566C23.4558 6.11336 22.8929 6.14803 22.4696 5.8735C20.5922 4.65593 18.353 3.94885 15.9487 3.94885C9.32131 3.94885 3.94873 9.32144 3.94873 15.9489C3.94873 18.2179 4.57851 20.3399 5.6728 22.1495C5.90663 22.5362 5.5839 23.056 5.1383 22.9808C5.01629 22.9603 4.91565 22.8769 4.80319 22.8253C4.44537 22.6611 4.11939 23.4635 3.82168 22.9489C2.63049 20.8896 1.94873 18.4989 1.94873 15.9489C1.94873 8.21687 8.21674 1.94885 15.9487 1.94885C18.8139 1.94885 21.478 2.80953 23.6967 4.28646Z" fill="#B8BDC5"/>
</svg>

After

Width:  |  Height:  |  Size: 2.5 KiB

3
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",
@ -384,6 +386,7 @@
"type_double_popup": "editor/type_double_popup.svg",
"type_boolean": "editor/type_boolean.svg",
"type_boolean_popup": "editor/type_boolean_popup.svg",
"type_cursor": "editor/type_cursor.svg",
"date_popup": "editor/date_popup.svg",
"param_popup": "editor/param_popup.svg",
"cellelement_popup": "editor/cellelement_popup.svg",

80
designer-base/src/main/resources/com/fr/design/data/tabledata/datacenter/web/data-choose.main.js

File diff suppressed because one or more lines are too long

4
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

2
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

2
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

2
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

2
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

29
designer-base/src/test/java/com/fr/design/ui/report/ReportServerParamDemo.java

@ -1,29 +0,0 @@
package com.fr.design.ui.report;
import com.fr.design.DesignerEnvManager;
import com.fr.design.ui.ModernUIPane;
import com.fr.design.ui.ModernUIPaneTest;
import javax.swing.*;
import java.awt.*;
/**
* Created by windy on 2019/3/25.
* 报表服务器参数demo
*/
public class ReportServerParamDemo {
public static void main(String... args) {
final JFrame frame = new JFrame();
frame.setSize(660, 600);
JPanel contentPane = (JPanel) frame.getContentPane();
// 是否需要开启调试窗口
DesignerEnvManager.getEnvManager().setOpenDebug(true);
final ModernUIPane<ModernUIPaneTest.Model> pane = new ModernUIPane.Builder<ModernUIPaneTest.Model>()
.withComponent(ReportServerParamComponent.KEY).build();
contentPane.add(pane, BorderLayout.CENTER);
frame.setVisible(true);
frame.setDefaultCloseOperation(WindowConstants.EXIT_ON_CLOSE);
}
}

8
designer-chart/src/main/java/com/fr/design/mainframe/chart/gui/ChartTypeButtonPane.java

@ -457,8 +457,9 @@ public class ChartTypeButtonPane extends BasicBeanPane<ChartCollection> 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 double DOWN_HEIGHT = scale(1);
private final Icon closeIcon = new LazyIcon("closeTag", 8);
private boolean isMoveOn = false;
private String buttonName = "";
@ -506,7 +507,8 @@ public class ChartTypeButtonPane extends BasicBeanPane<ChartCollection> 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));
int y = (int) DOWN_HEIGHT;
closeIcon.paintIcon(this, g2d, x, y);
}
@Override

23
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() {

4
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);

7
designer-chart/src/main/java/com/fr/van/chart/designer/other/AutoRefreshPane.java

@ -84,10 +84,9 @@ public class AutoRefreshPane extends BasicBeanPane<RefreshMoreLabel> {
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());

2
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<VanChartAxisLabelStyle> pane = new ClosableBubbleFloatPane(Constants.LEFT, arrowPoint, settingPane, size.width, FineUIScale.scale(240)) {
ClosableBubbleFloatPane<VanChartAxisLabelStyle> pane = new ClosableBubbleFloatPane(Constants.LEFT, arrowPoint, settingPane, size.width, FineUIScale.scale(260)) {
@Override
public void updateContentPane() {

Loading…
Cancel
Save