|
|
|
@ -1,14 +1,16 @@
|
|
|
|
|
package com.fr.design.report; |
|
|
|
|
|
|
|
|
|
import com.fr.base.BaseFormula; |
|
|
|
|
import com.fr.base.iofile.attr.WatermarkAttr; |
|
|
|
|
import com.fr.design.dialog.BasicPane; |
|
|
|
|
import com.fr.design.formula.TinyFormulaPane; |
|
|
|
|
import com.fr.design.editor.editor.FormulaEditor; |
|
|
|
|
import com.fr.design.gui.icombobox.UIComboBox; |
|
|
|
|
import com.fr.design.gui.icontainer.UIScrollPane; |
|
|
|
|
import com.fr.design.gui.ilable.UILabel; |
|
|
|
|
import com.fr.design.gui.ispinner.UISpinner; |
|
|
|
|
import com.fr.design.gui.ispinner.UnsignedIntUISpinner; |
|
|
|
|
import com.fr.design.gui.style.FRFontPane; |
|
|
|
|
import com.fr.design.i18n.Toolkit; |
|
|
|
|
import com.fr.design.layout.FRGUIPaneFactory; |
|
|
|
|
import com.fr.design.layout.TableLayout; |
|
|
|
|
import com.fr.design.layout.TableLayoutHelper; |
|
|
|
@ -50,7 +52,7 @@ public class WatermarkPane extends BasicPane {
|
|
|
|
|
// 水印预览面板
|
|
|
|
|
private WatermarkPreviewPane watermarkPreviewPane; |
|
|
|
|
// 文字
|
|
|
|
|
private TinyFormulaPane formulaPane; |
|
|
|
|
private FormulaEditor formulaPane; |
|
|
|
|
// 字号
|
|
|
|
|
private UIComboBox fontSizeComboBox; |
|
|
|
|
//横向间距
|
|
|
|
@ -119,16 +121,16 @@ public class WatermarkPane extends BasicPane {
|
|
|
|
|
return watermark; |
|
|
|
|
} |
|
|
|
|
|
|
|
|
|
public TinyFormulaPane getFormulaPane() { |
|
|
|
|
public FormulaEditor getFormulaPane() { |
|
|
|
|
return formulaPane; |
|
|
|
|
} |
|
|
|
|
|
|
|
|
|
public void setFormulaPane(TinyFormulaPane formulaPane) { |
|
|
|
|
public void setFormulaPane(FormulaEditor formulaPane) { |
|
|
|
|
this.formulaPane = formulaPane; |
|
|
|
|
} |
|
|
|
|
|
|
|
|
|
protected UIScrollPane initRightPane() { |
|
|
|
|
formulaPane = new TinyFormulaPane(); |
|
|
|
|
formulaPane = new FormulaEditor(Toolkit.i18nText("Fine-Design_Report_Parameter_Formula")); |
|
|
|
|
fontSizeComboBox = new UIComboBox(FRFontPane.FONT_SIZES); |
|
|
|
|
fontSizeComboBox.setEditable(true); |
|
|
|
|
horizontalGapSpinner = new UnsignedIntUISpinner(100, Integer.MAX_VALUE, 1, 200); |
|
|
|
@ -228,7 +230,7 @@ public class WatermarkPane extends BasicPane {
|
|
|
|
|
} |
|
|
|
|
|
|
|
|
|
private void populateFourmula(String formula) { |
|
|
|
|
this.formulaPane.populateBean(formula); |
|
|
|
|
this.formulaPane.setValue(BaseFormula.createFormulaBuilder().build(formula)); |
|
|
|
|
this.formulaPane.getUITextField().getDocument() |
|
|
|
|
.addDocumentListener(new DocumentListener() { |
|
|
|
|
@Override |
|
|
|
|