org.jfree.layouting.layouter.style

Class CSSValueResolverUtility

public class CSSValueResolverUtility extends Object

Creation-Date: 15.12.2005, 11:29:22

Author: Thomas Morgner

Field Summary
static doubleDEFAULT_X_HEIGHT_FACTOR
Method Summary
static CSSNumericValueconvertLength(CSSValue rawValue, LayoutContext context, OutputProcessorMetaData metaData)
static CSSNumericValueconvertLength(CSSNumericValue value, CSSNumericType type)
static doubleconvertLengthToDouble(CSSValue rawValue)
static doubleconvertLengthToDouble(CSSValue rawValue, LayoutContext context, OutputProcessorMetaData metaData)
Returns the length in point as a double primitive value.
static longconvertLengthToLong(CSSValue rawValue, LayoutContext context, OutputProcessorMetaData metaData)
Returns the length in point as a double primitive value.
static CSSNumericValuegetLength(CSSValue value)
static CSSNumericValuegetLength(CSSValue value, CSSNumericValue percentageBase)
static doublegetNumericValue(CSSValue value, double defaultValue)
static booleanisAbsoluteValue(CSSNumericValue value)
static booleanisLengthValue(CSSNumericValue value)
static booleanisURI(CSSValue value)

Field Detail

DEFAULT_X_HEIGHT_FACTOR

public static final double DEFAULT_X_HEIGHT_FACTOR

Method Detail

convertLength

public static CSSNumericValue convertLength(CSSValue rawValue, LayoutContext context, OutputProcessorMetaData metaData)

convertLength

public static CSSNumericValue convertLength(CSSNumericValue value, CSSNumericType type)

convertLengthToDouble

public static double convertLengthToDouble(CSSValue rawValue)

convertLengthToDouble

public static strictfp double convertLengthToDouble(CSSValue rawValue, LayoutContext context, OutputProcessorMetaData metaData)
Returns the length in point as a double primitive value. Be aware that using double-values is not very accurate.

Parameters: rawValue context metaData

Returns:

convertLengthToLong

public static strictfp long convertLengthToLong(CSSValue rawValue, LayoutContext context, OutputProcessorMetaData metaData)
Returns the length in point as a double primitive value.

Parameters: rawValue context metaData

Returns:

getLength

public static CSSNumericValue getLength(CSSValue value)

getLength

public static CSSNumericValue getLength(CSSValue value, CSSNumericValue percentageBase)

getNumericValue

public static double getNumericValue(CSSValue value, double defaultValue)

isAbsoluteValue

public static boolean isAbsoluteValue(CSSNumericValue value)

isLengthValue

public static boolean isLengthValue(CSSNumericValue value)

isURI

public static boolean isURI(CSSValue value)