|
|
|
@ -1,7 +1,11 @@
|
|
|
|
|
package com.fr.van.chart.map.line; |
|
|
|
|
|
|
|
|
|
import com.fine.theme.utils.FineLayoutBuilder; |
|
|
|
|
import com.formdev.flatlaf.util.ScaledEmptyBorder; |
|
|
|
|
import com.fr.design.constants.LayoutConstants; |
|
|
|
|
import com.fr.design.gui.icombobox.UIComboBox; |
|
|
|
|
import com.fr.design.gui.ilable.UILabel; |
|
|
|
|
import com.fr.design.i18n.Toolkit; |
|
|
|
|
import com.fr.general.ComparatorUtils; |
|
|
|
|
|
|
|
|
|
import com.fr.plugin.chart.base.AttrEffect; |
|
|
|
@ -11,7 +15,6 @@ import com.fr.van.chart.designer.TableLayout4VanChartHelper;
|
|
|
|
|
import com.fr.van.chart.designer.component.marker.VanChartImageMarkerPane; |
|
|
|
|
import com.fr.van.chart.designer.style.series.VanChartEffectPane; |
|
|
|
|
|
|
|
|
|
import javax.swing.BorderFactory; |
|
|
|
|
import javax.swing.JPanel; |
|
|
|
|
import java.awt.BorderLayout; |
|
|
|
|
import java.awt.CardLayout; |
|
|
|
@ -20,6 +23,9 @@ import java.awt.Dimension;
|
|
|
|
|
import java.awt.event.ItemEvent; |
|
|
|
|
import java.awt.event.ItemListener; |
|
|
|
|
|
|
|
|
|
import static com.fine.swing.ui.layout.Layouts.cell; |
|
|
|
|
import static com.fine.swing.ui.layout.Layouts.column; |
|
|
|
|
|
|
|
|
|
/** |
|
|
|
|
* Created by hufan on 2016/12/20. |
|
|
|
|
*/ |
|
|
|
@ -32,39 +38,34 @@ public class VanChartLineMapEffectPane extends VanChartEffectPane {
|
|
|
|
|
|
|
|
|
|
public VanChartLineMapEffectPane() { |
|
|
|
|
super(true); |
|
|
|
|
this.add(TableLayout4VanChartHelper.createGapTableLayoutPane(com.fr.design.i18n.Toolkit.i18nText("Fine-Design_Chart_Line_Map_Animation"), enabledButton), BorderLayout.NORTH); |
|
|
|
|
JPanel panel = FineLayoutBuilder.createHorizontalLayout(0, new double[]{1.2, 3}, |
|
|
|
|
new UILabel(Toolkit.i18nText("Fine-Design_Chart_Line_Map_Animation")), enabledButton); |
|
|
|
|
panel.setBorder(new ScaledEmptyBorder(0, 0, 10,0)); |
|
|
|
|
this.add(panel, BorderLayout.NORTH); |
|
|
|
|
} |
|
|
|
|
|
|
|
|
|
/** |
|
|
|
|
* 流向动画 |
|
|
|
|
* @return contentPane |
|
|
|
|
*/ |
|
|
|
|
protected JPanel createContentPane() { |
|
|
|
|
JPanel panel = new JPanel(new BorderLayout(0, 5)); |
|
|
|
|
JPanel panel = new JPanel(new BorderLayout()); |
|
|
|
|
// 运动周期
|
|
|
|
|
JPanel periodPane = createPeriodPane(); |
|
|
|
|
|
|
|
|
|
// 运动方式
|
|
|
|
|
animationType = new UIComboBox(LineMapAnimationType.getTypes()); |
|
|
|
|
initTypeContentPane(); |
|
|
|
|
|
|
|
|
|
JPanel animationTypePane = new JPanel(new BorderLayout(0, 5)); |
|
|
|
|
|
|
|
|
|
animationTypePane.add(createAnimationSelectPane(), BorderLayout.NORTH); |
|
|
|
|
animationTypePane.add(typeContentPane, BorderLayout.CENTER); |
|
|
|
|
|
|
|
|
|
panel.add(periodPane, BorderLayout.CENTER); |
|
|
|
|
panel.add(animationTypePane, BorderLayout.SOUTH); |
|
|
|
|
panel.setBorder(BorderFactory.createEmptyBorder(0, 12, 0, 0)); |
|
|
|
|
|
|
|
|
|
panel.add(column(LayoutConstants.VERTICAL_GAP, cell(periodPane), cell(createAnimationSelectPane()), cell(typeContentPane)).getComponent()); |
|
|
|
|
return panel; |
|
|
|
|
} |
|
|
|
|
|
|
|
|
|
protected void setContentPaneBorder() { |
|
|
|
|
return; |
|
|
|
|
} |
|
|
|
|
|
|
|
|
|
/** |
|
|
|
|
* 运动方式 |
|
|
|
|
* @return animationSelectPane |
|
|
|
|
*/ |
|
|
|
|
private Component createAnimationSelectPane() { |
|
|
|
|
JPanel panel = new JPanel(new BorderLayout(5, 0)); |
|
|
|
|
UILabel label1 = new UILabel(com.fr.design.i18n.Toolkit.i18nText("Fine-Design_Chart_Animation_Type")); |
|
|
|
|
label1.setPreferredSize(new Dimension((int) TableLayout4VanChartHelper.DESCRIPTION_AREA_WIDTH, 20)); |
|
|
|
|
panel.add(label1, BorderLayout.WEST); |
|
|
|
|
panel.add(animationType, BorderLayout.CENTER); |
|
|
|
|
return panel; |
|
|
|
|
return FineLayoutBuilder.createHorizontalLayout(0, new double[]{1.2, 3}, |
|
|
|
|
new UILabel(Toolkit.i18nText("Fine-Design_Chart_Animation_Type")), animationType); |
|
|
|
|
} |
|
|
|
|
|
|
|
|
|
private void initTypeContentPane() { |
|
|
|
|