Browse Source

Merging in latest from upstream (BA/design:refs/heads/release/9.0)

* commit '65f3870e85aee0ba92b35688eea5bf0235b13e5b':
  按照最新设计,处理连续弹窗问题
  修改老图表部分面板问题 按照最新设计,处理连续弹窗问题 修改9.0新图表bug
  REPORT-2897 9.0设计器修改 缩放条在不同的sheet切换不应该继承 PMD
  REPORT-4361 单元格元素 数据列 数据设置 分组 高级 自定义按钮问题
  REPORT-4308 单元格属性-样式,修改文本自定义样式无法实时生效
  REPORT-4363 表单工具栏图表和控件的扩展按钮,点击后,扩展的部分位置错乱
  代码质量
  REPORT-2897 9.0设计器修改 缩放条在不同的sheet切换不应该继承
  rollback UIToggleButton
  rollback UIToggleButton
  REPORT-2897 9.0设计器修改 缩放条在不同的sheet切换不应该继承 去掉表单缩放条
  rollback
  提交
master
kerry 7 years ago
parent
commit
1ab7b82317
  1. 31
      designer/src/com/fr/design/dscolumn/ResultSetGroupDockingPane.java
  2. 10
      designer/src/com/fr/design/mainframe/ElementCasePane.java
  3. 5
      designer/src/com/fr/design/mainframe/JWorkBook.java
  4. 5
      designer/src/com/fr/design/mainframe/ReportComponent.java
  5. 9
      designer/src/com/fr/design/mainframe/ReportComponentComposite.java
  6. 11
      designer/src/com/fr/design/mainframe/WorkSheetDesigner.java
  7. 15
      designer/src/com/fr/poly/PolyDesigner.java
  8. 2
      designer/src/com/fr/quickeditor/cellquick/CellDSColumnEditor.java
  9. 8
      designer_base/src/com/fr/design/gui/controlpane/UIControlPane.java
  10. 2
      designer_base/src/com/fr/design/gui/controlpane/UIListControlPane.java
  11. 126
      designer_base/src/com/fr/design/gui/icombobox/TextFontComboBox.java
  12. 15
      designer_base/src/com/fr/design/gui/style/FormatPane.java
  13. 4
      designer_base/src/com/fr/design/mainframe/JSliderPane.java
  14. 2
      designer_base/src/com/fr/design/mainframe/JTemplate.java
  15. 5
      designer_chart/src/com/fr/design/chart/report/MapDataPane.java
  16. 31
      designer_chart/src/com/fr/design/chart/report/MapTableDataSinglePane.java
  17. 2
      designer_chart/src/com/fr/design/chart/series/PlotSeries/MapGroupExtensionPane.java
  18. 4
      designer_chart/src/com/fr/design/mainframe/chart/gui/data/DatabaseTableDataPane.java
  19. 5
      designer_chart/src/com/fr/design/mainframe/chart/gui/style/ChartAccColorPane.java
  20. 21
      designer_chart/src/com/fr/design/mainframe/chart/gui/style/axis/ChartCategoryPane.java
  21. 3
      designer_chart/src/com/fr/design/mainframe/chart/gui/style/axis/ChartValuePane.java
  22. 21
      designer_chart/src/com/fr/design/mainframe/chart/gui/style/datasheet/ChartDatasheetPane.java
  23. 9
      designer_chart/src/com/fr/design/mainframe/chart/gui/style/series/MeterSeriesPane.java
  24. 13
      designer_chart/src/com/fr/design/mainframe/chart/gui/style/series/UIColorPickerPane.java
  25. 94
      designer_chart/src/com/fr/plugin/chart/custom/component/VanChartHyperLinkPane.java
  26. 27
      designer_chart/src/com/fr/plugin/chart/designer/other/HyperlinkMapFactory.java
  27. 6
      designer_form/src/com/fr/design/mainframe/FormArea.java
  28. 15
      designer_form/src/com/fr/design/mainframe/FormParaWidgetPane.java
  29. 5
      designer_form/src/com/fr/design/mainframe/JForm.java

31
designer/src/com/fr/design/dscolumn/ResultSetGroupDockingPane.java

@ -7,7 +7,6 @@ import com.fr.design.gui.ilable.UILabel;
import com.fr.design.layout.FRGUIPaneFactory;
import com.fr.design.layout.TableLayout;
import com.fr.design.layout.TableLayoutHelper;
import com.fr.design.mainframe.ElementCasePane;
import com.fr.design.utils.gui.GUICoreUtils;
import com.fr.general.Inter;
import com.fr.report.cell.TemplateCellElement;
@ -41,12 +40,12 @@ public class ResultSetGroupDockingPane extends ResultSetGroupPane {
private ItemListener listener;
public ResultSetGroupDockingPane(ElementCasePane ePane) {
public ResultSetGroupDockingPane() {
super();
this.initComponents(ePane);
this.initComponents();
}
public void initComponents(ElementCasePane ePane) {
public void initComponents() {
goBox = new UIComboBox(new String[]{Inter.getLocText("BindColumn-Group"), Inter.getLocText("BindColumn-Select"), Inter.getLocText("BindColumn-Summary")});
initCardPane();
contentPane = layoutPane();
@ -66,22 +65,23 @@ public class ResultSetGroupDockingPane extends ResultSetGroupPane {
};
goBox.addItemListener(new ItemListener() {
public void itemStateChanged(ItemEvent ee) {
checkButtonEnabled();
int i = goBox.getSelectedIndex();
if (i == BIND_GROUP) {
cardLayout.show(cardPane, "groupPane");
cardPane.setPreferredSize(new Dimension(156, 20));
cardPane.setPreferredSize(new Dimension(158, 20));
TableLayoutHelper.modifyTableLayoutIndexVGap(contentPane, 2, 10);
checkButtonEnabled();
} else if (i == BIND_SELECTED) {
cardLayout.show(cardPane, "listPane");
cardPane.setPreferredSize(new Dimension(0, 0));
TableLayoutHelper.modifyTableLayoutIndexVGap(contentPane, 2, 0);
} else if (i == BIND_SUMMARY) {
cardLayout.show(cardPane, "summaryPane");
cardPane.setPreferredSize(new Dimension(156, 20));
cardPane.setPreferredSize(new Dimension(158, 20));
TableLayoutHelper.modifyTableLayoutIndexVGap(contentPane, 2, 10);
CellExpandAttr cellExpandAttr = cellElement.getCellExpandAttr();
cellExpandAttr.setDirection(Constants.NONE);
checkButtonEnabled();
}
}
});
@ -96,7 +96,6 @@ public class ResultSetGroupDockingPane extends ResultSetGroupPane {
cardLayout = new CardLayout();
cardPane.setLayout(cardLayout);
JPanel pane = new JPanel(new BorderLayout(3, 0));
groupComboBox.addItemListener(new ItemListener() {
public void itemStateChanged(ItemEvent e) {
checkButtonEnabled();
@ -104,7 +103,9 @@ public class ResultSetGroupDockingPane extends ResultSetGroupPane {
});
advancedButton = new UIButton(Inter.getLocText("Custom"));
advancedButton.addActionListener(groupAdvancedListener);
pane.add(groupComboBox, BorderLayout.WEST);
JPanel pane = new JPanel(new BorderLayout(0, 10));
pane.add(groupComboBox, BorderLayout.NORTH);
pane.add(advancedButton, BorderLayout.CENTER);
cardPane.add(pane, "groupPane");
@ -124,7 +125,7 @@ public class ResultSetGroupDockingPane extends ResultSetGroupPane {
// RecordGrouper
recordGrouper = dSColumn.getGrouper();
if (recordGrouper instanceof FunctionGrouper && !((FunctionGrouper) recordGrouper).isCustom()) {
int mode = ((FunctionGrouper) recordGrouper).getDivideMode();
int mode = recordGrouper.getDivideMode();
if (mode == FunctionGrouper.GROUPING_MODE) {
cardLayout.show(cardPane, "groupPane");
this.goBox.setSelectedIndex(BIND_GROUP);
@ -152,7 +153,6 @@ public class ResultSetGroupDockingPane extends ResultSetGroupPane {
this.goBox.setSelectedIndex(BIND_GROUP);
this.groupComboBox.setSelectedIndex(ADVANCED);
}
checkButtonEnabled();
}
@ -190,6 +190,15 @@ public class ResultSetGroupDockingPane extends ResultSetGroupPane {
advancedButton.setEnabled(true);
}
}
if (advancedButton.isEnabled()) {
cardPane.setPreferredSize(new Dimension(158, 50));
cardPane.revalidate();
cardPane.repaint();
} else {
cardPane.setPreferredSize(new Dimension(158, 20));
cardPane.revalidate();
cardPane.repaint();
}
}
public void addListener(ItemListener listener) {

10
designer/src/com/fr/design/mainframe/ElementCasePane.java

@ -1325,7 +1325,7 @@ public abstract class ElementCasePane<T extends TemplateElementCase> extends Tar
* @return 返回正在编辑的状态.
*/
public EditingState createEditingState() {
return new ElementCaseEditingState(this.selection, this.verScrollBar.getValue(), this.horScrollBar.getValue());
return new ElementCaseEditingState(this.selection, this.verScrollBar.getValue(), this.horScrollBar.getValue(), this.resolution);
}
public void setCellNeedTOFormat(CellSelection selection) {
@ -1341,15 +1341,18 @@ public abstract class ElementCasePane<T extends TemplateElementCase> extends Tar
protected Selection selection;
protected int verticalValue = 0;
protected int horizontalValue = 0;
protected int resolution = ScreenResolution.getScreenResolution();
protected ElementCaseEditingState(Selection selection, int verticalValue, int horizontalValue) {
protected ElementCaseEditingState(Selection selection, int verticalValue, int horizontalValue, int resolution) {
try {
this.selection = selection.clone();
this.resolution = resolution;
} catch (CloneNotSupportedException e) {
throw new RuntimeException(e);
}
this.verticalValue = verticalValue;
this.horizontalValue = horizontalValue;
this.resolution = resolution;
}
@Override
@ -1363,7 +1366,8 @@ public abstract class ElementCasePane<T extends TemplateElementCase> extends Tar
ElementCasePane.this.getVerticalScrollBar().setValue(this.verticalValue);
ElementCasePane.this.getHorizontalScrollBar().setValue(this.horizontalValue);
// ElementCasePane.this.setResolution(this.resolution);
HistoryTemplateListPane.getInstance().getCurrentEditingTemplate().setScale(this.resolution);
// 重绘.
ElementCasePane.this.repaint();
}

5
designer/src/com/fr/design/mainframe/JWorkBook.java

@ -129,6 +129,11 @@ public class JWorkBook extends JTemplate<WorkBook, WorkBookUndoState> {
return getEditingElementCasePane();
}
@Override
public JComponent getCurrentReportComponentPane() {
return reportComposite;
}
@Override
protected UIModeControlContainer createCenterPane() {
parameterPane = ModuleContext.isModuleStarted(Module.FORM_MODULE) ? new ParameterDefinitePane() : null;

5
designer/src/com/fr/design/mainframe/ReportComponent.java

@ -44,6 +44,11 @@ public abstract class ReportComponent<T extends TemplateReport, E extends Elemen
public abstract S getDefaultSelectElement();
/**
* 更新JSliderPane
*/
public abstract void updateJSliderValue();
@Override
public ShortCut[] shortcut4TemplateMenu() {

9
designer/src/com/fr/design/mainframe/ReportComponentComposite.java

@ -111,7 +111,6 @@ public class ReportComponentComposite extends JComponent {
return;
}
centerCardPane.populate(workbook.getTemplateReport(newIndex));
if (parentContainer != null) {
parentContainer.setDownPane(ReportComponentComposite.this);
}
@ -120,12 +119,16 @@ public class ReportComponentComposite extends JComponent {
EditingState reportPaneEditState = templateStateList.get(newIndex);
if (reportPaneEditState != null) {
reportPaneEditState.revert();
updateJSlider();
}
} else {
while (templateStateList.size() <= newIndex) {
templateStateList.add(null);
}
centerCardPane.editingComponet.setSelection(centerCardPane.editingComponet.getDefaultSelectElement());
if (jSliderContainer != null){
jSliderContainer.reset();
}
}
if (centerCardPane.editingComponet.elementCasePane == null) {
@ -141,6 +144,10 @@ public class ReportComponentComposite extends JComponent {
}
}
private void updateJSlider(){
centerCardPane.editingComponet.updateJSliderValue();
}
/**
* 移除选中状态
*

11
designer/src/com/fr/design/mainframe/WorkSheetDesigner.java

@ -4,11 +4,13 @@ import java.awt.BorderLayout;
import javax.swing.*;
import com.fr.base.ScreenResolution;
import com.fr.design.DesignState;
import com.fr.design.actions.report.*;
import com.fr.design.designer.EditingState;
import com.fr.design.event.TargetModifiedEvent;
import com.fr.design.event.TargetModifiedListener;
import com.fr.design.file.HistoryTemplateListPane;
import com.fr.design.layout.FRGUIPaneFactory;
import com.fr.design.menu.*;
import com.fr.grid.selection.CellSelection;
@ -21,6 +23,8 @@ import com.fr.stable.ArrayUtils;
public class WorkSheetDesigner extends ReportComponent<WorkSheet, ElementCasePaneDelegate, Selection> {
private static final int HUND = 100;
public WorkSheetDesigner(WorkSheet sheet) {
super(sheet);
@ -166,6 +170,13 @@ public class WorkSheetDesigner extends ReportComponent<WorkSheet, ElementCasePan
return cellElement == null ? new CellSelection() : new CellSelection(0, 0, cellElement.getColumnSpan(), cellElement.getRowSpan());
}
@Override
public void updateJSliderValue() {
ReportComponentComposite reportComposite = (ReportComponentComposite) HistoryTemplateListPane.getInstance().getCurrentEditingTemplate().getCurrentReportComponentPane();
JSliderPane jSliderContainer = reportComposite.getjSliderContainer();
jSliderContainer.getShowVal().setValue((int)Math.ceil((double) this.elementCasePane.getResolution() * HUND / ScreenResolution.getScreenResolution()));
}
@Override
public void addSelectionChangeListener(SelectionListener selectionListener) {
elementCasePane.addSelectionChangeListener(selectionListener);

15
designer/src/com/fr/poly/PolyDesigner.java

@ -87,6 +87,7 @@ public class PolyDesigner extends ReportComponent<PolyWorkSheet, PolyElementCase
// richer:鼠标滚轮每滚动一下,PolyDesignPane的尺寸就改变ROTATIONS这么多
private static final int ROTATIONS = 50;
private static final int MIN = 10;
private static final int HUND = 100;
private JScrollBar verScrollBar;
private JScrollBar horScrollBar;
@ -687,14 +688,16 @@ public class PolyDesigner extends ReportComponent<PolyWorkSheet, PolyElementCase
* @return 返回正在编辑的状态.
*/
public EditingState createEditingState() {
return new PolyDesignerEditingState(selection);
return new PolyDesignerEditingState(selection, resolution);
}
private class PolyDesignerEditingState implements EditingState {
private String blockName;
private Selection select;
protected int resolution = ScreenResolution.getScreenResolution();
public PolyDesignerEditingState(BlockCreator creator) {
public PolyDesignerEditingState(BlockCreator creator, int resolution) {
this.resolution = resolution;
if (creator == null) {
return;
}
@ -710,6 +713,7 @@ public class PolyDesigner extends ReportComponent<PolyWorkSheet, PolyElementCase
public void revert() {
PolyDesigner.this.addedData = new AddedData(PolyDesigner.this);
stopEditingState();
HistoryTemplateListPane.getInstance().getCurrentEditingTemplate().setScale(this.resolution);
initPolyBlocks();
startEditing(blockName);
if (selection == null) {
@ -842,6 +846,13 @@ public class PolyDesigner extends ReportComponent<PolyWorkSheet, PolyElementCase
return null;
}
@Override
public void updateJSliderValue() {
ReportComponentComposite reportComposite = (ReportComponentComposite) HistoryTemplateListPane.getInstance().getCurrentEditingTemplate().getCurrentReportComponentPane();
JSliderPane jSliderContainer = reportComposite.getjSliderContainer();
jSliderContainer.getShowVal().setValue((int)Math.ceil((double)this.resolution * HUND / ScreenResolution.getScreenResolution()));
}
/**
* @return

2
designer/src/com/fr/quickeditor/cellquick/CellDSColumnEditor.java

@ -217,7 +217,7 @@ public class CellDSColumnEditor extends CellQuickEditor {
DSColumnBasicEditorPane() {
dataPane = new SelectedDataColumnPane(true, true, tc, cellElement);
groupPane = new ResultSetGroupDockingPane(tc);
groupPane = new ResultSetGroupDockingPane();
dataPane.addListener(dataListener);
groupPane.addListener(groupListener);

8
designer_base/src/com/fr/design/gui/controlpane/UIControlPane.java

@ -32,7 +32,7 @@ public abstract class UIControlPane extends BasicPane implements UnrepeatedNameH
private ToolBarDef toolbarDef;
private UIToolbar toolBar;
private UIToolbar topToolBar;
protected PopupEditDialog popupEditDialog;
protected Window popupEditDialog;
// peter:这是整体的一个cardLayout Pane
protected CardLayout cardLayout;
protected JPanel cardPane;
@ -119,7 +119,7 @@ public abstract class UIControlPane extends BasicPane implements UnrepeatedNameH
cardPane.add(selectLabel, "SELECT");
cardPane.add(controlUpdatePane, "EDIT");
if (isNewStyle()) {
popupEditDialog = new PopupEditDialog(cardPane);
getPopupEditDialog(cardPane);
this.add(getLeftPane(), BorderLayout.CENTER);
this.setBorder(BorderFactory.createEmptyBorder(10, 10, 15, 15));
} else {
@ -141,6 +141,10 @@ public abstract class UIControlPane extends BasicPane implements UnrepeatedNameH
this.checkButtonEnabled();
}
protected void getPopupEditDialog (JPanel cardPane) {
popupEditDialog = new PopupEditDialog(cardPane);
}
protected abstract JPanel createControlUpdatePane();
protected JPanel getLeftPane() {

2
designer_base/src/com/fr/design/gui/controlpane/UIListControlPane.java

@ -390,7 +390,7 @@ public abstract class UIListControlPane extends UIControlPane {
}
}
private void popupEditDialog(Point mousePos) {
protected void popupEditDialog(Point mousePos) {
if (isNewStyle()) {
Rectangle currentCellBounds = nameableList.getCellBounds(editingIndex, editingIndex);
if (editingIndex < 0 || !currentCellBounds.contains(mousePos)) {

126
designer_base/src/com/fr/design/gui/icombobox/TextFontComboBox.java

@ -0,0 +1,126 @@
package com.fr.design.gui.icombobox;
import com.fr.design.gui.icombobox.filter.Filter;
import com.fr.design.gui.icombobox.filter.StartsWithFilter;
import com.fr.design.gui.itextfield.UITextField;
import com.fr.stable.StringUtils;
import javax.swing.*;
import javax.swing.event.DocumentEvent;
import javax.swing.event.DocumentListener;
import java.awt.*;
import java.awt.event.ActionListener;
import java.util.ArrayList;
import java.util.List;
/**
* Created by MoMeak on 2017/9/5.
*/
public class TextFontComboBox<T> extends ExtendedComboBox {
private Filter filter;
public TextFontComboBox() {
this(new ArrayList<T>());
this.setEditable(true);
}
public TextFontComboBox(List<T> itemList) {
this(new StartsWithFilter(), itemList);
}
public TextFontComboBox(Filter filter, List<T> itemList) {
this.filter = filter;
setModel(new FilterableComboBoxModel(itemList));
setEditor(new TextFontComboBox.FilterComboBoxEditor());
setEditable(true);
}
public void setItemArray(T[] objectArray) {
List<T> itemList = new ArrayList<T>();
if (objectArray != null) {
for (int i = 0; i < objectArray.length; i++) {
itemList.add(objectArray[i]);
}
}
this.setItemList(itemList);
}
public void setItemList(List<T> itemList) {
((FilterableComboBoxModel) this.getModel()).setPrefix(StringUtils.EMPTY);
((FilterableComboBoxModel) this.getModel()).setItemList(itemList);
}
class FilterComboBoxEditor implements ComboBoxEditor, DocumentListener {
private Object item;
public UITextField textField;
private volatile boolean filtering = false;
private volatile boolean setting = false;
public FilterComboBoxEditor() {
textField = new UITextField(15);
textField.getDocument().addDocumentListener(this);
}
public Component getEditorComponent() {
return textField;
}
public void setItem(Object item) {
if (filtering) {
return;
}
this.item = item;
this.setting = true;
String newText = (item == null) ? StringUtils.EMPTY : item.toString();
textField.setText(newText);
this.setting = false;
}
public Object getItem() {
return this.item;
}
public void selectAll() {
textField.selectAll();
}
public void addActionListener(ActionListener l) {
textField.addActionListener(l);
}
public void removeActionListener(ActionListener l) {
textField.removeActionListener(l);
}
public void insertUpdate(DocumentEvent e) {
handleChange();
}
public void removeUpdate(DocumentEvent e) {
handleChange();
}
public void changedUpdate(DocumentEvent e) {
handleChange();
}
protected void handleChange() {
if (setting) {
return;
}
filtering = true;
((FilterableComboBoxModel) getModel()).setSelectedItem(textField.getText());
this.item = textField.getText();
setPopupVisible(true);
filtering = false;
}
}
}

15
designer_base/src/com/fr/design/gui/style/FormatPane.java

@ -9,8 +9,7 @@ import com.fr.data.core.FormatField.FormatContents;
import com.fr.design.border.UIRoundedBorder;
import com.fr.design.constants.LayoutConstants;
import com.fr.design.constants.UIConstants;
import com.fr.design.gui.icombobox.UIComboBox;
import com.fr.design.gui.icombobox.UIComboBoxRenderer;
import com.fr.design.gui.icombobox.*;
import com.fr.design.gui.ilable.UILabel;
import com.fr.design.layout.TableLayout;
import com.fr.design.layout.TableLayoutHelper;
@ -22,6 +21,8 @@ import javax.swing.*;
import javax.swing.border.Border;
import javax.swing.border.TitledBorder;
import java.awt.*;
import java.awt.event.ActionEvent;
import java.awt.event.ActionListener;
import java.awt.event.ItemEvent;
import java.awt.event.ItemListener;
import java.text.Format;
@ -51,7 +52,7 @@ public class FormatPane extends AbstractBasicStylePane {
private Format format;
private UIComboBox typeComboBox;
private UIComboBox textField;
private TextFontComboBox textField;
private UILabel sampleLabel;
private JPanel contentPane;
private JPanel txtCenterPane;
@ -89,7 +90,8 @@ public class FormatPane extends AbstractBasicStylePane {
contentPane.add(sampleLabel, BorderLayout.NORTH);
txtCenterPane = new JPanel(new BorderLayout());
textField = new UIComboBox(FormatField.getInstance().getFormatArray(getFormatContents()));
textField = new TextFontComboBox();
// textField.setItemArray(FormatField.getInstance().getFormatArray(getFormatContents()));
textField.addItemListener(textFieldItemListener);
textField.setEditable(true);
txtCenterPane.add(textField, BorderLayout.NORTH);
@ -322,9 +324,8 @@ public class FormatPane extends AbstractBasicStylePane {
cardLayout.show(centerPane, "hide");
} else {
textField.removeAllItems();
for (int i = 0; i < items.length; i++) {
textField.addItem(items[i]);
}
textField.setItemArray(items);
textField.setSelectedIndex(0);
centerPane.setPreferredSize(new Dimension(270, 65));
cardLayout.show(centerPane, "show");
}

4
designer_base/src/com/fr/design/mainframe/JSliderPane.java

@ -337,6 +337,10 @@ public class JSliderPane extends JPanel {
return this.showValue;
}
public void reset(){
this.showValSpinner.setValue(HUNDRED);
}
public static double divide(double v1, double v2, int scale) {
BigDecimal b1 = new BigDecimal(Double.toString(v1));
BigDecimal b2 = new BigDecimal(Double.toString(v2));

2
designer_base/src/com/fr/design/mainframe/JTemplate.java

@ -114,6 +114,8 @@ public abstract class JTemplate<T extends IOFile, U extends BaseUndoState<?>> ex
public abstract TargetComponent getCurrentElementCasePane();
public abstract JComponent getCurrentReportComponentPane();
// 为收集模版信息作准备
private void initForCollect() {
template.initTemplateID(); // 为新模板设置 templateID 属性

5
designer_chart/src/com/fr/design/chart/report/MapDataPane.java

@ -1,7 +1,6 @@
package com.fr.design.chart.report;
import com.fr.base.chart.chartdata.TopDefinitionProvider;
import com.fr.chart.chartdata.TopDefinition;
import com.fr.chart.chartattr.Chart;
import com.fr.chart.chartattr.ChartCollection;
import com.fr.chart.chartdata.MapMoreLayerReportDefinition;
@ -9,11 +8,11 @@ import com.fr.chart.chartdata.MapMoreLayerTableDefinition;
import com.fr.chart.chartdata.MapSingleLayerReportDefinition;
import com.fr.chart.chartdata.MapSingleLayerTableDefinition;
import com.fr.design.beans.FurtherBasicBeanPane;
import com.fr.design.dialog.BasicScrollPane;
import com.fr.design.gui.frpane.AttributeChangeListener;
import com.fr.design.gui.frpane.UIComboBoxPane;
import com.fr.design.gui.ilable.BoldFontTextLabel;
import com.fr.design.mainframe.chart.gui.data.DataContentsPane;
import com.fr.design.dialog.BasicScrollPane;
import com.fr.general.Inter;
import javax.swing.*;
@ -88,7 +87,7 @@ public class MapDataPane extends DataContentsPane {
protected void initLayout() {
this.setLayout(new BorderLayout(0, 6));
JPanel northPane = new JPanel(new FlowLayout(FlowLayout.LEFT));
northPane.add(new BoldFontTextLabel(Inter.getLocText("Map Show Type") + ":"));
northPane.add(new BoldFontTextLabel(Inter.getLocText("FR-Chart-Map_ShowWay") + ":"));
northPane.add(jcb);
this.add(northPane, BorderLayout.NORTH);
this.add(cardPane, BorderLayout.CENTER);

31
designer_chart/src/com/fr/design/chart/report/MapTableDataSinglePane.java

@ -1,27 +1,11 @@
package com.fr.design.chart.report;
import java.awt.BorderLayout;
import java.awt.Component;
import java.awt.Dimension;
import java.awt.FlowLayout;
import java.awt.event.ItemEvent;
import java.awt.event.ItemListener;
import java.util.ArrayList;
import java.util.List;
import javax.swing.JComponent;
import javax.swing.JPanel;
import javax.swing.JTable;
import javax.swing.SwingConstants;
import javax.swing.event.ChangeEvent;
import javax.swing.event.ChangeListener;
import com.fr.base.Utils;
import com.fr.chart.chartdata.MapSingleLayerTableDefinition;
import com.fr.chart.chartdata.SeriesDefinition;
import com.fr.data.impl.NameTableData;
import com.fr.design.data.tabledata.wrapper.TableDataWrapper;
import com.fr.design.beans.FurtherBasicBeanPane;
import com.fr.design.data.tabledata.wrapper.TableDataWrapper;
import com.fr.design.event.UIObserver;
import com.fr.design.event.UIObserverListener;
import com.fr.design.gui.frpane.UICorrelationPane;
@ -33,6 +17,15 @@ import com.fr.design.mainframe.chart.gui.data.DatabaseTableDataPane;
import com.fr.general.Inter;
import com.fr.stable.StringUtils;
import javax.swing.*;
import javax.swing.event.ChangeEvent;
import javax.swing.event.ChangeListener;
import java.awt.*;
import java.awt.event.ItemEvent;
import java.awt.event.ItemListener;
import java.util.ArrayList;
import java.util.List;
/**
* 单层地图时: 数据集 定义界面
*
@ -60,6 +53,10 @@ public class MapTableDataSinglePane extends FurtherBasicBeanPane<MapSingleLayerT
UILabel label = new UILabel(Inter.getLocText("Select_Data_Set") + ":", SwingConstants.RIGHT);
northPane.add(fromTableData = new DatabaseTableDataPane(label) {
@Override
protected void setBorder () {
this.setBorder(BorderFactory.createEmptyBorder());
}
@Override
protected void userEvent() {
refreshAreaNameBox();

2
designer_chart/src/com/fr/design/chart/series/PlotSeries/MapGroupExtensionPane.java

File diff suppressed because one or more lines are too long

4
designer_chart/src/com/fr/design/mainframe/chart/gui/data/DatabaseTableDataPane.java

@ -41,10 +41,12 @@ public class DatabaseTableDataPane extends BasicPane{
pane.add(reviewButton,BorderLayout.EAST);
this.add(pane,BorderLayout.CENTER);
setBorder ();
}
protected void setBorder () {
this.setBorder(BorderFactory.createEmptyBorder(0,24,0,15));
}
/**
* 返回选中的数据源.
*/

5
designer_chart/src/com/fr/design/mainframe/chart/gui/style/ChartAccColorPane.java

@ -1,6 +1,7 @@
package com.fr.design.mainframe.chart.gui.style;
import com.fr.chart.base.ChartConstants;
import com.fr.design.dialog.BasicPane;
import com.fr.design.event.UIObserver;
import com.fr.design.event.UIObserverListener;
import com.fr.design.mainframe.DesignerContext;
@ -9,11 +10,9 @@ import com.fr.design.style.color.ColorSelectConfigManager;
import com.fr.design.style.color.ColorSelectDetailPane;
import com.fr.design.style.color.ColorSelectDialog;
import com.fr.design.style.color.ColorSelectable;
import com.fr.design.dialog.BasicPane;
import javax.swing.event.ChangeEvent;
import javax.swing.event.ChangeListener;
import java.awt.*;
import java.awt.event.MouseEvent;
import java.awt.event.MouseListener;
@ -73,7 +72,7 @@ public class ChartAccColorPane extends BasicPane implements MouseListener, UIObs
}
Paint oldPaint = g2d.getPaint();
g2d.setPaint(new Color(212, 212, 216));
g2d.fillRect(0, 0, (int)bounds.getWidth(), (int)bounds.getHeight());
g2d.fillRect(0, 0, WIDTH*ROWCOUNT, WIDTH*4);
g2d.setPaint(oldPaint);
int y = 0;

21
designer_chart/src/com/fr/design/mainframe/chart/gui/style/axis/ChartCategoryPane.java

@ -1,12 +1,5 @@
package com.fr.design.mainframe.chart.gui.style.axis;
import java.awt.BorderLayout;
import java.awt.Component;
import javax.swing.BorderFactory;
import javax.swing.JPanel;
import javax.swing.JSeparator;
import com.fr.chart.chartattr.Axis;
import com.fr.chart.chartattr.Bar2DPlot;
import com.fr.chart.chartattr.CategoryAxis;
@ -15,10 +8,18 @@ import com.fr.design.gui.icheckbox.UICheckBox;
import com.fr.design.gui.style.FormatPane;
import com.fr.design.layout.TableLayout;
import com.fr.design.layout.TableLayoutHelper;
import com.fr.design.mainframe.chart.gui.style.*;
import com.fr.design.mainframe.chart.gui.style.ChartAxisLabelPane;
import com.fr.design.mainframe.chart.gui.style.ChartAxisLineStylePane;
import com.fr.design.mainframe.chart.gui.style.ChartAxisTitleNoFormulaPane;
import com.fr.design.mainframe.chart.gui.style.ChartAxisTitlePane;
import com.fr.design.mainframe.chart.gui.style.ChartAxisValueTypePane;
import com.fr.design.utils.gui.GUICoreUtils;
import com.fr.general.Inter;
import com.fr.plugin.chart.designer.component.format.FormatPaneWithOutFont;
import com.fr.stable.Constants;
import com.fr.design.utils.gui.GUICoreUtils;
import javax.swing.*;
import java.awt.*;
public class ChartCategoryPane extends ChartAxisUsePane<Axis>{
@ -46,7 +47,7 @@ public class ChartCategoryPane extends ChartAxisUsePane<Axis>{
axisValuePane = new ChartAxisValueTypePane();
axisLineStylePane = new ChartAxisLineStylePane();
formatPane = new FormatPane();
formatPane = new FormatPaneWithOutFont();
axisLabelPane = new ChartAxisLabelPane();
axisReversed = new UICheckBox(Inter.getLocText("AxisReversed"));
this.setLayout(new BorderLayout());

3
designer_chart/src/com/fr/design/mainframe/chart/gui/style/axis/ChartValuePane.java

@ -25,6 +25,7 @@ import com.fr.design.mainframe.chart.gui.style.ChartAxisTitleNoFormulaPane;
import com.fr.design.mainframe.chart.gui.style.ChartAxisTitlePane;
import com.fr.general.ComparatorUtils;
import com.fr.general.Inter;
import com.fr.plugin.chart.designer.component.format.FormatPaneWithOutFont;
import com.fr.stable.Constants;
import com.fr.stable.StringUtils;
@ -74,7 +75,7 @@ public class ChartValuePane extends ChartAxisUsePane<Axis>{
zeroPane = aliagnZero4Second();
axisReversed = new UICheckBox(Inter.getLocText("FR-Designer_AxisReversed"));
unitCombox = new UIComboBox(ChartConstants.UNIT_I18N_VALUES);
formatPane = new FormatPane();
formatPane = new FormatPaneWithOutFont();
axisLabelPane = new ChartAxisLabelPane();
dataPane = createDataDefinePane();

21
designer_chart/src/com/fr/design/mainframe/chart/gui/style/datasheet/ChartDatasheetPane.java

@ -1,18 +1,11 @@
package com.fr.design.mainframe.chart.gui.style.datasheet;
import java.awt.BorderLayout;
import java.awt.Component;
import java.awt.event.ActionEvent;
import java.awt.event.ActionListener;
import javax.swing.JPanel;
import javax.swing.JSeparator;
import com.fr.base.FRContext;
import com.fr.chart.chartattr.Chart;
import com.fr.chart.chartattr.Plot;
import com.fr.chart.chartglyph.DataSheet;
import com.fr.design.constants.LayoutConstants;
import com.fr.design.dialog.BasicScrollPane;
import com.fr.design.gui.icheckbox.UICheckBox;
import com.fr.design.gui.ilable.UILabel;
import com.fr.design.gui.style.FormatPane;
@ -21,10 +14,15 @@ import com.fr.design.layout.TableLayoutHelper;
import com.fr.design.mainframe.chart.PaneTitleConstants;
import com.fr.design.mainframe.chart.gui.style.ChartTextAttrPane;
import com.fr.design.mainframe.chart.gui.style.axis.ChartAxisPane;
import com.fr.design.dialog.BasicScrollPane;
import com.fr.design.utils.gui.GUICoreUtils;
import com.fr.general.FRFont;
import com.fr.general.Inter;
import com.fr.design.utils.gui.GUICoreUtils;
import com.fr.plugin.chart.designer.component.format.FormatPaneWithNormalType;
import javax.swing.*;
import java.awt.*;
import java.awt.event.ActionEvent;
import java.awt.event.ActionListener;
public class ChartDatasheetPane extends BasicScrollPane<Chart>{
private static final long serialVersionUID = -4854070113748783014L;
@ -48,8 +46,7 @@ public class ChartDatasheetPane extends BasicScrollPane<Chart>{
double[] rowSize = { p, p, p, p};
isDatasheetVisable = new UICheckBox(Inter.getLocText("Chart_Show_Data_Sheet"));
textAttrPane = new ChartTextAttrPane();
formatPane = new FormatPane();
formatPane.setForDataSheet();
formatPane = new FormatPaneWithNormalType();
Component[][] components = new Component[][]{
new Component[]{null,textAttrPane},
new Component[]{new JSeparator(),null},

9
designer_chart/src/com/fr/design/mainframe/chart/gui/style/series/MeterSeriesPane.java

@ -54,7 +54,14 @@ public class MeterSeriesPane extends AbstractPlotSeriesPane {
}
protected UIColorPickerPane createColorPickerPane(){
return new ColorPickerPaneWithFormula("meterString");
return new ColorPickerPaneWithFormula("meterString"){
protected double getEditAreaWidth () {
return 120;
}
protected int getColorgroupMarginLeft () {
return 20;
}
};
}

13
designer_chart/src/com/fr/design/mainframe/chart/gui/style/series/UIColorPickerPane.java

@ -186,7 +186,7 @@ public class UIColorPickerPane extends BasicPane implements UIObserver {
};
double p = TableLayout.PREFERRED;
double e = TableLayout4VanChartHelper.EDIT_AREA_WIDTH;
double e = getEditAreaWidth ();
double d = TableLayout4VanChartHelper.DESCRIPTION_AREA_WIDTH;
double[] columnSize = {d, e};
double[] rowSize = {p};
@ -209,7 +209,10 @@ public class UIColorPickerPane extends BasicPane implements UIObserver {
this.textFieldList = this.getTextFieldList();
refreshGroupPane(colors, getValueArray(number));
}
protected double getEditAreaWidth () {
return TableLayout4VanChartHelper.EDIT_AREA_WIDTH;
}
protected ArrayList getTextFieldList(){
@ -560,6 +563,10 @@ public class UIColorPickerPane extends BasicPane implements UIObserver {
return null;
}
protected int getColorgroupMarginLeft () {
return COLORGROUP_MARGIN_LEFT;
}
private LayoutManager layoutMeter = new LayoutManager() {
@Override
public void removeLayoutComponent(Component comp) {
@ -580,8 +587,8 @@ public class UIColorPickerPane extends BasicPane implements UIObserver {
public void layoutContainer(Container parent) {
upControlPane.setBounds(MARGIN_LEFT, MARGIN_TOP, UPCONTROLPANE_WIDTH, upControlPane.getPreferredSize().height + MARGIN_TOP);
stagePanel.setBounds(MARGIN_LEFT, upControlPane.getPreferredSize().height + LAYOUR_DET + MARGIN_TOP, UPCONTROLPANE_WIDTH, stagePanel.getPreferredSize().height);
colorGroup.setBounds(COLORGROUP_MARGIN_LEFT, 2 * MARGIN_TOP + upControlPane.getPreferredSize().height + stagePanel.getPreferredSize().height + 2 * LAYOUR_DET, colorGroup.getPreferredSize().width, colorGroup.getPreferredSize().height + upControlPane.getPreferredSize().height);
textGroup.setBounds(colorGroup.getPreferredSize().width + COLORGROUP_MARGIN_LEFT, upControlPane.getPreferredSize().height + stagePanel.getPreferredSize().height + 2 * LAYOUR_DET + MARGIN_TOP, textGroup.getPreferredSize().width, textGroup.getPreferredSize().height);
colorGroup.setBounds( getColorgroupMarginLeft (), 2 * MARGIN_TOP + upControlPane.getPreferredSize().height + stagePanel.getPreferredSize().height + 2 * LAYOUR_DET, colorGroup.getPreferredSize().width, colorGroup.getPreferredSize().height + upControlPane.getPreferredSize().height);
textGroup.setBounds(colorGroup.getPreferredSize().width + getColorgroupMarginLeft (), upControlPane.getPreferredSize().height + stagePanel.getPreferredSize().height + 2 * LAYOUR_DET + MARGIN_TOP, textGroup.getPreferredSize().width, textGroup.getPreferredSize().height);
}
@Override

94
designer_chart/src/com/fr/plugin/chart/custom/component/VanChartHyperLinkPane.java

@ -12,8 +12,12 @@ import com.fr.design.fun.HyperlinkProvider;
import com.fr.design.gui.controlpane.NameObjectCreator;
import com.fr.design.gui.controlpane.NameableCreator;
import com.fr.design.gui.controlpane.UIListControlPane;
import com.fr.design.gui.ibutton.UIButton;
import com.fr.design.gui.imenutable.UIMenuNameableCreator;
import com.fr.design.layout.FRGUIPaneFactory;
import com.fr.design.mainframe.DesignerContext;
import com.fr.design.module.DesignModuleFactory;
import com.fr.design.utils.gui.GUICoreUtils;
import com.fr.general.Inter;
import com.fr.general.NameObject;
import com.fr.js.EmailJavaScript;
@ -31,6 +35,10 @@ import com.fr.stable.ListMap;
import com.fr.stable.Nameable;
import com.fr.stable.bridge.StableFactory;
import javax.swing.*;
import java.awt.*;
import java.awt.event.ActionEvent;
import java.awt.event.ActionListener;
import java.util.ArrayList;
import java.util.HashMap;
import java.util.Map;
@ -116,6 +124,10 @@ public class VanChartHyperLinkPane extends UIListControlPane {
}
public void populate(Plot plot) {
//特殊处理,使用instanceof判断,处理连续弹窗问题
if (SwingUtilities.getWindowAncestor(this) instanceof JDialog) {
popupEditDialog = new HyperDialog(cardPane);
}
this.plot = plot;
HashMap paneMap = getHyperlinkMap(plot);
@ -229,4 +241,86 @@ public class VanChartHyperLinkPane extends UIListControlPane {
return null;
}
protected void popupEditDialog(Point mousePos) {
//特殊处理,处理连续弹窗情况
if (SwingUtilities.getWindowAncestor(this) instanceof JDialog) {
GUICoreUtils.centerWindow(popupEditDialog);
popupEditDialog.setVisible(true);
return;
}
super.popupEditDialog(mousePos);
}
// 点击"编辑"按钮,弹出面板
protected class HyperDialog extends JDialog {
private JComponent editPane;
private static final int WIDTH = 570;
private static final int HEIGHT = 490;
private UIButton okButton, cancelButton;
HyperDialog(JComponent pane) {
super(DesignerContext.getDesignerFrame(), true);
pane.setBorder(BorderFactory.createEmptyBorder(20, 10, 10, 10));
this.editPane = pane;
JPanel editPaneWrapper = new JPanel(new BorderLayout());
editPaneWrapper.add(editPane, BorderLayout.CENTER);
this.getContentPane().add(editPaneWrapper, BorderLayout.CENTER);
this.getContentPane().add(createControlButtonPane(), BorderLayout.SOUTH);
setSize(WIDTH, HEIGHT);
this.setVisible(false);
}
private JPanel createControlButtonPane() {
JPanel controlPane = FRGUIPaneFactory.createBorderLayout_S_Pane();
JPanel buttonsPane = new JPanel(new FlowLayout(FlowLayout.LEFT, 10, 0));
controlPane.add(buttonsPane, BorderLayout.EAST);
//确定
addOkButton(buttonsPane);
//取消
addCancelButton(buttonsPane);
controlPane.setBorder(BorderFactory.createEmptyBorder(10,0,10,0));
return controlPane;
}
private void addCancelButton(JPanel buttonsPane) {
cancelButton = new UIButton(Inter.getLocText("Cancel"));
buttonsPane.add(cancelButton);
cancelButton.addActionListener(new ActionListener() {
public void actionPerformed(ActionEvent evt) {
doCancel();
}
});
}
private void addOkButton(JPanel buttonsPane) {
okButton = new UIButton(Inter.getLocText("OK"));
buttonsPane.add(okButton);
okButton.addActionListener(new ActionListener() {
public void actionPerformed(ActionEvent evt) {
doOK();
}
});
}
public void doOK() {
saveSettings();
setVisible(false);
}
public void doCancel() {
setVisible(false);
}
}
}

27
designer_chart/src/com/fr/plugin/chart/designer/other/HyperlinkMapFactory.java

@ -12,13 +12,25 @@ import com.fr.design.chart.series.SeriesCondition.impl.ChartHyperRelateFloatLink
import com.fr.design.chart.series.SeriesCondition.impl.FormHyperlinkPane;
import com.fr.design.editor.ValueEditorPane;
import com.fr.design.editor.ValueEditorPaneFactory;
import com.fr.design.editor.editor.*;
import com.fr.design.editor.editor.BooleanEditor;
import com.fr.design.editor.editor.ConstantsEditor;
import com.fr.design.editor.editor.DateEditor;
import com.fr.design.editor.editor.DoubleEditor;
import com.fr.design.editor.editor.Editor;
import com.fr.design.editor.editor.FormulaEditor;
import com.fr.design.editor.editor.IntegerEditor;
import com.fr.design.editor.editor.TextEditor;
import com.fr.design.hyperlink.ReportletHyperlinkPane;
import com.fr.design.hyperlink.WebHyperlinkPane;
import com.fr.design.javascript.JavaScriptImplPane;
import com.fr.design.javascript.ParameterJavaScriptPane;
import com.fr.general.Inter;
import com.fr.js.*;
import com.fr.js.EmailJavaScript;
import com.fr.js.FormHyperlinkProvider;
import com.fr.js.JavaScriptImpl;
import com.fr.js.ParameterJavaScript;
import com.fr.js.ReportletHyperlink;
import com.fr.js.WebHyperlink;
import com.fr.plugin.chart.area.VanChartAreaPlot;
import com.fr.plugin.chart.bubble.BubblePlotType;
import com.fr.plugin.chart.bubble.VanChartBubblePlot;
@ -28,16 +40,16 @@ import com.fr.plugin.chart.custom.type.CustomStyle;
import com.fr.plugin.chart.drillmap.VanChartDrillMapPlot;
import com.fr.plugin.chart.funnel.VanChartFunnelPlot;
import com.fr.plugin.chart.gantt.VanChartGanttPlot;
import com.fr.plugin.chart.type.GaugeStyle;
import com.fr.plugin.chart.gauge.VanChartGaugePlot;
import com.fr.plugin.chart.heatmap.VanChartHeatMapPlot;
import com.fr.plugin.chart.line.VanChartLinePlot;
import com.fr.plugin.chart.type.MapType;
import com.fr.plugin.chart.map.VanChartMapPlot;
import com.fr.plugin.chart.multilayer.VanChartMultiPiePlot;
import com.fr.plugin.chart.scatter.VanChartScatterPlot;
import com.fr.plugin.chart.structure.VanChartStructurePlot;
import com.fr.plugin.chart.treemap.VanChartTreeMapPlot;
import com.fr.plugin.chart.type.GaugeStyle;
import com.fr.plugin.chart.type.MapType;
import com.fr.plugin.chart.wordcloud.VanChartWordCloudPlot;
import java.util.ArrayList;
@ -771,6 +783,13 @@ public class HyperlinkMapFactory {
public static class VAN_CHART extends ChartHyperRelateCellLinkPane{
}
public static class VAN_CHART_MULTICATEGORY extends ChartHyperRelateCellLinkPane{
@Override
protected ValueEditorPane getValueEditorPane() {
return getMultiCategoryEditorPane();
}
}
public static class VAN_CHART_SCATTER extends ChartHyperRelateCellLinkPane{
@Override
protected ValueEditorPane getValueEditorPane() {

6
designer_form/src/com/fr/design/mainframe/FormArea.java

@ -119,7 +119,7 @@ public class FormArea extends JComponent implements ScrollRulerComponent {
// slidePane = new UINumberSlidePane(SLIDER_MIN, SLIDER_FLOAT);
// slidePane.setPreferredSize(new Dimension(260,20));
slidePane = JFormSliderPane.getInstance();
slidePane.setPreferredSize(new Dimension(350, 20));
slidePane.setPreferredSize(new Dimension(200, 20));
JPanel resizePane = TableLayoutHelper.createCommonTableLayoutPane(new JComponent[][]{
@ -130,8 +130,8 @@ public class FormArea extends JComponent implements ScrollRulerComponent {
setWidgetsConfig();
// 先初始话滑块及对应事件,然后获取分辨率调整容器的显示大小
slidePane.setEnabled(false);
slidePane.setVisible(true);
initTransparent();
slidePane.setVisible(false);
// initTransparent();
initCalculateSize();
}

15
designer_form/src/com/fr/design/mainframe/FormParaWidgetPane.java

@ -2,6 +2,7 @@ package com.fr.design.mainframe;
import com.fr.base.BaseUtils;
import com.fr.design.ExtraDesignClassManager;
import com.fr.design.constants.UIConstants;
import com.fr.design.designer.beans.events.DesignerEditListener;
import com.fr.design.designer.beans.events.DesignerEvent;
import com.fr.design.designer.creator.XCreatorUtils;
@ -152,6 +153,7 @@ public class FormParaWidgetPane extends JPanel {
widgetPane.add(eastScrollPane);
widgetTypePopupMenu = new UIPopupMenu();
widgetTypePopupMenu.setBackground(UIConstants.SELECT_TAB);
widgetTypePopupMenu.add(widgetPane);
}
}
@ -167,6 +169,7 @@ public class FormParaWidgetPane extends JPanel {
int y = (int) Math.ceil(chartOptions.length / ((double) COMMON_CHAR_NUM)) * (widgetButtonHeight + smallGAP);
componentsPara.setPreferredSize(new Dimension(x, y));
chartTypePopupMenu = new UIPopupMenu();
chartTypePopupMenu.setBackground(UIConstants.SELECT_TAB);
chartTypePopupMenu.add(componentsPara);
}
}
@ -284,8 +287,8 @@ public class FormParaWidgetPane extends JPanel {
public void mouseClicked(MouseEvent e) {
initChartTypePopUp();
chartTypePopupMenu.show(FormParaWidgetPane.this,
(int) jSeparatorChart.getLocation().getX() + BORDER,
(int) jSeparatorChart.getLocation().getY());
(int) jSeparatorLayout.getLocation().getX() + BORDER,
(int) jSeparatorLayout.getLocation().getY());
}
});
labelPane.add(chartPopUpButton, BorderLayout.EAST);
@ -304,8 +307,8 @@ public class FormParaWidgetPane extends JPanel {
public void mouseClicked(MouseEvent e) {
initWidgetTypePopUp();
widgetTypePopupMenu.show(FormParaWidgetPane.this,
(int) jSeparatorLayout.getLocation().getX() + BORDER,
(int) jSeparatorLayout.getLocation().getY());
(int) jSeparatorChart.getLocation().getX() + BORDER,
(int) jSeparatorChart.getLocation().getY());
}
});
@ -316,7 +319,9 @@ public class FormParaWidgetPane extends JPanel {
private int calculateWidgetWindowRowNum() {
//向上取整
int rowNum = (int) Math.ceil((double) predifinedwidgeList.size() / (double) preWidgetShowMaxNum);
int eastRowNum = (int) Math.ceil((double) predifinedwidgeList.size() / (double) preWidgetShowMaxNum);
int westRowNum = (int) Math.ceil((double) loadWidgetOptions().length / (double) commonWidgetNum);
int rowNum = Math.max(eastRowNum, westRowNum);
rowNum = Math.max(rowNum, 2);
rowNum = Math.min(rowNum, preWidgetShowMaxRow);
return rowNum;

5
designer_form/src/com/fr/design/mainframe/JForm.java

@ -103,6 +103,11 @@ public class JForm extends JTemplate<Form, FormUndoState> implements BaseJForm {
return elementCaseDesign.getEditingElementCasePane();
}
@Override
public JComponent getCurrentReportComponentPane() {
return null;
}
public int getMenuState() {
return DesignState.JFORM;

Loading…
Cancel
Save