Browse Source

Pull request #8546: REPORT-68357 fix bugs

Merge in DESIGN/design from ~ZHENG/c-design:release/11.0 to release/11.0

* commit 'd047af9ba9d4a02af8c384b6e094244b297fcd0a':
  REPORT-68638 design fix:没有配色的时候渲染和配置界面配色不一致,统一成配置界面的
  REPORT-68357 fix:namestyle导致fvs.cpt中单元格样式中有主题相关配置
bugfix/11.0
zheng 3 years ago
parent
commit
e672f45685
  1. 3
      designer-base/src/main/java/com/fr/design/mainframe/theme/utils/DefaultThemedTemplateCellElementCase.java
  2. 18
      designer-base/src/main/java/com/fr/design/style/color/ColorAdjustPane.java

3
designer-base/src/main/java/com/fr/design/mainframe/theme/utils/DefaultThemedTemplateCellElementCase.java

@ -3,6 +3,7 @@ package com.fr.design.mainframe.theme.utils;
import com.fr.base.NameStyle; import com.fr.base.NameStyle;
import com.fr.base.theme.TemplateTheme; import com.fr.base.theme.TemplateTheme;
import com.fr.base.theme.settings.ThemedCellStyle; import com.fr.base.theme.settings.ThemedCellStyle;
import com.fr.design.base.mode.DesignModeContext;
import com.fr.design.file.HistoryTemplateListCache; import com.fr.design.file.HistoryTemplateListCache;
import com.fr.design.mainframe.JTemplate; import com.fr.design.mainframe.JTemplate;
import com.fr.report.cell.DefaultTemplateCellElement; import com.fr.report.cell.DefaultTemplateCellElement;
@ -37,7 +38,7 @@ public class DefaultThemedTemplateCellElementCase {
ThemedCellStyle themedCellStyle = theme.getCellStyleList().getUse4Default(); ThemedCellStyle themedCellStyle = theme.getCellStyleList().getUse4Default();
if (themedCellStyle != null) { if (themedCellStyle != null) {
NameStyle nameStyle = NameStyle.getPassiveInstance(themedCellStyle.getName(), themedCellStyle.getStyle()); NameStyle nameStyle = NameStyle.getPassiveInstance(themedCellStyle.getName(), themedCellStyle.getStyle());
cellElement.setStyle(nameStyle); cellElement.setStyle(DesignModeContext.isDuchampMode() ? nameStyle.getRealStyle() : nameStyle);
} }
} }
return cellElement; return cellElement;

18
designer-base/src/main/java/com/fr/design/style/color/ColorAdjustPane.java

@ -1,6 +1,7 @@
package com.fr.design.style.color; package com.fr.design.style.color;
import com.fr.base.BaseUtils; import com.fr.base.BaseUtils;
import com.fr.chart.base.ChartConstants;
import com.fr.design.DesignerEnvManager; import com.fr.design.DesignerEnvManager;
import com.fr.design.event.UIObserver; import com.fr.design.event.UIObserver;
import com.fr.design.event.UIObserverListener; import com.fr.design.event.UIObserverListener;
@ -12,8 +13,6 @@ import javax.swing.JComponent;
import javax.swing.JPanel; import javax.swing.JPanel;
import javax.swing.event.ChangeEvent; import javax.swing.event.ChangeEvent;
import javax.swing.event.ChangeListener; import javax.swing.event.ChangeListener;
import java.util.ArrayList;
import java.util.List;
import java.awt.Color; import java.awt.Color;
import java.awt.Dimension; import java.awt.Dimension;
import java.awt.Graphics; import java.awt.Graphics;
@ -23,6 +22,8 @@ import java.awt.event.MouseEvent;
import java.awt.event.MouseListener; import java.awt.event.MouseListener;
import java.awt.geom.Rectangle2D; import java.awt.geom.Rectangle2D;
import java.awt.image.BufferedImage; import java.awt.image.BufferedImage;
import java.util.ArrayList;
import java.util.List;
/** /**
* 配色方案选择组合色之后可以调整颜色的组件 * 配色方案选择组合色之后可以调整颜色的组件
@ -33,18 +34,7 @@ import java.awt.image.BufferedImage;
*/ */
public class ColorAdjustPane extends JPanel implements UIObserver { public class ColorAdjustPane extends JPanel implements UIObserver {
public static final Color[] DEFAULT_COLORS = { public static final Color[] DEFAULT_COLORS = ChartConstants.NEW_FEATURES;
new Color(99, 178, 238),
new Color(118, 218, 145),
new Color(248, 203, 127),
new Color(248, 149, 136),
new Color(124, 214, 207),
new Color(145, 146, 171),
new Color(120, 152, 225),
new Color(239, 166, 102),
new Color(237, 221, 134),
new Color(153, 135, 206),
};
private static final int COUNT_OF_ROW = 8; private static final int COUNT_OF_ROW = 8;

Loading…
Cancel
Save