Browse Source

CHART-16173 柱形图富文本标签时文本方向调整成横向

feature/big-screen
Qinghui.Liu 4 years ago
parent
commit
d8e0cc3511
  1. 12
      designer-chart/src/main/java/com/fr/van/chart/column/VanChartColumnPlotLabelDetailPane.java
  2. 2
      designer-chart/src/main/java/com/fr/van/chart/designer/style/label/VanChartPlotLabelDetailPane.java

12
designer-chart/src/main/java/com/fr/van/chart/column/VanChartColumnPlotLabelDetailPane.java

@ -22,8 +22,16 @@ public class VanChartColumnPlotLabelDetailPane extends VanChartPlotLabelDetailPa
AttrTooltipContent content = detail.getContent();
UIButtonGroup<Integer> orientation = getOrientation();
if (orientation != null) {
orientation.setEnabled(content != null && !content.isRichText());
if (orientation != null && content != null) {
if (content.isRichText()) {
orientation.setSelectedIndex(HORIZONTAL_INDEX);
detail.setHorizontal(true);
orientation.setEnabled(false);
} else {
orientation.setEnabled(true);
}
}
}

2
designer-chart/src/main/java/com/fr/van/chart/designer/style/label/VanChartPlotLabelDetailPane.java

@ -36,7 +36,7 @@ import java.awt.Component;
public class VanChartPlotLabelDetailPane extends BasicPane {
private static final long serialVersionUID = -22438250307946275L;
private static final int HORIZONTAL_INDEX = 0;
public static final int HORIZONTAL_INDEX = 0;
private BasicBeanPane<AttrTooltipContent> dataLabelContentPane;

Loading…
Cancel
Save