Package com.volantis.mcs.themes.values

Examples of com.volantis.mcs.themes.values.ShorthandValue


    }

    public IterationAction next(ShorthandValue subsetValue) {

        StyleShorthand shorthand = subsetValue.getShorthand();
        ShorthandValue shorthandValue = properties.getShorthandValue(shorthand);
        if (subsetValue.equals(shorthandValue)) {
            // the shorthand is in both sets with the same
            // value. In this case, leave the subset
            // as it is.
        } else {
View Full Code Here


     * @param values
     * @param priority
     */
    protected ShorthandValue createShorthandValue(
            StyleValue[] values, Priority priority) {
        return new ShorthandValue(shorthand, values, priority);
    }
View Full Code Here

            MutableStylePropertySet requiredForShorthand) {

        StyleValue[] values = getShorthandValues(requiredForIndividual,
                requiredForShorthand);
        Priority priority = getShorthandPriority();
        ShorthandValue shorthandValue = createShorthandValue(values, priority);

        outputValues.setShorthandValue(shorthandValue);
    }
View Full Code Here

                if (value != UnknownFontValue.INSTANCE && value != null) {
                    values[i] = value;
                }
            }

            ShorthandValue shorthandValue = new FontShorthandValue(
                    StyleShorthands.FONT, systemFont, values,
                    shorthandPriority);
            outputValues.setShorthandValue(shorthandValue);
        } else {
            standardAnalyzer.updateShorthand(outputValues,
View Full Code Here

    public void updateShorthand(
            MutableStyleProperties outputValues,
            MutableStylePropertySet requiredForIndividual,
            MutableStylePropertySet requiredForShorthand) {

        ShorthandValue shorthandValue = createShorthandValue();
        outputValues.setShorthandValue(shorthandValue);
    }
View Full Code Here

        }

        StyleValue[] values = new StyleValue[characteristicCount];
        System.arraycopy(characteristics, 0, values, 0, characteristicCount);

        return new ShorthandValue(StyleShorthands.BORDER, values,
                shorthandPriority);
    }
View Full Code Here

        PropertyValues inputValues = helper.parseDeclarations(css);

        optimizer.optimize(TargetEntity.ELEMENT, inputValues, outputValues,
                deviceValuesMock);

        ShorthandValue shorthandValue =
                outputValues.getShorthandValue(StyleShorthands.MARGIN);

        assertNotNull("Shorthand value should be set", shorthandValue);

        Priority priority = shorthandValue.getPriority();
        assertEquals("Priority mismatch", expectedPriority, priority);

        assertEquals("Count mismatch", expectedValues.length,
                shorthandValue.getCount());

        for (int i = 0; i < expectedValues.length; i++) {
            StyleValue expectedValue = expectedValues[i];
            StyleValue value = shorthandValue.getValue(i);
            assertEquals("Value " + i + " mismatch", expectedValue, value);
        }

        // todo check that the other properties are cleared.
    }
View Full Code Here

TOP

Related Classes of com.volantis.mcs.themes.values.ShorthandValue

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.