Examples of canEvalLength()


Examples of org.foray.fotree.value.PropertyValue.canEvalLength()

            }
            }
            if (length == null) {
                return 0;
            }
            if (length.canEvalLength()) {
                return length.evalLength(fobj.traitFontSize(context));
            }
            if (length.canEvalPercentage()) {
                final float percent = length.evalPercentage();
                return Math.round(context.ipdAncestorBlockOrRa() * percent
 
View Full Code Here

Examples of org.foray.fotree.value.PropertyValue.canEvalLength()

            lengthRange = new DtLengthRange(true, lengthMin, lengthOpt,
                    lengthMax);
        }

        final PropertyValue pv = standardParse(fobj, value);
        if (! pv.canEvalLength()
                && ! pv.canEvalPercentage()) {
            throw unexpectedValue(value, fobj);
        }
        if (subPropertyName.equals("minimum")) {
            lengthRange.setLengthMinimum(pv);
View Full Code Here

Examples of org.foray.fotree.value.PropertyValue.canEvalLength()

            return pv;
        }
        if (pv instanceof DtLengthRange) {
            return pv;
        }
        if (pv.canEvalLength()) {
            return pv;
        }
        throw unexpectedValue(value, fobj);
    }
View Full Code Here

Examples of org.foray.fotree.value.PropertyValue.canEvalLength()

            return pv;
        }
        if (pv.canEvalPercentage()) {
            return pv;
        }
        if (pv.canEvalLength()) {
            return pv;
        }
        throw unexpectedValue(value, fobj);
    }
View Full Code Here

Examples of org.foray.fotree.value.PropertyValue.canEvalLength()

            return pv;
        }
        if (pv.canEvalPercentage()) {
            return pv;
        }
        if (pv.canEvalLength()) {
            return pv;
        }
        throw unexpectedValue(value, fobj);
    }
View Full Code Here

Examples of org.foray.fotree.value.PropertyValue.canEvalLength()

     * @throws PropertyException For an invalid property value.
     */
    private PropertyValue createPropertyValue(final FObj fobj,
            final String value) throws PropertyException {
        final PropertyValue pv = this.standardParse(fobj, value);
        if (pv.canEvalLength()) {
            return pv;
        }
        throw unexpectedValue(value, fobj);
    }

View Full Code Here

Examples of org.foray.fotree.value.PropertyValue.canEvalLength()

            return pv;
        }
        if (pv.canEvalPercentage()) {
            return pv;
        }
        if (pv.canEvalLength()) {
            return pv;
        }
        throw unexpectedValue(value, fobj);
    }
View Full Code Here

Examples of org.foray.fotree.value.PropertyValue.canEvalLength()

            final String value) throws PropertyException {
        final PropertyValue pv = standardParse(fobj, value);
        if (pv.canEvalKeyword()) {
            return pv;
        }
        if (pv.canEvalLength()) {
            return pv;
        }
        throw unexpectedValue(value, fobj);
    }
View Full Code Here

Examples of org.foray.fotree.value.PropertyValue.canEvalLength()

        final ValueCollection collection = new ValueCollection();
        while (st.hasMoreTokens()) {
            final String token = st.nextToken();
            final PropertyValue parsedToken = this.standardParse(fobj, value,
                    null);
            if (parsedToken.canEvalLength()
                    || parsedToken.canEvalPercentage()) {
                collection.addItem(parsedToken);
            } else {
                throw this.unexpectedValue(token, fobj);
            }
View Full Code Here

Examples of org.foray.fotree.value.PropertyValue.canEvalLength()

                base = context.widthContainingBlock();
            }
            final float percent = value.evalPercentage();
            return Math.round(base * percent / WKConstants.PERCENT_CONVERSION);
        }
        if (value.canEvalLength()) {
            return this.convertValueToLength(value, fobj, context);
        }
        throw this.unexpectedRetrieval();
    }

View Full Code Here
TOP
Copyright © 2018 www.massapi.com. 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.