Package ro.sync.exml.view.graphics
Enum TextAttribute
- java.lang.Object
-
- java.lang.Enum<TextAttribute>
-
- ro.sync.exml.view.graphics.TextAttribute
-
- All Implemented Interfaces:
java.io.Serializable
,java.lang.Comparable<TextAttribute>
@API(type=EXTENDABLE, src=PRIVATE) public enum TextAttribute extends java.lang.Enum<TextAttribute>
Constants for theAttributedString
attributes. Similar to theTextAttribute
class.
-
-
Enum Constant Summary
Enum Constants Enum Constant Description FONT
Specifies a font for a text interval.FOREGROUND
The foreground color for a piece ofAttributedString
.POSTURE
The font posture (like italic, regular)POSTURE_OBLIQUE
The standard italic posture value.POSTURE_REGULAR
The standard posture value, upright.RELATIVE_SIZE
The relative size of the fontRELATIVE_SIZE_SMALL
A value for the relative size.RUN_DIRECTION
Attribute key for the run direction of the line.RUN_DIRECTION_LTR
Left-to-right run direction.RUN_DIRECTION_RTL
Right-to-left run direction.STRIKETHROUGH
Strike throughUNDERLINE
Underline.WEIGHT
The font weight ofAttributedString
.WEIGHT_BOLD
Value for the weight.
-
Method Summary
All Methods Static Methods Concrete Methods Modifier and Type Method Description static TextAttribute
valueOf(java.lang.String name)
Returns the enum constant of this type with the specified name.static TextAttribute[]
values()
Returns an array containing the constants of this enum type, in the order they are declared.
-
-
-
Enum Constant Detail
-
FOREGROUND
public static final TextAttribute FOREGROUND
The foreground color for a piece ofAttributedString
.
-
WEIGHT
public static final TextAttribute WEIGHT
The font weight ofAttributedString
.
-
WEIGHT_BOLD
public static final TextAttribute WEIGHT_BOLD
Value for the weight.
-
POSTURE
public static final TextAttribute POSTURE
The font posture (like italic, regular)
-
POSTURE_REGULAR
public static final TextAttribute POSTURE_REGULAR
The standard posture value, upright. This is the default value forPOSTURE
.- See Also:
POSTURE
-
POSTURE_OBLIQUE
public static final TextAttribute POSTURE_OBLIQUE
The standard italic posture value.- See Also:
POSTURE
-
RELATIVE_SIZE
public static final TextAttribute RELATIVE_SIZE
The relative size of the font
-
RELATIVE_SIZE_SMALL
public static final TextAttribute RELATIVE_SIZE_SMALL
A value for the relative size. Imposes a smaller size for the font.- See Also:
RELATIVE_SIZE
-
RUN_DIRECTION
public static final TextAttribute RUN_DIRECTION
Attribute key for the run direction of the line. Values are instances ofBoolean
. The default value is null, which indicates that the standard Bidi algorithm for determining run direction should be used with the valueBidi.DIRECTION_DEFAULT_LEFT_TO_RIGHT
.The constants
RUN_DIRECTION_RTL
andRUN_DIRECTION_LTR
are provided.This determines the value passed to the
Bidi
constructor to select the primary direction of the text in the paragraph.Note: This attribute should have the same value for all the text in a paragraph, otherwise the behavior is undetermined.
- See Also:
Bidi
-
RUN_DIRECTION_LTR
public static final TextAttribute RUN_DIRECTION_LTR
Left-to-right run direction.- See Also:
RUN_DIRECTION
-
RUN_DIRECTION_RTL
public static final TextAttribute RUN_DIRECTION_RTL
Right-to-left run direction.- See Also:
RUN_DIRECTION
-
FONT
public static final TextAttribute FONT
Specifies a font for a text interval. The value should be an instance ofFont
.
-
STRIKETHROUGH
public static final TextAttribute STRIKETHROUGH
Strike through
-
UNDERLINE
public static final TextAttribute UNDERLINE
Underline. The value should be an instance ofBoolean
.
-
-
Method Detail
-
values
public static TextAttribute[] values()
Returns an array containing the constants of this enum type, in the order they are declared. This method may be used to iterate over the constants as follows:for (TextAttribute c : TextAttribute.values()) System.out.println(c);
- Returns:
- an array containing the constants of this enum type, in the order they are declared
-
valueOf
public static TextAttribute valueOf(java.lang.String name)
Returns the enum constant of this type with the specified name. The string must match exactly an identifier used to declare an enum constant in this type. (Extraneous whitespace characters are not permitted.)- Parameters:
name
- the name of the enum constant to be returned.- Returns:
- the enum constant with the specified name
- Throws:
java.lang.IllegalArgumentException
- if this enum type has no constant with the specified namejava.lang.NullPointerException
- if the argument is null
-
-