Package org.apache.flex.forks.batik.dom.svg

Examples of org.apache.flex.forks.batik.dom.svg.SVGOMLineElement


    protected void buildShape(BridgeContext ctx,
                              Element e,
                              ShapeNode shapeNode) {

        try {
            SVGOMLineElement le = (SVGOMLineElement) e;

            // 'x1' attribute - default is 0
            AbstractSVGAnimatedLength _x1 =
                (AbstractSVGAnimatedLength) le.getX1();
            float x1 = _x1.getCheckedValue();

            // 'y1' attribute - default is 0
            AbstractSVGAnimatedLength _y1 =
                (AbstractSVGAnimatedLength) le.getY1();
            float y1 = _y1.getCheckedValue();

            // 'x2' attribute - default is 0
            AbstractSVGAnimatedLength _x2 =
                (AbstractSVGAnimatedLength) le.getX2();
            float x2 = _x2.getCheckedValue();

            // 'y2' attribute - default is 0
            AbstractSVGAnimatedLength _y2 =
                (AbstractSVGAnimatedLength) le.getY2();
            float y2 = _y2.getCheckedValue();

            shapeNode.setShape(new Line2D.Float(x1, y1, x2, y2));
        } catch (LiveAttributeException ex) {
            throw new BridgeException(ctx, ex);
View Full Code Here

TOP

Related Classes of org.apache.flex.forks.batik.dom.svg.SVGOMLineElement

Copyright © 2018 www.massapicom. All rights reserved.
All source code are property of their respective owners. Java is a trademark of Sun Microsystems, Inc and owned by ORACLE Inc. Contact coftware#gmail.com.