Class CSS20Attribute
java.lang.Object
com.adobe.fontengine.inlineformatting.css20.CSS20Attribute
This class holds the CSS attributes that can be used to tag an
AttributedRun
. Objects
of this class are used as the value entries of the ElementAttribute.CSS20Attribute
tag.
Concurrency
Instances of this class are immutable after construction and contain no mutable static data. Therefore, they are threadsafe.-
Nested Class Summary
Nested ClassesModifier and TypeClassDescriptionstatic final class
This class provides an enumeration of the possible values for the CSS Stretch attribute.static final class
This class provides an enumeration of the possible values for the CSS Style attribute.static final class
This class provides an enumeration of the possible values for the CSS Variant attribute.static final class
This class provides an enumeration of the possible values for the CSS Weight attribute. -
Constructor Summary
ConstructorsConstructorDescriptionCSS20Attribute
(CSS20Attribute properties) Copy constructor.CSS20Attribute
(String[] familyNames, CSS20Attribute.CSSStyleValue style, CSS20Attribute.CSSVariantValue variant, CSS20Attribute.CSSStretchValue stretch, CSS20Attribute.CSSWeightValue weight, double pointSize) Constructor.CSS20Attribute
(String[] familyNames, CSS20Attribute.CSSStyleValue style, CSS20Attribute.CSSVariantValue variant, CSS20Attribute.CSSStretchValue stretch, CSS20Attribute.CSSWeightValue weight, double pointSize, double opticalSize) Constructor. -
Method Summary
-
Constructor Details
-
CSS20Attribute
public CSS20Attribute(String[] familyNames, CSS20Attribute.CSSStyleValue style, CSS20Attribute.CSSVariantValue variant, CSS20Attribute.CSSStretchValue stretch, CSS20Attribute.CSSWeightValue weight, double pointSize, double opticalSize) Constructor. It is highly recommended that theString
objects have had thejava.lang.String.intern()
method called on them. This will greatly improve the performance of the formatting operations.- Parameters:
familyNames
- array of the font family names - this must not benull
style
- the font stylevariant
- the font variantstretch
- the font stretchweight
- the font weightpointSize
- the point size (this must be equal to or greater than zero)opticalSize
- the optical size used for selecting optical font variants
-
CSS20Attribute
public CSS20Attribute(String[] familyNames, CSS20Attribute.CSSStyleValue style, CSS20Attribute.CSSVariantValue variant, CSS20Attribute.CSSStretchValue stretch, CSS20Attribute.CSSWeightValue weight, double pointSize) Constructor. This is a convenience constructor that assumes that the optical size is equal to the point size. This is likely to the be the case for most uses. It is highly recommended that theString
objects have had thejava.lang.String.intern()
method called on them. This will greatly improve the performance of the formatting operations.- Parameters:
familyNames
- array of the font family names - this must not benull
style
- the font stylevariant
- the font variantstretch
- the font stretchweight
- the font weightpointSize
- the point size (this must be equal to or greater than zero)
-
CSS20Attribute
Copy constructor.- Parameters:
properties
-
-
-
Method Details
-
getFamilyNamesList
- Returns:
- - the familyNames.
-
getFamilyNames
-
getStyle
- Returns:
- - the style.
-
getWeight
public int getWeight()- Returns:
- - the weight after resolving for "bolder" and "lighter".
-
getVariant
- Returns:
- - the variant.
-
getStretch
- Returns:
- - the stretch.
-
getPointSize
public double getPointSize()- Returns:
- - the point size.
-
getOpticalSize
public double getOpticalSize()- Returns:
- - the optical size.
-
toString
-