Package org.w3c.dom.svg

Examples of org.w3c.dom.svg.SVGRect


                 "",null);
        }
       
        final SVGTextContent context = (SVGTextContent)svgelt.getSVGContext();

        return new SVGRect() {
                public float getX() {
                    return (float)context.getExtentOfChar(charnum).getX();
                }
                public void setX(float x) throws DOMException {
                    throw svgelt.createDOMException
View Full Code Here


     * To implement {@link
     * org.w3c.dom.svg.SVGLocatable#getBBox()}.
     */
    public static SVGRect getBBox(Element elt) {
        final SVGOMElement svgelt = (SVGOMElement)elt;
        return new SVGRect() {
                public float getX() {
                    return (float)svgelt.getSVGContext().getBBox().getX();
                }
                public void setX(float x) throws DOMException {
                    throw svgelt.createDOMException
View Full Code Here

     * To implement {@link
     * org.w3c.dom.svg.SVGLocatable#getBBox()}.
     */
    public static SVGRect getBBox(Element elt) {
        final SVGOMElement svgelt = (SVGOMElement)elt;
        return new SVGRect() {
                public float getX() {
                    return (float)svgelt.getSVGContext().getBBox().getX();
                }
                public void setX(float x) throws DOMException {
                    throw svgelt.createDOMException
View Full Code Here

        final SVGOMElement svgelt = (SVGOMElement)elt;
        SVGContext svgctx = svgelt.getSVGContext();
        if (svgctx == null) return null;
        if (svgctx.getBBox() == null) return null;

        return new SVGRect() {
                public float getX() {
                    return (float)svgelt.getSVGContext().getBBox().getX();
                }
                public void setX(float x) throws DOMException {
                    throw svgelt.createDOMException
View Full Code Here

        }
       
        final SVGTextContent context = (SVGTextContent)svgelt.getSVGContext();
        Rectangle2D r2d = getExtent(svgelt, context, charnum);
           
        return new SVGRect() {
                public float getX() {
                    return (float)SVGTextContentSupport.getExtent
                        (svgelt, context, charnum).getX();
                }
                public void setX(float x) throws DOMException {
View Full Code Here

                 "",null);
        }
       
        final SVGTextContent context = (SVGTextContent)svgelt.getSVGContext();
       
        return new SVGRect() {
                public float getX() {
                    return (float)SVGTextContentSupport.getExtent
                        (svgelt, context, charnum).getX();
                }
                public void setX(float x) throws DOMException {
View Full Code Here

        final SVGOMElement svgelt = (SVGOMElement)elt;
        SVGContext svgctx = svgelt.getSVGContext();
        if (svgctx == null) return null;
        if (svgctx.getBBox() == null) return null;

        return new SVGRect() {
                public float getX() {
                    return (float)svgelt.getSVGContext().getBBox().getX();
                }
                public void setX(float x) throws DOMException {
                    throw svgelt.createDOMException
View Full Code Here

    /**
     * Returns the base value of the attribute as an {@link AnimatableValue}.
     */
    public AnimatableValue getUnderlyingValue(AnimationTarget target) {
        SVGRect r = getBaseVal();
        return new AnimatableRectValue
            (target, r.getX(), r.getY(), r.getWidth(), r.getHeight());
    }
View Full Code Here

        final SVGOMElement svgelt = (SVGOMElement)elt;
        SVGContext svgctx = svgelt.getSVGContext();
        if (svgctx == null) return null;
        if (svgctx.getBBox() == null) return null;

        return new SVGRect() {
                public float getX() {
                    return (float)svgelt.getSVGContext().getBBox().getX();
                }
                public void setX(float x) throws DOMException {
                    throw svgelt.createDOMException
View Full Code Here

        if (!((SVGOMAnimatedRect) aViewBox).isSpecified()) {
            // no viewBox specified
            return new AffineTransform();
        }
        SVGRect viewBox = aViewBox.getAnimVal();
        float[] vb = new float[] { viewBox.getX(), viewBox.getY(),
                                   viewBox.getWidth(), viewBox.getHeight() };

        return getPreserveAspectRatioTransform(e, vb, w, h, aPAR, ctx);
    }
View Full Code Here

TOP

Related Classes of org.w3c.dom.svg.SVGRect

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.