public class TextPath
extends java.lang.Object
Use the Shape.getTextPath() property to access WordArt properties of a shape. You do not create instances of the TextPath class directly.
Shape.getTextPath()| Modifier and Type | Method and Description |
|---|---|
boolean |
getBold()
True if the font is formatted as bold.
|
boolean |
getFitPath()
Defines whether the text fits the path of a shape.
|
boolean |
getFitShape()
Defines whether the text fits bounding box of a shape.
|
java.lang.String |
getFontFamily()
Defines the family of the textpath font.
|
boolean |
getItalic()
True if the font is formatted as italic.
|
boolean |
getKerning()
Determines whether kerning is turned on.
|
boolean |
getOn()
Defines whether the text is displayed.
|
boolean |
getReverseRows()
Determines whether the layout order of rows is reversed.
|
boolean |
getRotateLetters()
Determines whether the letters of the text are rotated.
|
boolean |
getSameLetterHeights()
Determines whether all letters will be the same height regardless of initial case.
|
boolean |
getShadow()
Defines whether a shadow is applied to the text on a text path.
|
double |
getSize()
Defines the size of the font in points.
|
boolean |
getSmallCaps()
True if the font is formatted as small capital letters.
|
double |
getSpacing()
Defines the amount of spacing for text.
|
boolean |
getStrikeThrough()
True if the font is formatted as strikethrough text.
|
java.lang.String |
getText()
Defines the text of the text path.
|
int |
getTextPathAlignment()
Defines the alignment of text.
|
boolean |
getTrim()
Determines whether extra space is removed above and below the text.
|
boolean |
getUnderline()
True if the font is underlined.
|
boolean |
getXScale()
Determines whether a straight textpath will be used instead of the shape path.
|
void |
setBold(boolean value)
True if the font is formatted as bold.
|
void |
setFitPath(boolean value)
Defines whether the text fits the path of a shape.
|
void |
setFitShape(boolean value)
Defines whether the text fits bounding box of a shape.
|
void |
setFontFamily(java.lang.String value)
Defines the family of the textpath font.
|
void |
setItalic(boolean value)
True if the font is formatted as italic.
|
void |
setKerning(boolean value)
Determines whether kerning is turned on.
|
void |
setOn(boolean value)
Defines whether the text is displayed.
|
void |
setReverseRows(boolean value)
Determines whether the layout order of rows is reversed.
|
void |
setRotateLetters(boolean value)
Determines whether the letters of the text are rotated.
|
void |
setSameLetterHeights(boolean value)
Determines whether all letters will be the same height regardless of initial case.
|
void |
setShadow(boolean value)
Defines whether a shadow is applied to the text on a text path.
|
void |
setSize(double value)
Defines the size of the font in points.
|
void |
setSmallCaps(boolean value)
True if the font is formatted as small capital letters.
|
void |
setSpacing(double value)
Defines the amount of spacing for text.
|
void |
setStrikeThrough(boolean value)
True if the font is formatted as strikethrough text.
|
void |
setText(java.lang.String value)
Defines the text of the text path.
|
void |
setTextPathAlignment(int value)
Defines the alignment of text.
|
void |
setTrim(boolean value)
Determines whether extra space is removed above and below the text.
|
void |
setUnderline(boolean value)
True if the font is underlined.
|
void |
setXScale(boolean value)
Determines whether a straight textpath will be used instead of the shape path.
|
public boolean getOn()
The default value is false.
boolean value.public void setOn(boolean value)
The default value is false.
value - The corresponding boolean value.public boolean getFitPath()
The default value is false.
boolean value.public void setFitPath(boolean value)
The default value is false.
value - The corresponding boolean value.public boolean getFitShape()
The default value is false.
boolean value.public void setFitShape(boolean value)
The default value is false.
value - The corresponding boolean value.public java.lang.String getFontFamily()
The default value is Arial.
String value.public void setFontFamily(java.lang.String value)
The default value is Arial.
value - The corresponding String value.public double getSize()
The default value is 36.
double value.public void setSize(double value)
The default value is 36.
value - The corresponding double value.public boolean getBold()
The default value is false.
boolean value.public void setBold(boolean value)
The default value is false.
value - The corresponding boolean value.public boolean getItalic()
The default value is false.
boolean value.public void setItalic(boolean value)
The default value is false.
value - The corresponding boolean value.public boolean getSmallCaps()
The default value is false.
boolean value.public void setSmallCaps(boolean value)
The default value is false.
value - The corresponding boolean value.public boolean getRotateLetters()
The default value is false.
boolean value.public void setRotateLetters(boolean value)
The default value is false.
value - The corresponding boolean value.public boolean getTrim()
The default value is false.
boolean value.public void setTrim(boolean value)
The default value is false.
value - The corresponding boolean value.public boolean getKerning()
The default value is false.
boolean value.public void setKerning(boolean value)
The default value is false.
value - The corresponding boolean value.public boolean getShadow()
The default value is false.
boolean value.public void setShadow(boolean value)
The default value is false.
value - The corresponding boolean value.public boolean getUnderline()
The default value is false.
boolean value.public void setUnderline(boolean value)
The default value is false.
value - The corresponding boolean value.public boolean getStrikeThrough()
The default value is false.
boolean value.public void setStrikeThrough(boolean value)
The default value is false.
value - The corresponding boolean value.public boolean getSameLetterHeights()
The default value is false.
boolean value.public void setSameLetterHeights(boolean value)
The default value is false.
value - The corresponding boolean value.public java.lang.String getText()
The default value is an empty string.
String value.public void setText(java.lang.String value)
The default value is an empty string.
value - The corresponding String value.public int getTextPathAlignment()
The default value is TextPathAlignment.CENTER.
int value. The returned value is one of TextPathAlignment constants.public void setTextPathAlignment(int value)
The default value is TextPathAlignment.CENTER.
value - The corresponding int value. The value must be one of TextPathAlignment constants.public boolean getReverseRows()
The default value is false.
If true, the layout order of rows is reversed. This attribute is used for vertical text layout.
boolean value.public void setReverseRows(boolean value)
The default value is false.
If true, the layout order of rows is reversed. This attribute is used for vertical text layout.
value - The corresponding boolean value.public double getSpacing()
The default value is 1.
double value.public void setSpacing(double value)
The default value is 1.
value - The corresponding double value.public boolean getXScale()
The default value is false.
If true, the text runs along a path from left to right along the x value of the lower boundary of the shape.
boolean value.public void setXScale(boolean value)
The default value is false.
If true, the text runs along a path from left to right along the x value of the lower boundary of the shape.
value - The corresponding boolean value.