From 18a88dc422b332cd28ea7d1eda31df4df251f1de Mon Sep 17 00:00:00 2001 From: =?UTF-8?q?=E6=96=B9=E7=A3=8A?= <294531121@qq.com> Date: Mon, 30 Aug 2021 16:40:10 +0800 Subject: [PATCH 01/17] =?UTF-8?q?CHART-20476=20=E6=8A=A5=E8=A1=A8=E5=9D=97?= =?UTF-8?q?=E5=86=85=E5=9B=BE=E8=A1=A8-=E8=B6=85=E9=93=BE=E6=82=AC?= =?UTF-8?q?=E6=B5=AE=E7=AA=97=E8=AE=BE=E7=BD=AE=E9=A1=B9=E6=B2=A1=E4=BA=86?= MIME-Version: 1.0 Content-Type: text/plain; charset=UTF-8 Content-Transfer-Encoding: 8bit --- .../fr/design/module/ChartHyperlinkGroup.java | 19 +++++++++++-------- 1 file changed, 11 insertions(+), 8 deletions(-) diff --git a/designer-chart/src/main/java/com/fr/design/module/ChartHyperlinkGroup.java b/designer-chart/src/main/java/com/fr/design/module/ChartHyperlinkGroup.java index 7611f3300..06c101009 100644 --- a/designer-chart/src/main/java/com/fr/design/module/ChartHyperlinkGroup.java +++ b/designer-chart/src/main/java/com/fr/design/module/ChartHyperlinkGroup.java @@ -65,14 +65,17 @@ public class ChartHyperlinkGroup extends BaseHyperlinkGroup { return !ComparatorUtils.equals(clazz, formHyperlink.getClass()); } else { // 如果是决策报表 - if (template.getEditingReportIndex() == BaseJForm.FORM_TAB) { - // 编辑的是决策报表中的图表,那么没有ChartHyperRelateFloatLink 和 ChartHyperRelateCellLink 选项,有FormHyperlink 选项 - Class[] classes = new Class[]{ChartHyperRelateCellLink.class, ChartHyperRelateFloatLink.class}; - return !ArrayUtils.contains(classes, clazz); - } else if (template.getEditingReportIndex() == BaseJForm.ELEMENTCASE_TAB) { - // 编辑的是决策报表中的报表块,那么没有 ChartHyperPoplink 和 ChartHyperRelateFloatLink - Class[] classes = new Class[]{ChartHyperPoplink.class, ChartHyperRelateFloatLink.class}; - return !ArrayUtils.contains(classes, clazz); + Class[] classes = new Class[]{ChartHyperRelateCellLink.class, ChartHyperRelateFloatLink.class}; + for (Class aClass : classes) { + if (template.getEditingReportIndex() == BaseJForm.FORM_TAB) { + // 编辑的是决策报表中的图表,那么没有ChartHyperRelateFloatLink 和 ChartHyperRelateCellLink 选项,有FormHyperlink 选项 + if (ComparatorUtils.equals(aClass, clazz)) { + return false; + } + } else if (template.getEditingReportIndex() == BaseJForm.ELEMENTCASE_TAB) { + // 编辑的是决策报表中的报表块,那么没有 ChartHyperRelateFloatLink,有ChartHyperRelateCellLink 和 FormHyperlink 选项 + return !ComparatorUtils.equals(clazz, ChartHyperRelateFloatLink.class); + } } } return true; From 212cd97557c45987e71e149e059a02f667eca0fe Mon Sep 17 00:00:00 2001 From: kerry Date: Wed, 1 Sep 2021 19:56:23 +0800 Subject: [PATCH 02/17] =?UTF-8?q?REPORT-58395=E3=80=90=E4=B8=BB=E9=A2=98?= =?UTF-8?q?=E5=88=87=E6=8D=A2=E3=80=91frm=E4=B8=BB=E9=A2=98=E9=85=8D?= =?UTF-8?q?=E7=BD=AE=E7=BB=84=E4=BB=B6=E6=A0=87=E9=A2=98=E5=9B=BE=E6=A1=88?= =?UTF-8?q?=E4=BB=A5=E5=90=8E=EF=BC=8C=E5=B7=A6=E4=BE=A7=E9=A2=84=E8=A7=88?= =?UTF-8?q?=E5=9B=BE=E4=B8=8D=E7=94=9F=E6=95=88?= MIME-Version: 1.0 Content-Type: text/plain; charset=UTF-8 Content-Transfer-Encoding: 8bit --- .../fr/design/style/AbstractSelectBox.java | 1 - .../background/BackgroundJComponent.java | 32 ++++++++++--- .../style/color/NewColorSelectPane.java | 46 ++++++++++++------- 3 files changed, 54 insertions(+), 25 deletions(-) diff --git a/designer-base/src/main/java/com/fr/design/style/AbstractSelectBox.java b/designer-base/src/main/java/com/fr/design/style/AbstractSelectBox.java index 1d66094f1..cd2b8e47a 100644 --- a/designer-base/src/main/java/com/fr/design/style/AbstractSelectBox.java +++ b/designer-base/src/main/java/com/fr/design/style/AbstractSelectBox.java @@ -40,7 +40,6 @@ public abstract class AbstractSelectBox extends AbstractPopBox implements Mou displayComponent = new BackgroundJComponent(); displayComponent.setEmptyBackground(); - displayComponent.setBorder(new TriggleLineBorder()); triggleButton = new UIButton(UIConstants.ARROW_DOWN_ICON) { public boolean shouldResponseChangeListener() { return false; diff --git a/designer-base/src/main/java/com/fr/design/style/background/BackgroundJComponent.java b/designer-base/src/main/java/com/fr/design/style/background/BackgroundJComponent.java index 9d3c31bd4..377da330c 100644 --- a/designer-base/src/main/java/com/fr/design/style/background/BackgroundJComponent.java +++ b/designer-base/src/main/java/com/fr/design/style/background/BackgroundJComponent.java @@ -1,10 +1,12 @@ package com.fr.design.style.background; +import java.awt.Color; import java.awt.Graphics; +import java.awt.Insets; import java.awt.geom.Rectangle2D; import javax.swing.JComponent; - +import com.fr.design.border.UIRoundedBorder; import com.fr.general.Background; /** @@ -18,7 +20,7 @@ public class BackgroundJComponent extends JComponent { protected Background background ; public BackgroundJComponent() { - + this.setBorder(new UIRoundedBorder(Color.decode("#999999"), 2, 2)); } public BackgroundJComponent(Background background) { @@ -29,16 +31,32 @@ public class BackgroundJComponent extends JComponent { super.paint(g); if(background != null && this.getSize().getWidth() > 0 && this.getSize().getHeight() > 0) { - background.paint(g, new Rectangle2D.Double(1, 1, this.getSize().getWidth() - 2, - this.getSize().getHeight() - 2)); - } + background.paint(g, new Rectangle2D.Double(2, 2, this.getSize().getWidth() - 4, + this.getSize().getHeight() - 4)); + } + } - - public void setEmptyBackground() { + + @Override + protected void paintBorder(Graphics g) { +// Color oldColor = g.getColor(); +// Border border = getBorder(); +// if (border != null) { +// border.paintBorder(this, g, 0, 0, getWidth(), getHeight()); +// } + super.paintBorder(g); + } + + public void setEmptyBackground() { this.background = null; } public void setSelfBackground(Background background) { this.background = background; } + + @Override + public Insets getInsets() { + return new Insets(0,0,0,0); + } } \ No newline at end of file diff --git a/designer-base/src/main/java/com/fr/design/style/color/NewColorSelectPane.java b/designer-base/src/main/java/com/fr/design/style/color/NewColorSelectPane.java index 8abab768a..7cf7a4708 100644 --- a/designer-base/src/main/java/com/fr/design/style/color/NewColorSelectPane.java +++ b/designer-base/src/main/java/com/fr/design/style/color/NewColorSelectPane.java @@ -39,6 +39,8 @@ public class NewColorSelectPane extends BasicPane implements ColorSelectable { private static final long serialVersionUID = -8634152305687249392L; private static final float BRIGHTNESS_VALUE = 0.15F; private static final float PURITY_VALUE = 0.1F; + private static final int WIDTH = 197; + private static final int HEIGHT = 250; private FineColor color = null; // color // color setting action. @@ -49,9 +51,6 @@ public class NewColorSelectPane extends BasicPane implements ColorSelectable { private boolean isSupportThemeColor; - public final static int TRANSPARENT_WINDOW_HEIGHT = 165; - public final static int WINDOW_HEIGHT = 150; - // 最近使用颜色 private final NewUsedColorPane usedColorPane; private final JPanel menuColorPane; @@ -84,10 +83,12 @@ public class NewColorSelectPane extends BasicPane implements ColorSelectable { this.add(centerPane, BorderLayout.CENTER); menuColorPane = getMenuColorPane(); - centerPane.add(menuColorPane); + if(isSupportThemeColor){ - initThemeColorPane(); + JPanel themePane = initThemeColorPane(); + centerPane.add(themePane); }else { + centerPane.add(menuColorPane); initMenuColorPane(); } @@ -138,8 +139,14 @@ public class NewColorSelectPane extends BasicPane implements ColorSelectable { return jPanel; } - private void initThemeColorPane(){ + private JPanel initThemeColorPane(){ menuColorPane.removeAll(); + JPanel themeColorPane = new JPanel(new BorderLayout(0, 5)); + themeColorPane.setBorder(BorderFactory.createEmptyBorder(0, 0, 0, 0)); + themeColorPane.add(new UILabel(Toolkit.i18nText("Fine-Design_Basic_Theme_Color")), BorderLayout.CENTER); + + themeColorPane.add(menuColorPane, BorderLayout.SOUTH); + menuColorPane.setLayout(new BorderLayout(0, 10)); JPanel northPane = new JPanel(new GridLayout(1, 8, 3, 0)); JPanel centerPane = new JPanel(new GridLayout(1, 8, 3, 0)); @@ -147,10 +154,6 @@ public class NewColorSelectPane extends BasicPane implements ColorSelectable { menuColorPane.add(centerPane, BorderLayout.CENTER); Color[] colorArray = new Color[] { - // 2列灰度色 - Color.decode("#B3B3B3"), - Color.decode("#808080"), - // 8列主题色 Color.decode("#FFFFFF"), Color.decode("#CCCCCC"), @@ -160,13 +163,17 @@ public class NewColorSelectPane extends BasicPane implements ColorSelectable { Color.decode("#CCCCCC"), Color.decode("#FFFFFF"), Color.decode("#CCCCCC"), + + // 2列灰度色 + Color.decode("#808080"), + Color.decode("#B3B3B3"), }; if (themeColorCellGrid == null) { themeColorCellGrid = new ColorCell[colorArray.length][5]; for (int i = 0; i < colorArray.length; i++) { ColorCell[] colorCellColumn = new ColorCell[5]; - boolean isDefaultColor = (i == 0 || i == 1); + boolean isDefaultColor = (i == colorArray.length - 1 || i == colorArray.length - 2); Color color = colorArray[i]; colorCellColumn[0] = createFineColorCell(color, isDefaultColor, i, 2); colorCellColumn[2] = createFineColorCell(color = saturationDown(color, isDefaultColor, true), isDefaultColor, i, 1); @@ -191,6 +198,7 @@ public class NewColorSelectPane extends BasicPane implements ColorSelectable { } refreshThemeMenuColorPane(); + return themeColorPane; } private void refreshThemeMenuColorPane() { @@ -210,14 +218,14 @@ public class NewColorSelectPane extends BasicPane implements ColorSelectable { return; } - for (int i = 2; i < themeColorCellGrid.length; i++) { - Color color = standardColors.get(i - 2); + for (int i = 0; i < themeColorCellGrid.length - 2; i++) { + Color color = standardColors.get(i); themeColorCellGrid[i][0].setColor(color); themeColorCellGrid[i][2].setColor(color = saturationDown(color, false, true)); themeColorCellGrid[i][1].setColor(saturationDown(color, false, true)); - color = standardColors.get(i - 2); + color = standardColors.get(i); themeColorCellGrid[i][3].setColor(color = saturationDown(color, false, false)); themeColorCellGrid[i][4].setColor(saturationDown(color, false, false)); } @@ -225,7 +233,7 @@ public class NewColorSelectPane extends BasicPane implements ColorSelectable { private FineColorCell createFineColorCell(Color color, boolean isDefaultColor, int x, int y) { - return isDefaultColor ? new FineColorCell(color, this) : new FineColorCell(color, this, x - 2, y); + return isDefaultColor ? new FineColorCell(color, this) : new FineColorCell(color, this, x, y); } /** @@ -375,10 +383,14 @@ public class NewColorSelectPane extends BasicPane implements ColorSelectable { @Override public Dimension getPreferredSize() { + int height = HEIGHT; if (isSupportTransparent) { - return new Dimension(197, 265); + height += 15; + } + if (isSupportThemeColor) { + height += 25; } - return new Dimension(197, 250); + return new Dimension(WIDTH, height); } /** From 2bfdda603cb71f95c261dddef312d6576f61542b Mon Sep 17 00:00:00 2001 From: kuangshuai Date: Thu, 2 Sep 2021 14:44:55 +0800 Subject: [PATCH 03/17] =?UTF-8?q?REPORT-58655=20=E5=A4=8D=E7=94=A8?= =?UTF-8?q?=E7=BB=84=E4=BB=B6=E7=9A=84=E5=9C=A8=E7=BA=BF=E6=90=9C=E7=B4=A2?= =?UTF-8?q?=E9=9C=80=E8=A6=81=E5=9C=A8=E7=AD=9B=E9=80=89=E6=9D=A1=E4=BB=B6?= =?UTF-8?q?=E4=B8=8B=E6=90=9C=E7=B4=A2?= MIME-Version: 1.0 Content-Type: text/plain; charset=UTF-8 Content-Transfer-Encoding: 8bit --- .../share/ui/online/AbstractOnlineWidgetShowPane.java | 5 +---- 1 file changed, 1 insertion(+), 4 deletions(-) diff --git a/designer-form/src/main/java/com/fr/design/mainframe/share/ui/online/AbstractOnlineWidgetShowPane.java b/designer-form/src/main/java/com/fr/design/mainframe/share/ui/online/AbstractOnlineWidgetShowPane.java index 7c090cac3..117ac0ab8 100644 --- a/designer-form/src/main/java/com/fr/design/mainframe/share/ui/online/AbstractOnlineWidgetShowPane.java +++ b/designer-form/src/main/java/com/fr/design/mainframe/share/ui/online/AbstractOnlineWidgetShowPane.java @@ -47,14 +47,11 @@ public abstract class AbstractOnlineWidgetShowPane extends JPanel { private OnlineShareWidget[] sharableWidgetProviders; - //缓存一份用于搜索 - private final OnlineShareWidget[] sharableWidgetCache; //主面板和搜索面板的cardLayout private CardLayout mainCardLayout; public AbstractOnlineWidgetShowPane(OnlineShareWidget[] sharableWidgetProviders) { - this.sharableWidgetCache = sharableWidgetProviders; this.sharableWidgetProviders = sharableWidgetProviders; this.setLayout(FRGUIPaneFactory.createBorderLayout()); JPanel contentPane = initContentPane(); @@ -119,7 +116,7 @@ public abstract class AbstractOnlineWidgetShowPane extends JPanel { } List widgets = new ArrayList<>(); if (StringUtils.isNotEmpty(text)) { - for (OnlineShareWidget provider : sharableWidgetCache) { + for (OnlineShareWidget provider : sharableWidgetProviders) { if (provider.getName().toLowerCase().contains(text)) { widgets.add(provider); } From 26afc981ccce435c29025aa26eed946b0c86ee4f Mon Sep 17 00:00:00 2001 From: Starryi Date: Thu, 2 Sep 2021 14:25:45 +0800 Subject: [PATCH 04/17] =?UTF-8?q?REPORT-58667=20=E3=80=90=E4=B8=BB?= =?UTF-8?q?=E9=A2=98=E5=88=87=E6=8D=A2=E3=80=91=E4=BF=AE=E6=94=B9=E6=A8=A1?= =?UTF-8?q?=E6=9D=BF=E4=B8=BB=E9=A2=98=E7=AE=A1=E7=90=86=E7=9A=84tab?= =?UTF-8?q?=E5=90=8D=E7=A7=B0=E3=80=81=E7=AA=97=E5=8F=A3=E5=90=8D=E7=A7=B0?= MIME-Version: 1.0 Content-Type: text/plain; charset=UTF-8 Content-Transfer-Encoding: 8bit 【问题原因】 新增了聚合报表的主题,所以名称需要改下 【改动思路】 同上 --- .../mainframe/theme/dialog/TemplateThemeManageDialog.java | 4 ++-- 1 file changed, 2 insertions(+), 2 deletions(-) diff --git a/designer-base/src/main/java/com/fr/design/mainframe/theme/dialog/TemplateThemeManageDialog.java b/designer-base/src/main/java/com/fr/design/mainframe/theme/dialog/TemplateThemeManageDialog.java index e7acb8d8a..31762e72e 100644 --- a/designer-base/src/main/java/com/fr/design/mainframe/theme/dialog/TemplateThemeManageDialog.java +++ b/designer-base/src/main/java/com/fr/design/mainframe/theme/dialog/TemplateThemeManageDialog.java @@ -70,8 +70,8 @@ public class TemplateThemeManageDialog extends TemplateThemeDialog { reportThemesManagerPane = TemplateThemeManagePane.createReportThemesManagerPane(); reportThemesManagerPane.startListenThemeConfig(); - tabbedPane.addTab(Toolkit.i18nText("Fine-Design_Basic_Template_Theme_Manager_Dialog_FORM_TAB"), formThemesManagerPane); - tabbedPane.addTab(Toolkit.i18nText("Fine-Design_Basic_Template_Theme_Manager_Dialog_REPORT_TAB"), reportThemesManagerPane); + tabbedPane.addTab(Toolkit.i18nText("Fine-Design_Basic_Template_Theme_Manager_Dialog_Form_Tab"), formThemesManagerPane); + tabbedPane.addTab(Toolkit.i18nText("Fine-Design_Basic_Template_Theme_Manager_Dialog_Report_Tab"), reportThemesManagerPane); tabbedPane.setSelectedIndex(0); JTemplate template = HistoryTemplateListCache.getInstance().getCurrentEditingTemplate(); From e26869085a774d02112afb33e31846397440b037 Mon Sep 17 00:00:00 2001 From: Starryi Date: Thu, 2 Sep 2021 15:07:40 +0800 Subject: [PATCH 05/17] =?UTF-8?q?CHART-20536=20=E5=9B=BE=E8=A1=A8=E9=A2=84?= =?UTF-8?q?=E5=AE=9A=E4=B9=89=E9=85=8D=E8=89=B2=EF=BC=8C=E5=8D=87=E7=BA=A7?= =?UTF-8?q?=E5=85=BC=E5=AE=B9=E5=90=8E=EF=BC=8C=E4=B8=BB=E9=A2=98=E9=85=8D?= =?UTF-8?q?=E8=89=B2=E9=9D=A2=E6=9D=BF=E5=86=85=E5=AE=B9=E5=9B=BA=E5=AE=9A?= =?UTF-8?q?=E4=B8=8D=E5=8F=98?= MIME-Version: 1.0 Content-Type: text/plain; charset=UTF-8 Content-Transfer-Encoding: 8bit 【问题原因】 1. 兼容主题支持当前图表预定义配色 2. 图表预定义配色的数量导致主题色中实际颜色的数量可能 超过八个(但用户在界面上只能看到并编辑前八个),因此 需要调整下颜色选择面板等组件 【改动思路】 同上 --- .../theme/edit/ui/ColorListExtendedPane.java | 7 ++----- .../design/mainframe/theme/edit/ui/ColorListPane.java | 11 +++++++---- .../com/fr/design/style/color/NewColorSelectPane.java | 2 +- 3 files changed, 10 insertions(+), 10 deletions(-) diff --git a/designer-base/src/main/java/com/fr/design/mainframe/theme/edit/ui/ColorListExtendedPane.java b/designer-base/src/main/java/com/fr/design/mainframe/theme/edit/ui/ColorListExtendedPane.java index 4aac8562d..9d02180e7 100644 --- a/designer-base/src/main/java/com/fr/design/mainframe/theme/edit/ui/ColorListExtendedPane.java +++ b/designer-base/src/main/java/com/fr/design/mainframe/theme/edit/ui/ColorListExtendedPane.java @@ -66,10 +66,7 @@ public class ColorListExtendedPane extends JPanel implements MouseListener { public void populate(List colors) { if (colors.size() > 0) { colorList.clear(); - for (int i = 0; i < colorCount; i++) { - Color color = colors.get(i % colorCount); - colorList.add(color); - } + colorList.addAll(colors); repaint(); } } @@ -132,7 +129,7 @@ public class ColorListExtendedPane extends JPanel implements MouseListener { super.paint(g); Color oldColor = g.getColor(); - for (int i = 0; i < colorList.size(); i++) { + for (int i = 0; i < colorCount; i++) { int x = i * (boxSize + boxGap); for (int j = 0; j < extendedCount; j++) { Color color = extendedColorComputer.computeExtendedColor(colorList.get(i), j, extendedCount); diff --git a/designer-base/src/main/java/com/fr/design/mainframe/theme/edit/ui/ColorListPane.java b/designer-base/src/main/java/com/fr/design/mainframe/theme/edit/ui/ColorListPane.java index 2bf1931f1..adeca3d7a 100644 --- a/designer-base/src/main/java/com/fr/design/mainframe/theme/edit/ui/ColorListPane.java +++ b/designer-base/src/main/java/com/fr/design/mainframe/theme/edit/ui/ColorListPane.java @@ -88,10 +88,13 @@ public class ColorListPane extends JPanel implements UIObserver { } public void populate(List colors) { - for (int i = 0; i < colors.size() && i < colorList.size(); i++) { - Color color = colors.get(i % colorCount); - colorList.set(i, color); - colorButtons.get(i).setSelectObject(color); + colorList.clear(); + for (int i = 0; i < colors.size(); i++) { + Color color = colors.get(i); + colorList.add(color); + if (i < colorCount) { + colorButtons.get(i).setSelectObject(color); + } } } diff --git a/designer-base/src/main/java/com/fr/design/style/color/NewColorSelectPane.java b/designer-base/src/main/java/com/fr/design/style/color/NewColorSelectPane.java index 8abab768a..6a5bcb78b 100644 --- a/designer-base/src/main/java/com/fr/design/style/color/NewColorSelectPane.java +++ b/designer-base/src/main/java/com/fr/design/style/color/NewColorSelectPane.java @@ -206,7 +206,7 @@ public class NewColorSelectPane extends BasicPane implements ColorSelectable { } } } - if (standardColors == null || standardColors.size() != 8) { + if (standardColors == null || standardColors.size() < 8) { return; } From bae26e337e9e306bf17bafbb57355e2f979d0fdf Mon Sep 17 00:00:00 2001 From: Starryi Date: Thu, 2 Sep 2021 15:36:17 +0800 Subject: [PATCH 06/17] =?UTF-8?q?REPORT-58539=20=E3=80=90=E4=B8=BB?= =?UTF-8?q?=E9=A2=98=E5=88=87=E6=8D=A2=E3=80=91=E6=82=AC=E6=B5=AE=E5=85=83?= =?UTF-8?q?=E7=B4=A0-=E6=A0=B7=E5=BC=8F=E7=AA=97=E5=8F=A3ui=E4=BC=98?= =?UTF-8?q?=E5=8C=96?= MIME-Version: 1.0 Content-Type: text/plain; charset=UTF-8 Content-Transfer-Encoding: 8bit 【问题原因】 修复悬浮元素样式面板的标题边框文字颜色为黑色的问题 【改动思路】 同上 --- .../src/main/java/com/fr/design/style/AlignmentPane.java | 7 ++++--- .../src/main/java/com/fr/design/style/BorderPane.java | 5 +++-- 2 files changed, 7 insertions(+), 5 deletions(-) diff --git a/designer-base/src/main/java/com/fr/design/style/AlignmentPane.java b/designer-base/src/main/java/com/fr/design/style/AlignmentPane.java index 136de486a..22f60b185 100644 --- a/designer-base/src/main/java/com/fr/design/style/AlignmentPane.java +++ b/designer-base/src/main/java/com/fr/design/style/AlignmentPane.java @@ -5,6 +5,7 @@ package com.fr.design.style; import com.fr.base.BaseUtils; import com.fr.base.Style; +import com.fr.design.border.UITitledBorder; import com.fr.design.dialog.BasicPane; import com.fr.design.gui.ibutton.UIRadioButton; import com.fr.design.gui.icheckbox.UICheckBox; @@ -86,7 +87,7 @@ public class AlignmentPane extends BasicPane { //richer:文本控制和图片布局 JPanel textDirectionPanel = FRGUIPaneFactory.createY_AXISBoxInnerContainer_S_Pane(); contentPane.add(textDirectionPanel); - textDirectionPanel.setBorder(GUICoreUtils.createTitledBorder(com.fr.design.i18n.Toolkit.i18nText("Fine-Design_Basic_StyleAlignment_Text_Rotation"), null)); + textDirectionPanel.setBorder(UITitledBorder.createBorderWithTitle(com.fr.design.i18n.Toolkit.i18nText("Fine-Design_Basic_StyleAlignment_Text_Rotation"))); JPanel isVerticalTextPanel = FRGUIPaneFactory.createMediumHGapFlowInnerContainer_M_Pane(); textDirectionPanel.add(isVerticalTextPanel); initVerticalPane(isVerticalTextPanel); @@ -131,7 +132,7 @@ public class AlignmentPane extends BasicPane { private void initSpacingPane (JPanel spacingPane) { spacingPane.setLayout(new GridLayout(1, 3)); - spacingPane.setBorder(BorderFactory.createTitledBorder(com.fr.design.i18n.Toolkit.i18nText("Fine-Design_Basic_Style_Spacing") + ":")); + spacingPane.setBorder(UITitledBorder.createBorderWithTitle(com.fr.design.i18n.Toolkit.i18nText("Fine-Design_Basic_Style_Spacing") + ":")); spacingBeforeSpinner = new UIBasicSpinner(new SpinnerNumberModel(new Integer(0), new Integer(0), null, new Integer(1))); spacingBeforeSpinner.addChangeListener(changeListener); @@ -153,7 +154,7 @@ public class AlignmentPane extends BasicPane { private JPanel getIndentPane() { JPanel indentPane = FRGUIPaneFactory.createMediumHGapFlowInnerContainer_M_Pane(); - indentPane.setBorder(GUICoreUtils.createTitledBorder(com.fr.design.i18n.Toolkit.i18nText("Fine-Design_Basic_Sytle_Indentation"), null)); + indentPane.setBorder(UITitledBorder.createBorderWithTitle(com.fr.design.i18n.Toolkit.i18nText("Fine-Design_Basic_Sytle_Indentation"))); Comparable maximum = null; leftIndentSpinner = new UIBasicSpinner(new SpinnerNumberModel(new Integer(0), new Integer(0), maximum, new Integer(1))); leftIndentSpinner.addChangeListener(changeListener); diff --git a/designer-base/src/main/java/com/fr/design/style/BorderPane.java b/designer-base/src/main/java/com/fr/design/style/BorderPane.java index 442f30189..c9dff2c3d 100644 --- a/designer-base/src/main/java/com/fr/design/style/BorderPane.java +++ b/designer-base/src/main/java/com/fr/design/style/BorderPane.java @@ -7,6 +7,7 @@ import com.fr.base.BaseUtils; import com.fr.base.CellBorderStyle; import com.fr.base.GraphHelper; import com.fr.base.Style; +import com.fr.design.border.UITitledBorder; import com.fr.design.dialog.BasicPane; import com.fr.design.gui.ibutton.UIButton; import com.fr.design.gui.icombobox.LineComboBox; @@ -96,7 +97,7 @@ public class BorderPane extends BasicPane { JPanel centerPane = FRGUIPaneFactory.createBorderLayout_S_Pane(); - centerPane.setBorder(GUICoreUtils.createTitledBorder(com.fr.design.i18n.Toolkit.i18nText("Fine-Design_Basic_Preview"), null)); + centerPane.setBorder(UITitledBorder.createBorderWithTitle(com.fr.design.i18n.Toolkit.i18nText("Fine-Design_Basic_Preview"))); JPanel borderAllControlPane = FRGUIPaneFactory.createCenterFlowInnerContainer_S_Pane(); centerPane.add(borderAllControlPane, BorderLayout.NORTH); borderAllControlPane.setBorder(BorderFactory.createEmptyBorder(0, 0, 4, 0)); @@ -147,7 +148,7 @@ public class BorderPane extends BasicPane { JPanel northPane = FRGUIPaneFactory.createBorderLayout_S_Pane(); - northPane.setBorder(GUICoreUtils.createTitledBorder(com.fr.design.i18n.Toolkit.i18nText("Fine-Design_Basic_Line"), null)); + northPane.setBorder(UITitledBorder.createBorderWithTitle(com.fr.design.i18n.Toolkit.i18nText("Fine-Design_Basic_Line"))); JPanel rightTopPane = FRGUIPaneFactory.createBorderLayout_S_Pane(); northPane.add(rightTopPane, BorderLayout.NORTH); JPanel first = FRGUIPaneFactory.createNormalFlowInnerContainer_S_Pane(); From a2c89df2d535ea06afdb74975ec129316ac19ac5 Mon Sep 17 00:00:00 2001 From: Starryi Date: Thu, 2 Sep 2021 16:50:20 +0800 Subject: [PATCH 07/17] =?UTF-8?q?REPORT-58520=20FR11-=E4=BA=8C=E8=BD=AE?= =?UTF-8?q?=E5=9B=9E=E5=BD=92-=E6=A8=A1=E6=9D=BF-=E7=BA=B8=E5=BC=A0?= =?UTF-8?q?=E8=83=8C=E6=99=AF-=E8=83=8C=E6=99=AF=E8=AE=BE=E7=BD=AE?= =?UTF-8?q?=E6=98=BE=E7=A4=BA=E4=B8=8D=E5=85=A8?= MIME-Version: 1.0 Content-Type: text/plain; charset=UTF-8 Content-Transfer-Encoding: 8bit 【问题原因】 左侧背景预览面板宽度应自适应 【改动思路】 同上 --- .../java/com/fr/design/report/NewReportBackgroundPane.java | 4 ++-- 1 file changed, 2 insertions(+), 2 deletions(-) diff --git a/designer-realize/src/main/java/com/fr/design/report/NewReportBackgroundPane.java b/designer-realize/src/main/java/com/fr/design/report/NewReportBackgroundPane.java index 0e5b32789..cf514512d 100644 --- a/designer-realize/src/main/java/com/fr/design/report/NewReportBackgroundPane.java +++ b/designer-realize/src/main/java/com/fr/design/report/NewReportBackgroundPane.java @@ -140,11 +140,11 @@ public class NewReportBackgroundPane extends BasicPane { } }); - JPanel contentContainer = FRGUIPaneFactory.createBorderLayout_S_Pane(); + JPanel contentContainer = new JPanel(new BorderLayout(IntervalConstants.INTERVAL_L6, 0)); contentContainer.setBorder(BorderFactory.createEmptyBorder()); contentContainer.setBorder(BorderFactory.createEmptyBorder()); contentContainer.setPreferredSize(new Dimension(600, 540)); - contentContainer.add(createLeftPane(), BorderLayout.WEST); + contentContainer.add(createLeftPane(), BorderLayout.CENTER); contentContainer.add(createRightPane(), BorderLayout.EAST); addAttributeChangeListener(new AttributeChangeListener() { From 622c0456b3ebd8b66f498d05493636d8536d17cf Mon Sep 17 00:00:00 2001 From: =?UTF-8?q?=E6=96=B9=E7=A3=8A?= <294531121@qq.com> Date: Thu, 2 Sep 2021 16:50:46 +0800 Subject: [PATCH 08/17] =?UTF-8?q?REPORT-57881=2010.0.19=E4=B8=80=E8=BD=AE?= =?UTF-8?q?=E5=86=92=E7=83=9F-=E6=96=AD=E7=BD=91=E6=97=B6=E6=89=93?= =?UTF-8?q?=E5=BC=80=E8=AE=BE=E8=AE=A1=E5=99=A8=E5=86=85=E7=BD=AE=E5=B8=AE?= =?UTF-8?q?=E5=8A=A9=E6=96=87=E6=A1=A3=EF=BC=8C=E6=97=A5=E5=BF=97=E4=B8=AD?= =?UTF-8?q?=E6=B2=A1=E6=9C=89=E7=A6=BB=E7=BA=BF=E6=8F=90=E7=A4=BA?= MIME-Version: 1.0 Content-Type: text/plain; charset=UTF-8 Content-Transfer-Encoding: 8bit --- .../com/fr/design/actions/help/TutorialAction.java | 5 +++++ .../java/com/fr/design/login/AbstractDesignerSSO.java | 11 +++++++++++ 2 files changed, 16 insertions(+) diff --git a/designer-base/src/main/java/com/fr/design/actions/help/TutorialAction.java b/designer-base/src/main/java/com/fr/design/actions/help/TutorialAction.java index cf4f02f40..3e08b1399 100644 --- a/designer-base/src/main/java/com/fr/design/actions/help/TutorialAction.java +++ b/designer-base/src/main/java/com/fr/design/actions/help/TutorialAction.java @@ -1,5 +1,6 @@ package com.fr.design.actions.help; +import com.fr.design.i18n.Toolkit; import com.fr.design.login.AbstractDesignerSSO; import com.fr.design.menu.MenuKeySet; import com.fr.general.CloudCenter; @@ -52,6 +53,10 @@ public class TutorialAction extends AbstractDesignerSSO { } } + public String getOffLineWarnMessage() { + return Toolkit.i18nText("Fine-Design_Offline_Helptutorial_Msg"); + } + public static final MenuKeySet HELP_TUTORIAL = new MenuKeySet() { @Override public char getMnemonic() { diff --git a/designer-base/src/main/java/com/fr/design/login/AbstractDesignerSSO.java b/designer-base/src/main/java/com/fr/design/login/AbstractDesignerSSO.java index 2662198bb..f38fc1d08 100644 --- a/designer-base/src/main/java/com/fr/design/login/AbstractDesignerSSO.java +++ b/designer-base/src/main/java/com/fr/design/login/AbstractDesignerSSO.java @@ -6,6 +6,9 @@ import com.fr.design.actions.UpdateAction; import com.fr.design.login.utils.DesignerLoginUtils; import com.fr.design.os.impl.SupportOSImpl; import com.fr.design.utils.BrowseUtils; +import com.fr.log.FineLoggerFactory; +import com.fr.stable.StringUtils; + import java.awt.event.ActionEvent; import java.util.HashMap; import java.util.Map; @@ -21,6 +24,10 @@ public abstract class AbstractDesignerSSO extends UpdateAction { public void actionPerformed(ActionEvent event) { String url = getJumpUrl(); if (!DesignerLoginUtils.isOnline()) { + String message = getOffLineWarnMessage(); + if (StringUtils.isNotEmpty(message)) { + FineLoggerFactory.getLogger().warn(message); + } BrowseUtils.browser(url); return; } @@ -47,4 +54,8 @@ public abstract class AbstractDesignerSSO extends UpdateAction { } public abstract String getJumpUrl(); + + public String getOffLineWarnMessage() { + return StringUtils.EMPTY; + } } From a4350ad4baab9b28b09939795391537184d56ea8 Mon Sep 17 00:00:00 2001 From: kerry Date: Thu, 2 Sep 2021 17:49:33 +0800 Subject: [PATCH 09/17] =?UTF-8?q?REPORT-58543=E3=80=90=E4=B8=BB=E9=A2=98?= =?UTF-8?q?=E5=88=87=E6=8D=A2=E3=80=91=E5=AD=97=E7=AC=A6=E9=A2=9C=E8=89=B2?= =?UTF-8?q?=E7=9A=84=E4=B8=BB=E9=A2=98=E8=89=B2=E6=8E=A7=E4=BB=B6=E4=B8=AD?= =?UTF-8?q?=E7=9A=84=E8=89=B2=E5=9D=97=E6=B2=A1=E6=9C=89=E9=80=89=E4=B8=AD?= =?UTF-8?q?=E7=8A=B6=E6=80=81?= MIME-Version: 1.0 Content-Type: text/plain; charset=UTF-8 Content-Transfer-Encoding: 8bit --- .../fr/design/gui/ibutton/UIColorButton.java | 1 + .../theme/preview/ComponentPreviewPane.java | 40 +++++++- .../ecpreview/cell/AbstractPreviewCell.java | 7 +- .../style/color/ColorControlWindow.java | 4 + .../color/ColorControlWindowWithAuto.java | 5 + .../style/color/NewColorSelectPane.java | 92 ++++++++----------- 6 files changed, 89 insertions(+), 60 deletions(-) diff --git a/designer-base/src/main/java/com/fr/design/gui/ibutton/UIColorButton.java b/designer-base/src/main/java/com/fr/design/gui/ibutton/UIColorButton.java index 8171f31cb..31a6d963d 100644 --- a/designer-base/src/main/java/com/fr/design/gui/ibutton/UIColorButton.java +++ b/designer-base/src/main/java/com/fr/design/gui/ibutton/UIColorButton.java @@ -136,6 +136,7 @@ public class UIColorButton extends UIButton implements PopupHider, UIObserver, G } popupWin = this.getColorControlWindow(); + popupWin.setColor(color); GUICoreUtils.showPopupMenu(popupWin, this, POPUP_MENU_SHIFT, this.getSize().height); } diff --git a/designer-base/src/main/java/com/fr/design/mainframe/theme/preview/ComponentPreviewPane.java b/designer-base/src/main/java/com/fr/design/mainframe/theme/preview/ComponentPreviewPane.java index da7f7bac5..d7bdfadfd 100644 --- a/designer-base/src/main/java/com/fr/design/mainframe/theme/preview/ComponentPreviewPane.java +++ b/designer-base/src/main/java/com/fr/design/mainframe/theme/preview/ComponentPreviewPane.java @@ -6,7 +6,6 @@ import com.fr.base.background.ImageBackground; import com.fr.base.theme.FormTheme; import com.fr.base.theme.settings.ThemedComponentStyle; import com.fr.design.border.UIRoundedBorder; -import com.fr.design.gui.ilable.UILabel; import com.fr.design.layout.FRGUIPaneFactory; import com.fr.form.ui.Label; import com.fr.form.ui.LayoutBorderStyle; @@ -20,15 +19,20 @@ import javax.swing.BorderFactory; import javax.swing.JPanel; import javax.swing.SwingConstants; import javax.swing.border.Border; +import javax.swing.border.LineBorder; import java.awt.AlphaComposite; +import java.awt.BasicStroke; import java.awt.BorderLayout; +import java.awt.Color; import java.awt.Component; import java.awt.Composite; import java.awt.Dimension; import java.awt.Graphics; import java.awt.Graphics2D; import java.awt.Image; +import java.awt.RenderingHints; import java.awt.Shape; +import java.awt.Stroke; import java.awt.geom.Rectangle2D; import java.awt.geom.RoundRectangle2D; @@ -67,7 +71,11 @@ public abstract class ComponentPreviewPane extends UINoOpaquePanel implements Th ThemedComponentStyle componentStyle = theme.getComponentStyle(); style = componentStyle.getStyle(); - setBorder(new UIRoundedBorder(style.getBorder(), style.getColor(), style.getBorderRadius())); + if (style.getBorder() == 0) { + setBorder(null); + } else { + setBorder(new UIRoundedBorder(style.getBorder(), style.getColor(), style.getBorderRadius())); + } int paddingTop = componentStyle.getPaddingTop(); int paddingBottom = componentStyle.getPaddingBottom(); @@ -116,8 +124,10 @@ public abstract class ComponentPreviewPane extends UINoOpaquePanel implements Th data.setInsetImagePadding(titlePacker.getInsetImagePadding()); data.setInsetRelativeTextLeft(titlePacker.isInsetRelativeTextLeft()); data.setInsetRelativeTextRight(titlePacker.isInsetRelativeTextRight()); + this.setBorder(new BottomLineBorder(componentStyle.getStyle().getColor(), componentStyle.getStyle().getBorder())); } + @Override public void paintComponent(Graphics g) { super.paintComponent(g); @@ -145,6 +155,32 @@ public abstract class ComponentPreviewPane extends UINoOpaquePanel implements Th } + public static class BottomLineBorder extends LineBorder { + + private BottomLineBorder(Color color, int thickness) { + super(color, thickness); + } + + @Override + public void paintBorder(Component c, Graphics g, int x, int y, int width, int height) { + Graphics2D g2d = (Graphics2D) g; + + Color oldColor = g2d.getColor(); + Stroke oldStroke = g2d.getStroke(); + + g2d.setRenderingHint(RenderingHints.KEY_ANTIALIASING, RenderingHints.VALUE_ANTIALIAS_ON); + + g2d.setColor(getLineColor()); + g2d.setStroke(new BasicStroke(getThickness() * 2)); + g2d.drawLine(0, height, width, height); + + g2d.setStroke(oldStroke); + g2d.setColor(oldColor); + g2d.setRenderingHint(RenderingHints.KEY_ANTIALIASING, RenderingHints.VALUE_ANTIALIAS_OFF); + } + } + + private static class Utils { private static void paintBackground(Graphics2D g2d, Background background, Shape shape, float opacity) { if (background != null) { diff --git a/designer-base/src/main/java/com/fr/design/mainframe/theme/preview/ecpreview/cell/AbstractPreviewCell.java b/designer-base/src/main/java/com/fr/design/mainframe/theme/preview/ecpreview/cell/AbstractPreviewCell.java index 9c7c335de..a8a5f1892 100644 --- a/designer-base/src/main/java/com/fr/design/mainframe/theme/preview/ecpreview/cell/AbstractPreviewCell.java +++ b/designer-base/src/main/java/com/fr/design/mainframe/theme/preview/ecpreview/cell/AbstractPreviewCell.java @@ -1,8 +1,6 @@ package com.fr.design.mainframe.theme.preview.ecpreview.cell; -import com.fr.base.ScreenResolution; import com.fr.base.Style; - import javax.swing.JComponent; import java.awt.Dimension; import java.awt.Graphics; @@ -10,6 +8,8 @@ import java.awt.Graphics2D; public abstract class AbstractPreviewCell extends JComponent { protected Style style = Style.DEFAULT_STYLE; + private static final int NO_SCALE_RESOLUTION = 100; + public void refresh(Style style) { this.style = style; @@ -17,9 +17,8 @@ public abstract class AbstractPreviewCell extends JComponent { public void paint(Graphics g) { Graphics2D g2d = (Graphics2D) g; - int resolution = ScreenResolution.getScreenResolution(); Style.paintBackground(g2d, style, getWidth(), getHeight()); - paintContent(g2d, resolution); + paintContent(g2d, NO_SCALE_RESOLUTION); Style.paintBorder(g2d, style, getWidth(), getHeight()); } diff --git a/designer-base/src/main/java/com/fr/design/style/color/ColorControlWindow.java b/designer-base/src/main/java/com/fr/design/style/color/ColorControlWindow.java index 43f994a65..7fccbfde2 100644 --- a/designer-base/src/main/java/com/fr/design/style/color/ColorControlWindow.java +++ b/designer-base/src/main/java/com/fr/design/style/color/ColorControlWindow.java @@ -38,6 +38,10 @@ public abstract class ColorControlWindow extends JPopupMenu { return selectionPopupPane.getColor(); } + public void setColor(Color color) { + selectionPopupPane.setColor(color); + } + public PopupHider getPopupHider() { return popupHider; } diff --git a/designer-base/src/main/java/com/fr/design/style/color/ColorControlWindowWithAuto.java b/designer-base/src/main/java/com/fr/design/style/color/ColorControlWindowWithAuto.java index dc4eb9571..01351bfed 100644 --- a/designer-base/src/main/java/com/fr/design/style/color/ColorControlWindowWithAuto.java +++ b/designer-base/src/main/java/com/fr/design/style/color/ColorControlWindowWithAuto.java @@ -39,6 +39,11 @@ public abstract class ColorControlWindowWithAuto extends ColorControlWindow { return selectionPopupPaneWithAuto.getColor(); } + public void setColor(Color color) { + selectionPopupPaneWithAuto.setColor(color); + } + + protected void initSelectionPopupPane(boolean isSupportTransparent) { selectionPopupPaneWithAuto = new ColorSelectionPopupPaneWithAuto(isSupportTransparent); this.add(selectionPopupPaneWithAuto, BorderLayout.CENTER); diff --git a/designer-base/src/main/java/com/fr/design/style/color/NewColorSelectPane.java b/designer-base/src/main/java/com/fr/design/style/color/NewColorSelectPane.java index 7cf7a4708..1b7af375f 100644 --- a/designer-base/src/main/java/com/fr/design/style/color/NewColorSelectPane.java +++ b/designer-base/src/main/java/com/fr/design/style/color/NewColorSelectPane.java @@ -1,6 +1,7 @@ package com.fr.design.style.color; import com.fr.base.FineColor; +import com.fr.base.theme.FineColorDeriveState; import com.fr.base.theme.TemplateTheme; import com.fr.design.DesignerEnvManager; import com.fr.design.border.UIRoundedBorder; @@ -37,10 +38,11 @@ import java.util.List; */ public class NewColorSelectPane extends BasicPane implements ColorSelectable { private static final long serialVersionUID = -8634152305687249392L; - private static final float BRIGHTNESS_VALUE = 0.15F; - private static final float PURITY_VALUE = 0.1F; + private static final int WIDTH = 197; private static final int HEIGHT = 250; + //颜色衍生的数量 + private static final int DEFAULT_DERIVE_COUNT = 5; private FineColor color = null; // color // color setting action. @@ -56,7 +58,7 @@ public class NewColorSelectPane extends BasicPane implements ColorSelectable { private final JPanel menuColorPane; private ColorCell[][] themeColorCellGrid; - public static NewColorSelectPane createColorSelectPaneWithTheme(boolean supportTheme){ + public static NewColorSelectPane createColorSelectPaneWithTheme(boolean supportTheme) { return new NewColorSelectPane(true, supportTheme); } @@ -79,15 +81,15 @@ public class NewColorSelectPane extends BasicPane implements ColorSelectable { initSelectButton(isSupportTransparent); // center JPanel centerPane = FRGUIPaneFactory.createY_AXISBoxInnerContainer_S_Pane(); - centerPane.setBorder(BorderFactory.createEmptyBorder(10, 4, 0 ,4)); + centerPane.setBorder(BorderFactory.createEmptyBorder(10, 4, 0, 4)); this.add(centerPane, BorderLayout.CENTER); menuColorPane = getMenuColorPane(); - if(isSupportThemeColor){ + if (isSupportThemeColor) { JPanel themePane = initThemeColorPane(); centerPane.add(themePane); - }else { + } else { centerPane.add(menuColorPane); initMenuColorPane(); } @@ -130,7 +132,7 @@ public class NewColorSelectPane extends BasicPane implements ColorSelectable { centerPane.add(centerPane1); } - private JPanel createStandardColorPane(){ + private JPanel createStandardColorPane() { JPanel jPanel = new JPanel(new GridLayout(1, 10, 3, 0)); Color[] colorArray = ColorFactory.STANDARD_COLORS; for (int i = 0; i < colorArray.length; i++) { @@ -139,7 +141,7 @@ public class NewColorSelectPane extends BasicPane implements ColorSelectable { return jPanel; } - private JPanel initThemeColorPane(){ + private JPanel initThemeColorPane() { menuColorPane.removeAll(); JPanel themeColorPane = new JPanel(new BorderLayout(0, 5)); themeColorPane.setBorder(BorderFactory.createEmptyBorder(0, 0, 0, 0)); @@ -153,7 +155,7 @@ public class NewColorSelectPane extends BasicPane implements ColorSelectable { menuColorPane.add(northPane, BorderLayout.NORTH); menuColorPane.add(centerPane, BorderLayout.CENTER); - Color[] colorArray = new Color[] { + Color[] colorArray = new Color[]{ // 8列主题色 Color.decode("#FFFFFF"), Color.decode("#CCCCCC"), @@ -165,22 +167,20 @@ public class NewColorSelectPane extends BasicPane implements ColorSelectable { Color.decode("#CCCCCC"), // 2列灰度色 - Color.decode("#808080"), - Color.decode("#B3B3B3"), + Color.decode("#333333"), + Color.decode("#FFFFFF"), }; if (themeColorCellGrid == null) { - themeColorCellGrid = new ColorCell[colorArray.length][5]; + themeColorCellGrid = new ColorCell[colorArray.length][DEFAULT_DERIVE_COUNT]; for (int i = 0; i < colorArray.length; i++) { - ColorCell[] colorCellColumn = new ColorCell[5]; + ColorCell[] colorCellColumn = new ColorCell[DEFAULT_DERIVE_COUNT]; boolean isDefaultColor = (i == colorArray.length - 1 || i == colorArray.length - 2); Color color = colorArray[i]; - colorCellColumn[0] = createFineColorCell(color, isDefaultColor, i, 2); - colorCellColumn[2] = createFineColorCell(color = saturationDown(color, isDefaultColor, true), isDefaultColor, i, 1); - colorCellColumn[1] = createFineColorCell(saturationDown(color, isDefaultColor, true), isDefaultColor, i, 0); - color = colorArray[i]; - colorCellColumn[3] = createFineColorCell(color = saturationDown(color, isDefaultColor, false), isDefaultColor, i, 3); - colorCellColumn[4] = createFineColorCell(saturationDown(color, isDefaultColor, false), isDefaultColor, i, 4); + Color[] deriveColorArr = FineColorDeriveState.getDeriveColorArr(color, isDefaultColor, DEFAULT_DERIVE_COUNT); + for (int j = 0; j < deriveColorArr.length; j++) { + colorCellColumn[j] = createFineColorCell(deriveColorArr[j], isDefaultColor, i, j); + } themeColorCellGrid[i] = colorCellColumn; } } @@ -189,11 +189,10 @@ public class NewColorSelectPane extends BasicPane implements ColorSelectable { northPane.add(themeColorCellGrid[i][0]); } for (int i = 0; i < colorArray.length; i++) { - JPanel columnPane = new JPanel(new GridLayout(4, 1, 0, 3)); - columnPane.add(themeColorCellGrid[i][1]); - columnPane.add(themeColorCellGrid[i][2]); - columnPane.add(themeColorCellGrid[i][3]); - columnPane.add(themeColorCellGrid[i][4]); + JPanel columnPane = new JPanel(new GridLayout(DEFAULT_DERIVE_COUNT - 1, 1, 0, 3)); + for (int j = 1; j < DEFAULT_DERIVE_COUNT; j++) { + columnPane.add(themeColorCellGrid[i][j]); + } centerPane.add(columnPane); } @@ -206,7 +205,7 @@ public class NewColorSelectPane extends BasicPane implements ColorSelectable { if (TemplateThemeProfileDialog.isEditingTheme()) { standardColors = TemplateThemeProfileDialog.getEditingColorScheme(); } else { - JTemplate template = HistoryTemplateListCache.getInstance().getCurrentEditingTemplate(); + JTemplate template = HistoryTemplateListCache.getInstance().getCurrentEditingTemplate(); if (template != null) { TemplateTheme theme = template.getTemplateTheme(); if (theme != null) { @@ -220,14 +219,10 @@ public class NewColorSelectPane extends BasicPane implements ColorSelectable { for (int i = 0; i < themeColorCellGrid.length - 2; i++) { Color color = standardColors.get(i); - - themeColorCellGrid[i][0].setColor(color); - themeColorCellGrid[i][2].setColor(color = saturationDown(color, false, true)); - themeColorCellGrid[i][1].setColor(saturationDown(color, false, true)); - - color = standardColors.get(i); - themeColorCellGrid[i][3].setColor(color = saturationDown(color, false, false)); - themeColorCellGrid[i][4].setColor(saturationDown(color, false, false)); + Color[] deriveColorArr = FineColorDeriveState.getDeriveColorArr(color, false, DEFAULT_DERIVE_COUNT); + for (int j = 0; j < deriveColorArr.length; j++) { + themeColorCellGrid[i][j].setColor(deriveColorArr[j]); + } } } @@ -236,21 +231,6 @@ public class NewColorSelectPane extends BasicPane implements ColorSelectable { return isDefaultColor ? new FineColorCell(color, this) : new FineColorCell(color, this, x, y); } - /** - * 调整明度和纯度,默认色只调整明度 - * @param color - * @param isDefaultColor - * @return - */ - public static Color saturationDown(Color color, boolean isDefaultColor, boolean isLight) { - float[] hsb = Color.RGBtoHSB(color.getRed(), color.getGreen(), color.getBlue(), new float[3]); - if (!isDefaultColor) { - hsb[1] = isLight ? Math.max(0, hsb[1] - PURITY_VALUE) : Math.min(1, hsb[1] + PURITY_VALUE); - } - hsb[2] = isLight ? Math.min(1, hsb[2] + BRIGHTNESS_VALUE) : Math.max(0, hsb[2] - BRIGHTNESS_VALUE); - Color color1 = Color.getHSBColor(hsb[0], hsb[1], hsb[2]); - return color1; - } private void initMenuColorPane() { menuColorPane.setLayout(new GridLayout(5, 8, 3, 3)); @@ -274,7 +254,7 @@ public class NewColorSelectPane extends BasicPane implements ColorSelectable { return true; } - protected void initSelectButton(boolean isSupportTransparent){ + protected void initSelectButton(boolean isSupportTransparent) { this.isSupportTransparent = isSupportTransparent; this.setLayout(FRGUIPaneFactory.createBorderLayout()); this.setBorder(new UIRoundedBorder(UIConstants.TOOLBAR_BORDER_COLOR, 1, 5)); @@ -288,6 +268,7 @@ public class NewColorSelectPane extends BasicPane implements ColorSelectable { /** * 添加监听 + * * @param changeListener 监听 */ public void addChangeListener(ChangeListener changeListener) { @@ -340,7 +321,7 @@ public class NewColorSelectPane extends BasicPane implements ColorSelectable { setFineColor(fineColor); } - private void setFineColor(FineColor fineColor){ + private void setFineColor(FineColor fineColor) { this.color = fineColor; // fire color change. @@ -351,7 +332,9 @@ public class NewColorSelectPane extends BasicPane implements ColorSelectable { changeListener.stateChanged(evt); } } - DesignerEnvManager.getEnvManager().getColorConfigManager().addToColorQueue(color); + if (color != null) { + DesignerEnvManager.getEnvManager().getColorConfigManager().addToColorQueue(color.getColor()); + } this.repaint(); } @@ -412,12 +395,12 @@ public class NewColorSelectPane extends BasicPane implements ColorSelectable { private boolean setColorRealTime; - public JPanel getPane(){ + public JPanel getPane() { return this.pane; } - public NewUsedColorPane(int columns, ColorSelectable selectable, boolean setColorRealTime){ + public NewUsedColorPane(int columns, ColorSelectable selectable, boolean setColorRealTime) { this.columns = columns; this.selectable = selectable; this.setColorRealTime = setColorRealTime; @@ -448,7 +431,7 @@ public class NewColorSelectPane extends BasicPane implements ColorSelectable { * 更新最近使用颜色 */ public void updateUsedColor() { - int total = columns ; + int total = columns; Color[] colors = DesignerEnvManager.getEnvManager().getColorConfigManager().getColors(); int size = colors.length; for (int i = 0; i < total; i++) { @@ -464,4 +447,5 @@ public class NewColorSelectPane extends BasicPane implements ColorSelectable { } } + } From 523b763e21e4ddea9b936fb4fe40d568e592e59f Mon Sep 17 00:00:00 2001 From: kerry Date: Thu, 2 Sep 2021 17:50:28 +0800 Subject: [PATCH 10/17] =?UTF-8?q?=E4=BB=A3=E7=A0=81=E4=BF=AE=E6=94=B9?= MIME-Version: 1.0 Content-Type: text/plain; charset=UTF-8 Content-Transfer-Encoding: 8bit --- .../fr/design/style/background/BackgroundJComponent.java | 9 --------- 1 file changed, 9 deletions(-) diff --git a/designer-base/src/main/java/com/fr/design/style/background/BackgroundJComponent.java b/designer-base/src/main/java/com/fr/design/style/background/BackgroundJComponent.java index 377da330c..611953a20 100644 --- a/designer-base/src/main/java/com/fr/design/style/background/BackgroundJComponent.java +++ b/designer-base/src/main/java/com/fr/design/style/background/BackgroundJComponent.java @@ -37,15 +37,6 @@ public class BackgroundJComponent extends JComponent { } - @Override - protected void paintBorder(Graphics g) { -// Color oldColor = g.getColor(); -// Border border = getBorder(); -// if (border != null) { -// border.paintBorder(this, g, 0, 0, getWidth(), getHeight()); -// } - super.paintBorder(g); - } public void setEmptyBackground() { this.background = null; From 37abccaea2409929a679cb0c12289ba2082f6123 Mon Sep 17 00:00:00 2001 From: hades Date: Fri, 3 Sep 2021 11:05:56 +0800 Subject: [PATCH 11/17] =?UTF-8?q?REPORT-58713=20=E5=86=B3=E7=AD=96?= =?UTF-8?q?=E6=8A=A5=E8=A1=A8=E4=B8=AD=E5=85=AC=E5=BC=8F=E6=A8=A1=E6=8B=9F?= =?UTF-8?q?=E8=AE=A1=E7=AE=97=E7=9A=84=E5=8F=82=E6=95=B0=E7=BC=96=E8=BE=91?= =?UTF-8?q?=E7=AA=97=E5=8F=A3=E4=BC=9A=E5=87=BA=E7=8E=B0=E2=80=9C=E9=97=AA?= =?UTF-8?q?=E5=B1=8F=E2=80=9D=E7=8E=B0=E8=B1=A1?= MIME-Version: 1.0 Content-Type: text/plain; charset=UTF-8 Content-Transfer-Encoding: 8bit --- .../main/java/com/fr/design/designer/creator/XCreator.java | 7 ++++++- 1 file changed, 6 insertions(+), 1 deletion(-) diff --git a/designer-form/src/main/java/com/fr/design/designer/creator/XCreator.java b/designer-form/src/main/java/com/fr/design/designer/creator/XCreator.java index 55b9c191f..e0e6e74a4 100644 --- a/designer-form/src/main/java/com/fr/design/designer/creator/XCreator.java +++ b/designer-form/src/main/java/com/fr/design/designer/creator/XCreator.java @@ -802,7 +802,12 @@ public abstract class XCreator extends JPanel implements XComponent, XCreatorToo try { popup.setLocation(designer.getLocationOnScreen().x + designer.getPaintX() + extraX, designer.getLocationOnScreen().y + designer.getPaintY() + extraY); popup.updatePane(designer); - popup.setVisible(selected && accept && popup.hasVisibleButtons() && popup.isCanVisible() && !isShowPluginDialog()); + boolean needShowing = selected && accept && popup.hasVisibleButtons() && popup.isCanVisible() && !isShowPluginDialog(); + if (!popup.isVisible() && needShowing) { + popup.setVisible(true); + } else if (!needShowing) { + popup.setVisible(false); + } popup.setRelativeBounds(bounds); } catch (Exception ignored) { } From d44b2ed3aa33be21ddc483a65917191eef5283cb Mon Sep 17 00:00:00 2001 From: Starryi Date: Thu, 2 Sep 2021 17:20:16 +0800 Subject: [PATCH 12/17] =?UTF-8?q?REPORT-58586=20FR11-=E4=BA=8C=E8=BD=AE?= =?UTF-8?q?=E5=9B=9E=E5=BD=92-=E5=8D=95=E5=85=83=E6=A0=BC=E5=B1=9E?= =?UTF-8?q?=E6=80=A7-=E6=A0=B7=E5=BC=8F-=E5=88=87=E6=8D=A2=E6=88=90?= =?UTF-8?q?=E8=B7=9F=E9=9A=8F=E4=B8=BB=E9=A2=98=E5=90=8E=EF=BC=8C=E9=BC=A0?= =?UTF-8?q?=E6=A0=87=E6=97=A0=E6=B3=95=E4=B8=8A=E6=BB=91=E8=87=B3=E9=A1=B6?= =?UTF-8?q?=E9=83=A8?= MIME-Version: 1.0 Content-Type: text/plain; charset=UTF-8 Content-Transfer-Encoding: 8bit 【问题原因】 内层多加了一个ScrollPane就会有这个BUG,和外层的ScrollPane冲突了。 先和之前的预定义样式列表的实现保持一致吧,只有最外层的能滚动, 看看后面能不能优化下 【改动思路】 同上 --- .../fr/design/mainframe/cell/settingpane/style/StylePane.java | 4 +--- 1 file changed, 1 insertion(+), 3 deletions(-) diff --git a/designer-realize/src/main/java/com/fr/design/mainframe/cell/settingpane/style/StylePane.java b/designer-realize/src/main/java/com/fr/design/mainframe/cell/settingpane/style/StylePane.java index 93bf52397..e559cfaa4 100644 --- a/designer-realize/src/main/java/com/fr/design/mainframe/cell/settingpane/style/StylePane.java +++ b/designer-realize/src/main/java/com/fr/design/mainframe/cell/settingpane/style/StylePane.java @@ -7,7 +7,6 @@ import com.fr.design.dialog.BasicPane; import com.fr.design.event.UIObserver; import com.fr.design.event.UIObserverListener; import com.fr.design.gui.ibutton.UIButtonGroup; -import com.fr.design.gui.icontainer.UIScrollPane; import com.fr.design.gui.ilable.UILabel; import com.fr.design.i18n.Toolkit; import com.fr.design.layout.TableLayout; @@ -132,8 +131,7 @@ public class StylePane extends BasicPane implements UIObserver { uiLabel.setPreferredSize(new Dimension(uiLabel.getPreferredSize().width, 20)); container.add(uiLabel, BorderLayout.NORTH); themedCellStyleListPane.setBorder(BorderFactory.createEmptyBorder()); - UIScrollPane scrollPane = new UIScrollPane(themedCellStyleListPane); - container.add(scrollPane, BorderLayout.CENTER); + container.add(themedCellStyleListPane, BorderLayout.CENTER); return container; } From a242b1cd59484a6721ee9197bf35ca759109fa75 Mon Sep 17 00:00:00 2001 From: Starryi Date: Thu, 2 Sep 2021 18:22:59 +0800 Subject: [PATCH 13/17] =?UTF-8?q?REPORT-58389=20=E3=80=90FR11=E4=BA=8C?= =?UTF-8?q?=E8=BD=AE=E5=9B=9E=E5=BD=92=E3=80=91=E8=AE=BE=E8=AE=A1=E5=99=A8?= =?UTF-8?q?-frm=E6=A8=A1=E6=9D=BF=E6=92=A4=E9=94=80/=E5=88=87=E6=8D=A2?= =?UTF-8?q?=E4=B8=BB=E9=A2=98=EF=BC=8C=E8=AE=BE=E8=AE=A1=E7=94=BB=E5=B8=83?= =?UTF-8?q?=E9=83=BD=E4=BC=9A=E5=8F=98=E5=B0=8F?= MIME-Version: 1.0 Content-Type: text/plain; charset=UTF-8 Content-Transfer-Encoding: 8bit 【问题原因】 1. 主题功能仅负责撤销回退的数据模型修改,不进行界 面刷新,界面刷新依然由原来的撤销回退逻辑完成,优化 撤销回退的效率 2. 设计器修刷新界面后,需要恢复下画布尺寸和滚动条位置 【改动思路】 同上 --- .../java/com/fr/design/mainframe/JTemplate.java | 2 -- .../main/java/com/fr/design/mainframe/JForm.java | 15 +++++++++++++-- .../java/com/fr/design/mainframe/JWorkBook.java | 4 +++- 3 files changed, 16 insertions(+), 5 deletions(-) diff --git a/designer-base/src/main/java/com/fr/design/mainframe/JTemplate.java b/designer-base/src/main/java/com/fr/design/mainframe/JTemplate.java index 4e0a8090e..8bb23786f 100644 --- a/designer-base/src/main/java/com/fr/design/mainframe/JTemplate.java +++ b/designer-base/src/main/java/com/fr/design/mainframe/JTemplate.java @@ -625,8 +625,6 @@ public abstract class JTemplate> */ public void redo() { this.getUndoManager().redo(); - // 重做前模版使用主题可能已经被删除或修改,需要重置模版样式 - checkAndResetTheme(); fireSuperTargetModified(); } 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 04dd92243..9d03edbc0 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 @@ -664,9 +664,11 @@ public class JForm extends JTemplate implements BaseJForm implements BaseJForm implements BaseJForm { @Override protected void applyUndoState(WorkBookUndoState u) { try { - this.setTarget((WorkBook) u.getWorkBook().clone()); + WorkBook undoWorkBook = (WorkBook) u.getWorkBook().clone(); + undoWorkBook.checkAndResetTheme(); + this.setTarget(undoWorkBook); if (!DesignerMode.isAuthorityEditing()) { if (u.getAuthorityType() != BaseUndoState.NORMAL_STATE) { applyAll(u); From 0c6391f2d9831e22abe03a4950c6c807bbe888b8 Mon Sep 17 00:00:00 2001 From: Starryi Date: Thu, 2 Sep 2021 18:58:38 +0800 Subject: [PATCH 14/17] =?UTF-8?q?REPORT-58800=20=E3=80=90=E4=B8=BB?= =?UTF-8?q?=E9=A2=98=E5=88=87=E6=8D=A2=E3=80=91=E4=BC=98=E5=8C=96=E4=B8=BB?= =?UTF-8?q?=E9=A2=98=E9=80=89=E6=8B=A9=E7=95=8C=E9=9D=A2=20=E5=BA=94?= =?UTF-8?q?=E7=94=A8=E4=B8=BB=E9=A2=98=E7=9A=84=E4=BA=A4=E4=BA=92?= MIME-Version: 1.0 Content-Type: text/plain; charset=UTF-8 Content-Transfer-Encoding: 8bit 【问题原因】 交互变更: 直接点击主题列表中的主题块就可以切换当前模版使用的主题 【改动思路】 同上 --- .../theme/TemplateThemeListPane.java | 20 +++--- .../dialog/TemplateThemeUsingDialog.java | 65 ++----------------- 2 files changed, 18 insertions(+), 67 deletions(-) diff --git a/designer-base/src/main/java/com/fr/design/mainframe/theme/TemplateThemeListPane.java b/designer-base/src/main/java/com/fr/design/mainframe/theme/TemplateThemeListPane.java index 524c272ac..493033512 100644 --- a/designer-base/src/main/java/com/fr/design/mainframe/theme/TemplateThemeListPane.java +++ b/designer-base/src/main/java/com/fr/design/mainframe/theme/TemplateThemeListPane.java @@ -126,15 +126,17 @@ public class TemplateThemeListPane extends BasicPane { } private void setSelectedBlock(TemplateThemeBlock block) { - if (selectedBlock != null) { - selectedBlock.setSelected(false); - } - selectedBlock = block; - if (selectedBlock != null) { - selectedBlock.setSelected(true); - } - if (changeListener != null) { - changeListener.fireChanged(new ChangeEvent(this)); + if (selectedBlock != block) { + if (selectedBlock != null) { + selectedBlock.setSelected(false); + } + selectedBlock = block; + if (selectedBlock != null) { + selectedBlock.setSelected(true); + } + if (changeListener != null) { + changeListener.fireChanged(new ChangeEvent(this)); + } } } diff --git a/designer-base/src/main/java/com/fr/design/mainframe/theme/dialog/TemplateThemeUsingDialog.java b/designer-base/src/main/java/com/fr/design/mainframe/theme/dialog/TemplateThemeUsingDialog.java index 1d17bb4eb..e4f4b5fd2 100644 --- a/designer-base/src/main/java/com/fr/design/mainframe/theme/dialog/TemplateThemeUsingDialog.java +++ b/designer-base/src/main/java/com/fr/design/mainframe/theme/dialog/TemplateThemeUsingDialog.java @@ -1,9 +1,8 @@ package com.fr.design.mainframe.theme.dialog; -import com.fr.base.theme.ThemedTemplate; import com.fr.base.theme.TemplateTheme; import com.fr.base.theme.TemplateThemeConfig; -import com.fr.design.base.mode.DesignModeContext; +import com.fr.base.theme.ThemedTemplate; import com.fr.design.event.ChangeEvent; import com.fr.design.event.ChangeListener; import com.fr.design.gui.ibutton.UIButton; @@ -11,7 +10,6 @@ import com.fr.design.i18n.Toolkit; import com.fr.design.layout.FRGUIPaneFactory; import com.fr.design.mainframe.theme.TemplateThemeListPane; import com.fr.design.mainframe.theme.ui.BorderUtils; -import com.fr.stable.StringUtils; import com.fr.workspace.WorkContext; import javax.swing.BorderFactory; @@ -43,56 +41,27 @@ TemplateThemeUsingDialog extends TemplateThemeDialog { JPanel content = createContent(); UIButton openThemeManagerButton = createOpenThemeManagerButton(); - UIButton usingCurrentThemeButton = createUsingCurrentThemeButton(); UIButton completeButton = createCompleteButton(); setContentPane(createDialogContentPane(content, new UIButton[]{ openThemeManagerButton }, - new UIButton[]{ usingCurrentThemeButton, completeButton } + new UIButton[]{ completeButton } )); themeListPane.startListenThemeConfig(); - resetEnableCurrentThemeButton(themeListPane.getSelectedTheme(), usingCurrentThemeButton); themeListPane.setSelectedChangeListener(new ChangeListener() { @Override public void fireChanged(ChangeEvent event) { - resetEnableCurrentThemeButton(themeListPane.getSelectedTheme(), usingCurrentThemeButton); + TemplateTheme theme = themeListPane.getSelectedTheme(); + if (theme != null) { + currentTemplate.setTemplateTheme(theme); + themeListPane.repaint(); + } } }); } - private void resetEnableCurrentThemeButton(T selectedTheme, UIButton usingCurrentThemeButton) { - if (selectedTheme == null) { - usingCurrentThemeButton.setEnabled(false); - return; - } - String selectedThemeName = selectedTheme.getName(); - if (StringUtils.isEmpty(selectedThemeName)) { - usingCurrentThemeButton.setEnabled(false); - return; - } - - if (currentTemplate == null) { - usingCurrentThemeButton.setEnabled(false); - return; - } - - TemplateTheme templateUsingTheme = currentTemplate.getTemplateTheme(); - if (templateUsingTheme == null) { - usingCurrentThemeButton.setEnabled(true); - return; - } - - String templateUsingThemeName = templateUsingTheme.getName(); - if (StringUtils.isEmpty(templateUsingThemeName)) { - usingCurrentThemeButton.setEnabled(true); - return; - } - - usingCurrentThemeButton.setEnabled(!StringUtils.equals(templateUsingThemeName, selectedTheme.getName())); - } - private JPanel createContent() { JPanel container = FRGUIPaneFactory.createBorderLayout_S_Pane(); container.setBorder(BorderFactory.createEmptyBorder(10, 10, 0, 10)); @@ -123,17 +92,6 @@ TemplateThemeUsingDialog extends TemplateThemeDialog { return null; } - private UIButton createUsingCurrentThemeButton() { - UIButton button = new UIButton(Toolkit.i18nText("Fine-Design_Basic_Template_Theme_Using_Dialog_Use")); - button.addActionListener(new ActionListener() { - @Override - public void actionPerformed(ActionEvent e) { - apply2CurrentTemplate(button); - } - }); - return button; - } - private UIButton createCompleteButton() { UIButton button = new UIButton(Toolkit.i18nText("Fine-Design_Basic_Template_Theme_Using_Dialog_Complete")); button.addActionListener(new ActionListener() { @@ -150,13 +108,4 @@ TemplateThemeUsingDialog extends TemplateThemeDialog { themeListPane.stopAsyncFetchTheme(); super.exit(); } - - private void apply2CurrentTemplate(UIButton usingCurrentThemeButton) { - TemplateTheme theme = themeListPane.getSelectedTheme(); - if (theme != null) { - currentTemplate.setTemplateTheme(theme); - themeListPane.repaint(); - usingCurrentThemeButton.setEnabled(false); - } - } } \ No newline at end of file From e2534d993323efe587a1bba7f64483ff820c0ec5 Mon Sep 17 00:00:00 2001 From: Starryi Date: Fri, 3 Sep 2021 11:41:25 +0800 Subject: [PATCH 15/17] =?UTF-8?q?REPORT-58503=20=E3=80=90=E4=B8=BB?= =?UTF-8?q?=E9=A2=98=E5=88=87=E6=8D=A2=E3=80=91=E9=A2=84=E8=A7=88=E5=8C=BA?= =?UTF-8?q?ui=E6=94=B9=E7=89=88?= MIME-Version: 1.0 Content-Type: text/plain; charset=UTF-8 Content-Transfer-Encoding: 8bit 【问题原因】 单元格样式预览显示透明块 【改动思路】 同上 --- .../fr/design/cell/CellStylePreviewPane.java | 82 ++++++++++++++++++ .../theme/edit/cell/CellStyleEditPane.java | 53 ++--------- .../design/images/transparent_background.png | Bin 0 -> 24823 bytes .../style/ThemedCellStyleListPane.java | 46 +--------- .../com/fr/design/report/ReportStylePane.java | 42 +-------- 5 files changed, 94 insertions(+), 129 deletions(-) create mode 100644 designer-base/src/main/java/com/fr/design/cell/CellStylePreviewPane.java create mode 100644 designer-base/src/main/resources/com/fr/design/images/transparent_background.png diff --git a/designer-base/src/main/java/com/fr/design/cell/CellStylePreviewPane.java b/designer-base/src/main/java/com/fr/design/cell/CellStylePreviewPane.java new file mode 100644 index 000000000..d566bbf98 --- /dev/null +++ b/designer-base/src/main/java/com/fr/design/cell/CellStylePreviewPane.java @@ -0,0 +1,82 @@ +package com.fr.design.cell; + +import com.fr.base.NameStyle; +import com.fr.base.ScreenResolution; +import com.fr.base.Style; +import com.fr.design.mainframe.theme.TemplateThemeBlock; +import com.fr.general.IOUtils; + +import javax.swing.Icon; +import javax.swing.JComponent; +import javax.swing.JPanel; +import java.awt.Dimension; +import java.awt.Graphics; +import java.awt.Graphics2D; +import java.awt.Image; +import java.awt.Toolkit; + +/** + * @author Starryi + * @version 1.0 + * Created by Starryi on 2021/9/3 + */ +public class CellStylePreviewPane extends JPanel { + + private static final Image transparentBackgroundImage = Toolkit.getDefaultToolkit().createImage(CellStylePreviewPane.class.getResource("/com/fr/design/images/transparent_background.png")); + private final float transparentBackgroundWidth; + private final float transparentBackgroundHeight; + private final float transparentBackgroundAspect; + private String paintText = "Report"; + private Style style = Style.DEFAULT_STYLE; + + public CellStylePreviewPane() { + transparentBackgroundWidth = transparentBackgroundImage.getWidth(null); + transparentBackgroundHeight = transparentBackgroundImage.getHeight(null); + transparentBackgroundAspect = 1.0F * transparentBackgroundImage.getWidth(null) / transparentBackgroundImage.getHeight(null); + } + + public void setStyle(Style style) { + this.style = style; + if (style instanceof NameStyle) { + paintText = ((NameStyle) style).getName(); + } + repaint(); + } + + @Override + public void paintComponent(Graphics g) { + Graphics2D g2d = (Graphics2D) g; + int resolution = ScreenResolution.getScreenResolution(); + + int width = getWidth(); + int height = getHeight(); + + float scaleWidth = 1.0F * getWidth() / transparentBackgroundWidth; + float scaleHeight = 1.0F * getHeight() / transparentBackgroundHeight; + float maxScale = Math.max(scaleWidth, scaleHeight); + + if (maxScale <= 1) { + scaleWidth = scaleHeight = 1; + } else { + scaleHeight = scaleWidth = maxScale; + } + g2d.drawImage(transparentBackgroundImage, 0, 0, (int) (transparentBackgroundWidth * scaleWidth), (int) (transparentBackgroundHeight * scaleHeight), null); + + if (style == Style.DEFAULT_STYLE) { + // 如果是默认的style,就只写"Report"上去 + Style.paintContent(g2d, paintText, style, width, height, resolution); + return; + } + + Style.paintBackground(g2d, style, width, height); + + Style.paintContent(g2d, paintText, style, width, height, resolution); + + Style.paintBorder(g2d, style, getWidth() - 3, getHeight() - 3); + } + + @Override + public Dimension getMinimumSize() { + return getPreferredSize(); + } +} diff --git a/designer-base/src/main/java/com/fr/design/mainframe/theme/edit/cell/CellStyleEditPane.java b/designer-base/src/main/java/com/fr/design/mainframe/theme/edit/cell/CellStyleEditPane.java index a2991a89f..53e4d9a91 100644 --- a/designer-base/src/main/java/com/fr/design/mainframe/theme/edit/cell/CellStyleEditPane.java +++ b/designer-base/src/main/java/com/fr/design/mainframe/theme/edit/cell/CellStyleEditPane.java @@ -1,8 +1,7 @@ package com.fr.design.mainframe.theme.edit.cell; -import com.fr.base.ScreenResolution; -import com.fr.base.Style; import com.fr.base.theme.settings.ThemedCellStyle; +import com.fr.design.cell.CellStylePreviewPane; import com.fr.design.constants.UIConstants; import com.fr.design.dialog.AttrScrollPane; import com.fr.design.dialog.BasicPane; @@ -18,12 +17,9 @@ import com.fr.design.layout.FRGUIPaneFactory; import com.fr.design.mainframe.theme.ui.BorderUtils; import javax.swing.BorderFactory; -import javax.swing.JComponent; import javax.swing.JPanel; import java.awt.BorderLayout; import java.awt.Dimension; -import java.awt.Graphics; -import java.awt.Graphics2D; import java.awt.GridLayout; import java.util.ArrayList; import java.util.List; @@ -39,7 +35,7 @@ import static com.fr.design.i18n.Toolkit.i18nText; */ public class CellStyleEditPane extends MultiTabPane { private ThemedCellStyle cellStyle; - private PreviewArea previewArea; + private CellStylePreviewPane previewArea; private boolean populating; private AttributeChangeListener attributeChangeListener; @@ -78,7 +74,7 @@ public class CellStyleEditPane extends MultiTabPane { for (BasicPane basicPane : paneList) { ((AbstractBasicStylePane) basicPane).populateBean(ob.getStyle()); - previewArea.preview(ob.getStyle()); + previewArea.setStyle(ob.getStyle()); } this.populating = false; } @@ -112,7 +108,8 @@ public class CellStyleEditPane extends MultiTabPane { jPanel.setLayout(new BorderLayout(0, 4)); JPanel previewPane = FRGUIPaneFactory.createBorderLayout_S_Pane(); - previewArea = new PreviewArea(); + previewArea = new CellStylePreviewPane(); + previewArea.setPreferredSize(new Dimension(223, 30)); previewPane.setBorder(BorderUtils.createTitleBorder(i18nText("Fine-Design_Basic_Preview"))); previewPane.add(previewArea, BorderLayout.CENTER); @@ -138,7 +135,7 @@ public class CellStyleEditPane extends MultiTabPane { } ThemedCellStyle cellStyle = updateBean(); if (cellStyle != null) { - previewArea.preview(cellStyle.getStyle()); + previewArea.setStyle(cellStyle.getStyle()); } fireAttrChangeListener(); } @@ -157,42 +154,4 @@ public class CellStyleEditPane extends MultiTabPane { @Override public void updateBean(ThemedCellStyle ob) {} - - private static class PreviewArea extends JComponent { - - private static final String paintText = "Report"; - private Style style = Style.DEFAULT_STYLE; - - public PreviewArea() { - setPreferredSize(new Dimension(223, 30)); - } - - public void preview(Style style) { - this.style = style; - repaint(); - } - - @Override - public void paintComponent(Graphics g) { - Graphics2D g2d = (Graphics2D) g; - int resolution = ScreenResolution.getScreenResolution(); - - if (style == Style.DEFAULT_STYLE) { - // 如果是默认的style,就只写"Report"上去 - Style.paintContent(g2d, paintText, style, getWidth() - 3, getHeight() - 3, resolution); - return; - } - - Style.paintBackground(g2d, style, getWidth() - 3, getHeight() - 3); - - Style.paintContent(g2d, paintText, style, getWidth() - 3, getHeight() - 3, resolution); - - Style.paintBorder(g2d, style, getWidth() - 3, getHeight() - 3); - } - - @Override - public Dimension getMinimumSize() { - return getPreferredSize(); - } - } } diff --git a/designer-base/src/main/resources/com/fr/design/images/transparent_background.png b/designer-base/src/main/resources/com/fr/design/images/transparent_background.png new file mode 100644 index 0000000000000000000000000000000000000000..cfb233f46e5e5e3c5349a7639004806f54c1eee2 GIT binary patch literal 24823 zcmV)zK#{+RP)Px#L}ge>W=%~1DgXcg2mk?xX#fNO00031000^Q000001E2u_0{{R30RRC20H6W@ z1ONa40RR93KA-~t1ONa40RR91AOHXW0RJawn*abn07*naRCod1z1y>0$Fk-%m$YPC z7t6LRUnSdf`Fj2-qW=|MAbm0oSy?s4-1}Gm*Z+O|5C8BFo4viw z=B>B3n=@z5Y)Bt{_~B;n)Tzz0&px|(<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eIEqWr%82q>kN@ zo$e)e99TtG$#VvoC%+B0wBufGm07xivD?O_VRyVKyOfx*J85_1K_>ZAJ|cQuOQ&j! zU}vWwe50;a-bw7R*)A`bSZ?(Sm0g3M`5JccEU?p9u-l$gOZBZ9Y{9bLJ<{b-FXWY; z0~>uu9)C%mpv(utlIgZx+7rCwS!2hL(Cb=d6?P>_<@WLO&&1C15Fr_lRan)h`em&o|OtoV&S3t!|>N1=ys=k4;)%Vp}Sn;rv&<5~Hgs#R; z@~~qKc?^bMrfBuMV(#rc?`hrmUSJ%#4BN$xBXj#%P}Bjb{i0&&c4qc zE1l346G>$lgaCG=CuT_Y!gYlY9x9DDt~Qtwd5~oQ2P65QCq=$Heu%nqO1pkMuy_Fn zITPQImrBesRS{)L9ioo)Q@P=D6H8~F;6i85BV1JmJmKSg%9Ig#sEAAkI~pm*LBsHv z=SjW-KYZjTa`Wg>4Q%}Mq#VQ=z{mp zUAy3(vFdb9r;xV^nU86EA*7>eBo1-rT{ zqWI9cM;;2hSsrrCCwn@*Ujrv3^2Lr*?z%6AZ|d6+l*mW^N|hTso-i2#3%mKu3;et7 zZpOseS@bTugKzGO6a)VnyNq{!xu~L3;=aAnzvO>5_P9c_wB)0 z7|*ic-Gv=>Odm6L>hL(6y)9h2F imp private static class RadioButtonListCellRenderer extends JPanel implements ListCellRenderer, Serializable { private final UIRadioButton button; - private final PreviewArea previewArea; + private final CellStylePreviewPane previewArea; public RadioButtonListCellRenderer() { super(); @@ -150,7 +147,7 @@ public class ThemedCellStyleListPane extends FurtherBasicBeanPane imp setBorder(BorderFactory.createEmptyBorder(5, 5, 5, 5)); setPreferredSize(new Dimension(getPreferredSize().width, 40)); button = new UIRadioButton(); - previewArea = new PreviewArea(); + previewArea = new CellStylePreviewPane(); add(button, BorderLayout.WEST); add(previewArea, BorderLayout.CENTER); } @@ -162,41 +159,4 @@ public class ThemedCellStyleListPane extends FurtherBasicBeanPane imp return this; } } - - private static class PreviewArea extends JComponent { - - private String paintText = "Report"; - private Style style = Style.DEFAULT_STYLE; - - public void setStyle(Style style) { - this.style = style; - if (style instanceof NameStyle) { - paintText = ((NameStyle) style).getName(); - } - repaint(); - } - - @Override - public void paintComponent(Graphics g) { - Graphics2D g2d = (Graphics2D) g; - int resolution = ScreenResolution.getScreenResolution(); - - if (style == Style.DEFAULT_STYLE) { - // 如果是默认的style,就只写"Report"上去 - Style.paintContent(g2d, paintText, style, getWidth() - 3, getHeight() - 3, resolution); - return; - } - - Style.paintBackground(g2d, style, getWidth() - 3, getHeight() - 3); - - Style.paintContent(g2d, paintText, style, getWidth() - 3, getHeight() - 3, resolution); - - Style.paintBorder(g2d, style, getWidth() - 3, getHeight() - 3); - } - - @Override - public Dimension getMinimumSize() { - return getPreferredSize(); - } - } } \ No newline at end of file diff --git a/designer-realize/src/main/java/com/fr/design/report/ReportStylePane.java b/designer-realize/src/main/java/com/fr/design/report/ReportStylePane.java index 91b3641ff..94b18f969 100644 --- a/designer-realize/src/main/java/com/fr/design/report/ReportStylePane.java +++ b/designer-realize/src/main/java/com/fr/design/report/ReportStylePane.java @@ -1,9 +1,9 @@ package com.fr.design.report; import com.fr.base.NameStyle; -import com.fr.base.ScreenResolution; import com.fr.base.Style; import com.fr.design.border.UIRoundedBorder; +import com.fr.design.cell.CellStylePreviewPane; import com.fr.design.constants.UIConstants; import com.fr.design.designer.IntervalConstants; import com.fr.design.dialog.BasicPane; @@ -52,8 +52,6 @@ import java.awt.CardLayout; import java.awt.Color; import java.awt.Component; import java.awt.Dimension; -import java.awt.Graphics; -import java.awt.Graphics2D; import java.awt.event.ActionEvent; import java.awt.event.ActionListener; import java.util.ArrayList; @@ -66,7 +64,7 @@ public class ReportStylePane extends BasicPane { }; public static final int DEFAULT_SELECTED_INDEX = 0; - private final PreviewArea previewArea; + private final CellStylePreviewPane previewArea; private final UIButtonGroup followingThemeButtonGroup; private final CustomFloatStyleSettingPane customStylePane; private final ThemedCellStyleListPane themedCellStyleListPane; @@ -78,7 +76,7 @@ public class ReportStylePane extends BasicPane { setLayout(FRGUIPaneFactory.createBorderLayout()); setBorder(BorderFactory.createEmptyBorder(10, 10, 0, 10)); - previewArea = new PreviewArea(); + previewArea = new CellStylePreviewPane(); followingThemeButtonGroup = new UIButtonGroup<>(FOLLOWING_THEME_STRING_ARRAYS); customStylePane = new CustomFloatStyleSettingPane(); themedCellStyleListPane = new ThemedCellStyleListPane(); @@ -333,40 +331,6 @@ public class ReportStylePane extends BasicPane { previewArea.setStyle(updateBean()); } - private static class PreviewArea extends JComponent { - - private static final String paintText = "Report"; - private Style style = Style.DEFAULT_STYLE; - - public void setStyle(Style style) { - this.style = style; - repaint(); - } - - @Override - public void paintComponent(Graphics g) { - Graphics2D g2d = (Graphics2D) g; - int resolution = ScreenResolution.getScreenResolution(); - - if (style == Style.DEFAULT_STYLE) { - // 如果是默认的style,就只写"Report"上去 - Style.paintContent(g2d, paintText, style, getWidth() - 3, getHeight() - 3, resolution); - return; - } - - Style.paintBackground(g2d, style, getWidth() - 3, getHeight() - 3); - - Style.paintContent(g2d, paintText, style, getWidth() - 3, getHeight() - 3, resolution); - - Style.paintBorder(g2d, style, getWidth() - 3, getHeight() - 3); - } - - @Override - public Dimension getMinimumSize() { - return getPreferredSize(); - } - } - private static class CustomFloatStyleSettingPane extends BasicPane implements ChangeListener { private static final int ALIGNMENT_INDEX = 1; private static final int FONT_INDEX = 2; From 98768ff1088b7541169523f4086883456259cb73 Mon Sep 17 00:00:00 2001 From: hades Date: Fri, 3 Sep 2021 11:44:46 +0800 Subject: [PATCH 16/17] =?UTF-8?q?REPORT-58713=20=20=E5=8A=A0=E4=BA=9B?= =?UTF-8?q?=E6=B3=A8=E9=87=8A?= MIME-Version: 1.0 Content-Type: text/plain; charset=UTF-8 Content-Transfer-Encoding: 8bit --- .../src/main/java/com/fr/design/designer/creator/XCreator.java | 2 ++ 1 file changed, 2 insertions(+) diff --git a/designer-form/src/main/java/com/fr/design/designer/creator/XCreator.java b/designer-form/src/main/java/com/fr/design/designer/creator/XCreator.java index e0e6e74a4..e82528558 100644 --- a/designer-form/src/main/java/com/fr/design/designer/creator/XCreator.java +++ b/designer-form/src/main/java/com/fr/design/designer/creator/XCreator.java @@ -803,6 +803,8 @@ public abstract class XCreator extends JPanel implements XComponent, XCreatorToo popup.setLocation(designer.getLocationOnScreen().x + designer.getPaintX() + extraX, designer.getLocationOnScreen().y + designer.getPaintY() + extraY); popup.updatePane(designer); boolean needShowing = selected && accept && popup.hasVisibleButtons() && popup.isCanVisible() && !isShowPluginDialog(); + // 当不可见时,且可以设置为可见状态,才去设置为可见 + // 避免已经是可见状态时,重复设置可见,造成闪屏 if (!popup.isVisible() && needShowing) { popup.setVisible(true); } else if (!needShowing) { From 95c13ae6a5dba90d8e7d81107194fc7c8f95f7e0 Mon Sep 17 00:00:00 2001 From: =?UTF-8?q?=E7=99=BD=E5=B2=B3?= <445798420@qq.com> Date: Fri, 3 Sep 2021 14:28:13 +0800 Subject: [PATCH 17/17] =?UTF-8?q?CHART-20565=20=E5=9B=BE=E8=A1=A8=E6=B8=90?= =?UTF-8?q?=E5=8F=98=E8=89=B2=E6=9B=B4=E6=96=B0?= MIME-Version: 1.0 Content-Type: text/plain; charset=UTF-8 Content-Transfer-Encoding: 8bit --- .../design/mainframe/theme/TemplateThemeProfilePane.java | 9 ++++----- 1 file changed, 4 insertions(+), 5 deletions(-) diff --git a/designer-base/src/main/java/com/fr/design/mainframe/theme/TemplateThemeProfilePane.java b/designer-base/src/main/java/com/fr/design/mainframe/theme/TemplateThemeProfilePane.java index b7a8db48a..fa6d087db 100644 --- a/designer-base/src/main/java/com/fr/design/mainframe/theme/TemplateThemeProfilePane.java +++ b/designer-base/src/main/java/com/fr/design/mainframe/theme/TemplateThemeProfilePane.java @@ -5,7 +5,6 @@ import com.fr.base.theme.TemplateTheme; import com.fr.base.theme.TemplateThemeConfig; import com.fr.base.theme.settings.ThemeThumbnail; import com.fr.base.theme.settings.ThemedCellStyleList; -import com.fr.base.theme.settings.ThemedChartStyle; import com.fr.base.theme.settings.ThemedColorScheme; import com.fr.design.designer.IntervalConstants; import com.fr.design.dialog.FineJOptionPane; @@ -27,12 +26,9 @@ import com.fr.design.mainframe.theme.edit.ui.ColorListPane; import com.fr.design.mainframe.theme.edit.ui.LabelUtils; import com.fr.design.mainframe.theme.ui.BorderUtils; import com.fr.design.utils.gui.GUICoreUtils; -import com.fr.general.Inter; import com.fr.log.FineLoggerFactory; import com.fr.stable.StringUtils; import com.fr.transaction.CallBackAdaptor; -import com.fr.transaction.Configurations; -import com.fr.transaction.WorkerFacade; import javax.swing.BorderFactory; import javax.swing.JComponent; @@ -44,6 +40,7 @@ import javax.swing.event.ChangeEvent; import javax.swing.event.ChangeListener; import javax.swing.event.DocumentEvent; import javax.swing.event.DocumentListener; +import java.util.List; import java.awt.BorderLayout; import java.awt.Color; import java.awt.Component; @@ -55,7 +52,6 @@ import java.awt.event.FocusAdapter; import java.awt.event.FocusEvent; import java.awt.event.WindowAdapter; import java.awt.event.WindowEvent; -import java.util.List; import static com.fr.design.i18n.Toolkit.i18nText; @@ -321,6 +317,9 @@ public abstract class TemplateThemeProfilePane extends FineColorManager.traverse(theme, replaceByColorScheme); populateBean(theme); + + //图表渐变色 + chartStyleSettingPane.populateGradientBar(colors); } public void populateBean(T theme) {