org.jfree.layouting.layouter.style

Class CSSValueResolverUtility


public class CSSValueResolverUtility
extends java.lang.Object

Creation-Date: 15.12.2005, 11:29:22
Author:
Thomas Morgner

Field Summary

static double
DEFAULT_X_HEIGHT_FACTOR

Method Summary

static CSSNumericValue
convertLength(CSSNumericValue value, CSSNumericType type)
static CSSNumericValue
convertLength(CSSValue rawValue, LayoutContext context, OutputProcessorMetaData metaData)
static double
convertLengthToDouble(CSSValue rawValue)
static strictfp
double convertLengthToDouble(CSSValue rawValue, LayoutContext context, OutputProcessorMetaData metaData)
Returns the length in point as a double primitive value.
static CSSNumericValue
getLength(CSSValue value)
static CSSNumericValue
getLength(CSSValue value, CSSNumericValue percentageBase)
static double
getNumericValue(CSSValue value, double defaultValue)
static boolean
isAbsoluteValue(CSSNumericValue value)
static boolean
isLengthValue(CSSNumericValue value)
static boolean
isURI(CSSValue value)
static strictfp
long convertLengthToLong(CSSValue rawValue, LayoutContext context, OutputProcessorMetaData metaData)
Returns the length in point as a double primitive value.

Field Details

DEFAULT_X_HEIGHT_FACTOR

public static final double DEFAULT_X_HEIGHT_FACTOR
Field Value:
0.0

Method Details

convertLength

public static CSSNumericValue convertLength(CSSNumericValue value,
                                            CSSNumericType type)

convertLength

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

convertLengthToDouble

public static double convertLengthToDouble(CSSValue rawValue)

double 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:

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)

long 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: