Browse Source

Merge pull request #2504 in DESIGN/design from release/10.0 to bugfix/10.0

* commit '8d9edb6c3b25b9c053df837219295fa2c3f34cb4':
  CHART-16000 富文本编辑器弹窗模态设置
  CHART-15955 富文本界面设置为可拖拽
  CHART-16060 漏斗图富文本参数解析
  调整标签界面
  CHART-16003 调整富文本编辑器自定义JS界面宽度
bugfix/10.0
superman 4 years ago
parent
commit
a33928063f
  1. 3
      designer-chart/src/main/java/com/fr/van/chart/designer/component/VanChartHtmlLabelPane.java
  2. 3
      designer-chart/src/main/java/com/fr/van/chart/designer/component/VanChartRichEditorDialog.java
  3. 10
      designer-chart/src/main/java/com/fr/van/chart/designer/component/VanChartTooltipContentPane.java
  4. 4
      designer-chart/src/main/java/com/fr/van/chart/designer/component/label/GaugeLabelContentPane.java
  5. 1
      designer-chart/src/main/java/com/fr/van/chart/funnel/designer/style/VanChartFunnelTooltipContentPane.java
  6. 4
      designer-chart/src/main/java/com/fr/van/chart/gantt/designer/style/label/VanChartGanttLabelContentPane.java
  7. 4
      designer-chart/src/main/java/com/fr/van/chart/structure/desinger/style/VanChartStructureLabelContentPane.java
  8. 1
      designer-chart/src/main/java/com/fr/van/chart/wordcloud/designer/style/VanChartWordCloudTooltipContentPane.java
  9. 2
      designer-chart/src/main/resources/com/fr/design/editor/script/editor.js

3
designer-chart/src/main/java/com/fr/van/chart/designer/component/VanChartHtmlLabelPane.java

@ -148,11 +148,12 @@ public class VanChartHtmlLabelPane extends JPanel{
double p = TableLayout.PREFERRED; double p = TableLayout.PREFERRED;
double f = TableLayout.FILL; double f = TableLayout.FILL;
double[] columnSize = { p, f }; double[] columnSize = { p, f };
double[] rowSize = { p, p}; double[] rowSize = {p, p, p};
Component[][] components = new Component[][]{ Component[][] components = new Component[][]{
new Component[]{isCustomWidth, customWidth}, new Component[]{isCustomWidth, customWidth},
new Component[]{isCustomHeight, customHeight}, new Component[]{isCustomHeight, customHeight},
new Component[] {null, null}
}; };
return TableLayoutHelper.createTableLayoutPane(components, rowSize, columnSize); return TableLayoutHelper.createTableLayoutPane(components, rowSize, columnSize);
} }

3
designer-chart/src/main/java/com/fr/van/chart/designer/component/VanChartRichEditorDialog.java

@ -18,7 +18,8 @@ public class VanChartRichEditorDialog extends BasicDialog {
this.setTitle(Toolkit.i18nText("Fine-Design_Report_RichTextEditor")); this.setTitle(Toolkit.i18nText("Fine-Design_Report_RichTextEditor"));
this.setBasicDialogSize(DEFAULT); this.setBasicDialogSize(DEFAULT);
GUICoreUtils.centerWindow(this); GUICoreUtils.centerWindow(this);
this.setResizable(false); this.setResizable(true);
this.setModal(true);
} }
protected void applyEnterAction() { protected void applyEnterAction() {

10
designer-chart/src/main/java/com/fr/van/chart/designer/component/VanChartTooltipContentPane.java

@ -9,6 +9,7 @@ import com.fr.design.gui.ilable.UILabel;
import com.fr.design.i18n.Toolkit; import com.fr.design.i18n.Toolkit;
import com.fr.design.layout.TableLayout; import com.fr.design.layout.TableLayout;
import com.fr.design.layout.TableLayoutHelper; import com.fr.design.layout.TableLayoutHelper;
import com.fr.design.mainframe.DesignerContext;
import com.fr.design.mainframe.chart.gui.style.ChartTextAttrPane; import com.fr.design.mainframe.chart.gui.style.ChartTextAttrPane;
import com.fr.design.ui.ModernUIPane; import com.fr.design.ui.ModernUIPane;
import com.fr.plugin.chart.base.AttrTooltipContent; import com.fr.plugin.chart.base.AttrTooltipContent;
@ -32,7 +33,6 @@ import com.fr.van.chart.designer.component.format.VanChartFormatPaneWithoutCheck
import com.fr.van.chart.designer.style.VanChartStylePane; import com.fr.van.chart.designer.style.VanChartStylePane;
import javax.swing.JComponent; import javax.swing.JComponent;
import javax.swing.JFrame;
import javax.swing.JPanel; import javax.swing.JPanel;
import javax.swing.SwingUtilities; import javax.swing.SwingUtilities;
import java.awt.BorderLayout; import java.awt.BorderLayout;
@ -246,7 +246,7 @@ public class VanChartTooltipContentPane extends BasicBeanPane<AttrTooltipContent
} else if (content.getSelectedIndex() == RICH_EDITOR_INDEX) { } else if (content.getSelectedIndex() == RICH_EDITOR_INDEX) {
return editorPanel.getPreferredSize(); return editorPanel.getPreferredSize();
} else { } else {
return htmlPanel.getPreferredSize(); return new Dimension(commonPanel.getPreferredSize().width, htmlLabelPane.getPreferredSize().height);
} }
} }
}; };
@ -262,7 +262,7 @@ public class VanChartTooltipContentPane extends BasicBeanPane<AttrTooltipContent
if (content.getSelectedIndex() == COMMON_INDEX) { if (content.getSelectedIndex() == COMMON_INDEX) {
return commonPanel.getPreferredSize(); return commonPanel.getPreferredSize();
} else { } else {
return htmlPanel.getPreferredSize(); return new Dimension(commonPanel.getPreferredSize().width, htmlLabelPane.getPreferredSize().height);
} }
} }
}; };
@ -407,7 +407,7 @@ public class VanChartTooltipContentPane extends BasicBeanPane<AttrTooltipContent
private void fireRichEditor() { private void fireRichEditor() {
final ModernUIPane<VanChartRichEditorPane.RichEditorModel> pane = VanChartRichEditorPane.createRichEditorPane(richText); final ModernUIPane<VanChartRichEditorPane.RichEditorModel> pane = VanChartRichEditorPane.createRichEditorPane(richText);
BasicDialog dialog = new VanChartRichEditorDialog(new JFrame(), pane); BasicDialog dialog = new VanChartRichEditorDialog(DesignerContext.getDesignerFrame(), pane);
pane.populate(VanChartRichEditorPane.getRichEditorModel(richText)); pane.populate(VanChartRichEditorPane.getRichEditorModel(richText));
@ -608,8 +608,8 @@ public class VanChartTooltipContentPane extends BasicBeanPane<AttrTooltipContent
setDirty(false); setDirty(false);
} }
checkCardPane();
checkStylePane(); checkStylePane();
checkCardPane();
} }
private void populateTypeButton(AttrTooltipContent attrTooltipContent) { private void populateTypeButton(AttrTooltipContent attrTooltipContent) {

4
designer-chart/src/main/java/com/fr/van/chart/designer/component/label/GaugeLabelContentPane.java

@ -2,7 +2,7 @@ package com.fr.van.chart.designer.component.label;
import com.fr.design.i18n.Toolkit; import com.fr.design.i18n.Toolkit;
import com.fr.van.chart.designer.component.VanChartTooltipContentPane; import com.fr.van.chart.designer.component.VanChartLabelContentPane;
import com.fr.van.chart.designer.style.VanChartStylePane; import com.fr.van.chart.designer.style.VanChartStylePane;
import javax.swing.JPanel; import javax.swing.JPanel;
@ -10,7 +10,7 @@ import javax.swing.JPanel;
/** /**
* Created by mengao on 2017/8/13. * Created by mengao on 2017/8/13.
*/ */
public class GaugeLabelContentPane extends VanChartTooltipContentPane { public class GaugeLabelContentPane extends VanChartLabelContentPane {
public GaugeLabelContentPane(VanChartStylePane parent, JPanel showOnPane) { public GaugeLabelContentPane(VanChartStylePane parent, JPanel showOnPane) {
super(parent, showOnPane); super(parent, showOnPane);

1
designer-chart/src/main/java/com/fr/van/chart/funnel/designer/style/VanChartFunnelTooltipContentPane.java

@ -62,6 +62,7 @@ public class VanChartFunnelTooltipContentPane extends VanChartTooltipContentPane
AttrTooltipContent attrTooltipContent = new AttrTooltipContent(); AttrTooltipContent attrTooltipContent = new AttrTooltipContent();
attrTooltipContent.getCategoryFormat().setEnable(false); attrTooltipContent.getCategoryFormat().setEnable(false);
attrTooltipContent.setSeriesFormat(new AttrTooltipNameFormat()); attrTooltipContent.setSeriesFormat(new AttrTooltipNameFormat());
attrTooltipContent.setRichTextSeriesFormat(new AttrTooltipNameFormat());
attrTooltipContent.getSeriesFormat().setEnable(true); attrTooltipContent.getSeriesFormat().setEnable(true);
attrTooltipContent.getValueFormat().setEnable(true); attrTooltipContent.getValueFormat().setEnable(true);
return attrTooltipContent; return attrTooltipContent;

4
designer-chart/src/main/java/com/fr/van/chart/gantt/designer/style/label/VanChartGanttLabelContentPane.java

@ -3,7 +3,7 @@ package com.fr.van.chart.gantt.designer.style.label;
import com.fr.design.i18n.Toolkit; import com.fr.design.i18n.Toolkit;
import com.fr.plugin.chart.base.AttrTooltipContent; import com.fr.plugin.chart.base.AttrTooltipContent;
import com.fr.plugin.chart.gantt.attr.AttrGanttTooltipContent; import com.fr.plugin.chart.gantt.attr.AttrGanttTooltipContent;
import com.fr.van.chart.designer.component.VanChartTooltipContentPane; import com.fr.van.chart.designer.component.VanChartLabelContentPane;
import com.fr.van.chart.designer.component.format.SeriesNameFormatPaneWithCheckBox; import com.fr.van.chart.designer.component.format.SeriesNameFormatPaneWithCheckBox;
import com.fr.van.chart.designer.component.format.VanChartFormatPaneWithCheckBox; import com.fr.van.chart.designer.component.format.VanChartFormatPaneWithCheckBox;
import com.fr.van.chart.designer.style.VanChartStylePane; import com.fr.van.chart.designer.style.VanChartStylePane;
@ -16,7 +16,7 @@ import java.awt.Component;
/** /**
* Created by hufan on 2017/1/13. * Created by hufan on 2017/1/13.
*/ */
public class VanChartGanttLabelContentPane extends VanChartTooltipContentPane { public class VanChartGanttLabelContentPane extends VanChartLabelContentPane {
private VanChartFormatPaneWithCheckBox processesFormatPane; private VanChartFormatPaneWithCheckBox processesFormatPane;
private VanChartDateFormatPaneWithCheckBox startTimeFormatPane; private VanChartDateFormatPaneWithCheckBox startTimeFormatPane;

4
designer-chart/src/main/java/com/fr/van/chart/structure/desinger/style/VanChartStructureLabelContentPane.java

@ -4,7 +4,7 @@ package com.fr.van.chart.structure.desinger.style;
import com.fr.design.i18n.Toolkit; import com.fr.design.i18n.Toolkit;
import com.fr.plugin.chart.base.AttrTooltipContent; import com.fr.plugin.chart.base.AttrTooltipContent;
import com.fr.plugin.chart.multilayer.style.AttrTooltipMultiLevelNameFormat; import com.fr.plugin.chart.multilayer.style.AttrTooltipMultiLevelNameFormat;
import com.fr.van.chart.designer.component.VanChartTooltipContentPane; import com.fr.van.chart.designer.component.VanChartLabelContentPane;
import com.fr.van.chart.designer.component.format.CategoryNameFormatPaneWithCheckBox; import com.fr.van.chart.designer.component.format.CategoryNameFormatPaneWithCheckBox;
import com.fr.van.chart.designer.component.format.PercentFormatPaneWithCheckBox; import com.fr.van.chart.designer.component.format.PercentFormatPaneWithCheckBox;
import com.fr.van.chart.designer.component.format.SeriesNameFormatPaneWithCheckBox; import com.fr.van.chart.designer.component.format.SeriesNameFormatPaneWithCheckBox;
@ -17,7 +17,7 @@ import java.awt.Component;
/** /**
* Created by shine on 2017/2/15. * Created by shine on 2017/2/15.
*/ */
public class VanChartStructureLabelContentPane extends VanChartTooltipContentPane { public class VanChartStructureLabelContentPane extends VanChartLabelContentPane {
public VanChartStructureLabelContentPane(VanChartStylePane parent, JPanel showOnPane) { public VanChartStructureLabelContentPane(VanChartStylePane parent, JPanel showOnPane) {
super(parent, showOnPane); super(parent, showOnPane);
} }

1
designer-chart/src/main/java/com/fr/van/chart/wordcloud/designer/style/VanChartWordCloudTooltipContentPane.java

@ -81,6 +81,7 @@ public class VanChartWordCloudTooltipContentPane extends VanChartTooltipContentP
protected AttrTooltipContent createAttrTooltip() { protected AttrTooltipContent createAttrTooltip() {
AttrTooltipContent attrTooltipContent = new AttrTooltipContent(); AttrTooltipContent attrTooltipContent = new AttrTooltipContent();
attrTooltipContent.setSeriesFormat(new AttrTooltipNameFormat()); attrTooltipContent.setSeriesFormat(new AttrTooltipNameFormat());
attrTooltipContent.setRichTextSeriesFormat(new AttrTooltipNameFormat());
return attrTooltipContent; return attrTooltipContent;
} }
} }

2
designer-chart/src/main/resources/com/fr/design/editor/script/editor.js

@ -107,7 +107,7 @@
_cleanHtml: function (value) { _cleanHtml: function (value) {
var editorService = BI.Services.getService("bi.service.design.chart.common.editor"); var editorService = BI.Services.getService("bi.service.design.chart.common.editor");
var dimensionIds = this.options.dimensionIds; var dimensionIds = this.model.dimensionIds;
var dataIdMap = {}; var dataIdMap = {};
for (var i = 0, len = dimensionIds.length; i < len; i++) { for (var i = 0, len = dimensionIds.length; i < len; i++) {

Loading…
Cancel
Save