diff --git a/designer-chart/src/main/java/com/fr/van/chart/designer/component/VanChartLabelContentPane.java b/designer-chart/src/main/java/com/fr/van/chart/designer/component/VanChartLabelContentPane.java index 06c0640819..1aaf53424c 100644 --- a/designer-chart/src/main/java/com/fr/van/chart/designer/component/VanChartLabelContentPane.java +++ b/designer-chart/src/main/java/com/fr/van/chart/designer/component/VanChartLabelContentPane.java @@ -1,13 +1,17 @@ package com.fr.van.chart.designer.component; +import com.fr.design.mainframe.chart.gui.style.ChartTextAttrPane; +import com.fr.design.mainframe.chart.gui.style.ChartTextAttrPaneWithAuto; import com.fr.design.mainframe.chart.gui.style.ChartTextAttrPaneWithThemeStyle; import com.fr.design.mainframe.chart.mode.ChartEditContext; import com.fr.plugin.chart.base.AttrTooltipContent; +import com.fr.plugin.chart.type.FontAutoType; import com.fr.plugin.chart.type.TextAlign; import com.fr.van.chart.designer.style.VanChartStylePane; import javax.swing.JPanel; import java.awt.BorderLayout; +import java.awt.Component; public class VanChartLabelContentPane extends VanChartTooltipContentPane { @@ -37,6 +41,19 @@ public class VanChartLabelContentPane extends VanChartTooltipContentPane { return stylePanel; } + @Override + protected ChartTextAttrPane createChartTextAttrPane() { + return new ChartTextAttrPaneWithAuto(FontAutoType.COLOR) { + protected Component[][] getComponents(JPanel buttonPane) { + return new Component[][]{ + new Component[]{null, null}, + new Component[]{null, getFontNameComboBox()}, + new Component[]{null, buttonPane} + }; + } + }; + } + public void updateTextAttr(AttrTooltipContent attrTooltipContent) { if (isInCondition() || !ChartEditContext.supportTheme()) { super.updateTextAttr(attrTooltipContent); diff --git a/designer-chart/src/main/java/com/fr/van/chart/designer/component/VanChartTooltipContentPane.java b/designer-chart/src/main/java/com/fr/van/chart/designer/component/VanChartTooltipContentPane.java index bdbdee6a86..ab84b88b89 100644 --- a/designer-chart/src/main/java/com/fr/van/chart/designer/component/VanChartTooltipContentPane.java +++ b/designer-chart/src/main/java/com/fr/van/chart/designer/component/VanChartTooltipContentPane.java @@ -11,7 +11,6 @@ import com.fr.design.layout.TableLayout; 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.ChartTextAttrPaneWithAuto; import com.fr.design.ui.ModernUIPane; import com.fr.general.ComparatorUtils; import com.fr.plugin.chart.base.AttrTooltipContent; @@ -22,7 +21,6 @@ import com.fr.plugin.chart.base.format.AttrTooltipFormat; import com.fr.plugin.chart.base.format.AttrTooltipPercentFormat; import com.fr.plugin.chart.base.format.AttrTooltipSeriesFormat; import com.fr.plugin.chart.base.format.AttrTooltipValueFormat; -import com.fr.plugin.chart.type.FontAutoType; import com.fr.stable.StringUtils; import com.fr.van.chart.designer.TableLayout4VanChartHelper; import com.fr.van.chart.designer.component.format.CategoryNameFormatPaneWithCheckBox; @@ -41,10 +39,6 @@ import com.fr.van.chart.designer.style.VanChartStylePane; import javax.swing.JComponent; import javax.swing.JPanel; import javax.swing.SwingUtilities; -import java.util.Arrays; -import java.util.LinkedHashMap; -import java.util.List; -import java.util.Map; import java.awt.BorderLayout; import java.awt.CardLayout; import java.awt.Component; @@ -53,6 +47,10 @@ import java.awt.event.ActionEvent; import java.awt.event.ActionListener; import java.awt.event.MouseAdapter; import java.awt.event.MouseEvent; +import java.util.Arrays; +import java.util.LinkedHashMap; +import java.util.List; +import java.util.Map; /** * 数据点提示内容界面,含有通用设置、富文本编辑器、自定义JS界面 @@ -317,15 +315,7 @@ public class VanChartTooltipContentPane extends BasicBeanPane