Package org.w3c.dom.css

Examples of org.w3c.dom.css.CSSValue


            for (int i = 0; i < items.length; i++) {
                nitems[i] = items[i];
            }
            items = nitems;
        }
        CSSValue result = items[index];
        if (result == null) {
            items[index] = result = new ListComponent(index);
        }
        return result;
    }
View Full Code Here


    /**
     * Gets the CSS value associated with the given property.
     */
    protected CSSValue getCSSValue(String name) {
        CSSValue result = null;
        if (values != null) {
            result = (CSSValue)values.get(name);
        }
        if (result == null) {
            result = createCSSValue(name);
View Full Code Here

        Map refs = new HashMap();
        for (;;) {
        CSSOMReadOnlyStyleDeclaration decl;
        decl = CSSUtilities.getComputedStyle(paintElement);

        CSSValue opacityVal = decl.getPropertyCSSValueInternal
            (BATIK_EXT_SOLID_OPACITY_PROPERTY);
        if (opacityVal != null) {
            float attr = PaintServer.convertOpacity(opacityVal);
                return (opacity * attr);
            }
View Full Code Here

        Map refs = new HashMap();
        for (;;) {
            CSSOMReadOnlyStyleDeclaration decl;
            decl = CSSUtilities.getComputedStyle(paintElement);

            CSSValue colorDef;
            colorDef = decl.getPropertyCSSValueInternal
                (BATIK_EXT_SOLID_COLOR_PROPERTY);
            if (colorDef != null) {
                if (colorDef.getCssValueType() ==
                    CSSValue.CSS_PRIMITIVE_VALUE) {
            CSSPrimitiveValue v = (CSSPrimitiveValue)colorDef;
                    return PaintServer.convertColor
                        (v.getRGBColorValue(), opacity);
        } else {
View Full Code Here

        AbstractViewCSS viewCss = CSSUtilities.getViewCSS(element);
        CSSOMReadOnlyStyleDeclaration styleDecl = viewCss.getCascadedStyle(element, null);

        // determine if text-decoration was explicity set on this element
        CSSValue cssVal = styleDecl.getLocalPropertyCSSValue(CSS_TEXT_DECORATION_PROPERTY);
        if (cssVal == null) {
            // not explicitly set so return the copy of the parent's decoration
            return textDecoration;
        }

        short t = cssVal.getCssValueType();

        if (t == CSSValue.CSS_VALUE_LIST) {

            // first check to see if its a valid list,
            // ie. if it contains none then that is the only element
View Full Code Here

        }

        // 'stroke-width' property
        CSSStyleDeclaration decl
            = CSSUtilities.getComputedStyle(paintedElement);
        CSSValue v = decl.getPropertyCSSValue(CSS_STROKE_WIDTH_PROPERTY);
        float strokeWidth = UnitProcessor.cssOtherLengthToUserSpace
            (v, CSS_STROKE_WIDTH_PROPERTY, uctx);

        // 'markerUnits' attribute - default is 'strokeWidth'
        short unitsType;
View Full Code Here

                                              BridgeContext ctx) {

        CSSOMReadOnlyStyleDeclaration decl
            = CSSUtilities.getComputedStyle(paintedElement);

        CSSValue v;

        v = decl.getPropertyCSSValueInternal(CSS_MARKER_START_PROPERTY);
        Marker startMarker
            = convertMarker(paintedElement, (CSSPrimitiveValue)v, ctx);
View Full Code Here

            CSSUtilities.getComputedStyle(strokedElement);
        // 'stroke-opacity'
        float opacity = convertOpacity
            (decl.getPropertyCSSValueInternal(CSS_STROKE_OPACITY_PROPERTY));
        // 'stroke'
        CSSValue paintDef
            = decl.getPropertyCSSValueInternal(CSS_STROKE_PROPERTY);

        return convertPaint(strokedElement,
                            strokedNode,
                            paintDef,
View Full Code Here

            CSSUtilities.getComputedStyle(filledElement);
        // 'fill-opacity'
        float opacity = convertOpacity
            (decl.getPropertyCSSValueInternal(CSS_FILL_OPACITY_PROPERTY));
        // 'fill'
        CSSValue paintDef = decl.getPropertyCSSValueInternal(CSS_FILL_PROPERTY);

        return convertPaint(filledElement,
                            filledNode,
                            paintDef,
                            opacity,
View Full Code Here

                                              opacity,
                                              ctx);
                if (paint == null) { // no paint found
                    CSSOMReadOnlyStyleDeclaration decl =
                        CSSUtilities.getComputedStyle(paintedElement);
                    CSSValue v
                        = decl.getPropertyCSSValueInternal(CSS_COLOR_PROPERTY);
                    paint =  convertColor
                        (((CSSPrimitiveValue)v).getRGBColorValue(), opacity);
                }
                return paint;
View Full Code Here

TOP

Related Classes of org.w3c.dom.css.CSSValue

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.