Search in sources :

Example 6 with XMLComponent

use of com.ramussoft.report.editor.xml.components.XMLComponent in project ramus by Vitaliy-Yakovchuk.

the class AttributesEditorModel method setValueAt.

@Override
public void setValueAt(Object aValue, int rowIndex, int columnIndex) {
    Attribute attribute = attributes.get(rowIndex);
    boolean set = false;
    for (XMLComponent component : components) {
        List<Attribute> list = component.getXMLAttributes();
        int i = list.indexOf(attribute);
        if (i >= 0) {
            component.setXMLAttribute(list.get(i), aValue);
            set = true;
        }
    }
    if (set)
        editorView.save();
    reportEditor.repaint();
}
Also used : XMLComponent(com.ramussoft.report.editor.xml.components.XMLComponent)

Example 7 with XMLComponent

use of com.ramussoft.report.editor.xml.components.XMLComponent in project ramus by Vitaliy-Yakovchuk.

the class AttributesEditorModel method setAttributes.

public void setAttributes(List<XMLComponent> components, XMLReportEditorView editorView) {
    this.components = components;
    this.reportEditor = editorView.getEditorView().getReportEditor();
    this.editorView = editorView;
    attributes = new ArrayList<Attribute>();
    for (XMLComponent component : this.components) {
        for (Attribute attribute : component.getXMLAttributes()) {
            if (attributes.indexOf(attribute) < 0) {
                attributes.add(attribute);
            }
        }
    }
    fireTableDataChanged();
}
Also used : XMLComponent(com.ramussoft.report.editor.xml.components.XMLComponent)

Example 8 with XMLComponent

use of com.ramussoft.report.editor.xml.components.XMLComponent in project ramus by Vitaliy-Yakovchuk.

the class XMLDiagram method storeToXML.

public void storeToXML(ReportSaveXMLReader reportSaveXMLReader) throws SAXException {
    for (QBounds bounds : yBounds) {
        XMLComponent component = (XMLComponent) getComponent(bounds);
        component.storeToXML(reportSaveXMLReader);
    }
}
Also used : QBounds(com.ramussoft.reportgef.model.QBounds) XMLComponent(com.ramussoft.report.editor.xml.components.XMLComponent)

Aggregations

XMLComponent (com.ramussoft.report.editor.xml.components.XMLComponent)8 QBounds (com.ramussoft.reportgef.model.QBounds)6 Component (com.ramussoft.reportgef.Component)4 Bounds (com.ramussoft.reportgef.model.Bounds)4 GradientPaint (java.awt.GradientPaint)4 Table (com.ramussoft.report.editor.xml.components.Table)3 TableColumn (com.ramussoft.report.editor.xml.components.TableColumn)3 Point2D (java.awt.geom.Point2D)3 ArrayList (java.util.ArrayList)3 Dimension2DImpl (com.ramussoft.reportgef.model.Dimension2DImpl)2 Dimension (java.awt.Dimension)1 SAXException (org.xml.sax.SAXException)1