public enum TextAutofit extends java.lang.Enum<TextAutofit>
Autofit specifies that a shape should be auto-fit to fully contain the text described within it. Auto-fitting is when text within a shape is scaled in order to contain all the text inside
(指定自动适应类型的列表。 Autofit 指定一个形状应该自动适应以完全包含其中描述的文本。自动拟合是当形状内的文本被缩放以包含里面的所有文本时)Enum Constant and Description |
---|
NONE
Specifies that text within the text body should not be auto-fit to the bounding box.
|
NORMAL
Specifies that text within the text body should be normally auto-fit to the bounding box.
|
SHAPE
Specifies that a shape should be auto-fit to fully contain the text described within it.
|
Modifier and Type | Method and Description |
---|---|
static TextAutofit |
valueOf(java.lang.String name)
Returns the enum constant of this type with the specified name.
(返回具有指定名称的此类型的枚举常量。)
|
static TextAutofit[] |
values()
Returns an array containing the constants of this enum type, in the order they are declared.
(按照声明的顺序返回包含此枚举类型常量的数组。)
|
public static final TextAutofit NONE
public static final TextAutofit NORMAL
Example: Consider the situation where a user is building a diagram and needs to have the text for each shape that they are using stay within the bounds of the shape. An easy way this might be done is by using NORMAL autofit
(指定文本正文中的文本通常应自动适应边界框。自动调整是缩放文本框中的文本以保持在文本框中。示例:考虑用户正在构建图表并且需要让他们使用的每个形状的文本保持在形状范围内的情况。一个简单的方法是使用 NORMAL autofit)public static final TextAutofit SHAPE
Example: Consider the situation where a user is building a diagram and needs to have the text for each shape that they are using stay within the bounds of the shape. An easy way this might be done is by using SHAPE autofit
(指定应自动调整形状以完全包含其中描述的文本。自动拟合是指对形状中的文本进行缩放以包含其中的所有文本。示例:考虑用户正在构建图表并且需要让他们使用的每个形状的文本保持在形状范围内的情况。一个简单的方法是使用 SHAPE autofit)public static TextAutofit[] values()
for (TextAutofit c : TextAutofit.values()) System.out.println(c);(按照声明的顺序返回包含此枚举类型常量的数组。此方法可用于迭代常量,如下所示: for (TextAutofit c : TextAutofit.values()) System.out.println(c);)
public static TextAutofit valueOf(java.lang.String name)
name
- the name of the enum constant to be returned.
(name - 要返回的枚举常量的名称。)
java.lang.IllegalArgumentException
- if this enum type has no constant with the specified name
(java.lang.IllegalArgumentException - 如果此枚举类型没有具有指定名称的常量)
java.lang.NullPointerException
- if the argument is null
(java.lang.NullPointerException - 如果参数为空)
Copyright 2021 The Apache Software Foundation or its licensors, as applicable.