Enum RectHeightMode
- java.lang.Object
-
- java.lang.Enum<RectHeightMode>
-
- io.github.humbleui.skija.paragraph.RectHeightMode
-
- All Implemented Interfaces:
java.io.Serializable,java.lang.Comparable<RectHeightMode>
public enum RectHeightMode extends java.lang.Enum<RectHeightMode>
-
-
Enum Constant Summary
Enum Constants Enum Constant Description INCLUDE_LINE_SPACING_BOTTOMThe line spacing will be added to the bottom of the rect.INCLUDE_LINE_SPACING_MIDDLEExtends the top and/or bottom edge of the bounds to fully cover any line spacing.INCLUDE_LINE_SPACING_TOPThe line spacing will be added to the top of the rect.MAXThe height of the boxes will be the maximum height of all runs in the line.STRUTTIGHTProvide tight bounding boxes that fit heights per run.
-
Field Summary
Fields Modifier and Type Field Description static RectHeightMode[]_values
-
Method Summary
All Methods Static Methods Concrete Methods Modifier and Type Method Description static RectHeightModevalueOf(java.lang.String name)Returns the enum constant of this type with the specified name.static RectHeightMode[]values()Returns an array containing the constants of this enum type, in the order they are declared.
-
-
-
Enum Constant Detail
-
TIGHT
public static final RectHeightMode TIGHT
Provide tight bounding boxes that fit heights per run.
-
MAX
public static final RectHeightMode MAX
The height of the boxes will be the maximum height of all runs in the line. All rects in the same line will be the same height.
-
INCLUDE_LINE_SPACING_MIDDLE
public static final RectHeightMode INCLUDE_LINE_SPACING_MIDDLE
Extends the top and/or bottom edge of the bounds to fully cover any line spacing. The top edge of each line should be the same as the bottom edge of the line above. There should be no gaps in vertical coverage given any ParagraphStyle line_height. The top and bottom of each rect will cover half of the space above and half of the space below the line.
-
INCLUDE_LINE_SPACING_TOP
public static final RectHeightMode INCLUDE_LINE_SPACING_TOP
The line spacing will be added to the top of the rect.
-
INCLUDE_LINE_SPACING_BOTTOM
public static final RectHeightMode INCLUDE_LINE_SPACING_BOTTOM
The line spacing will be added to the bottom of the rect.
-
STRUT
public static final RectHeightMode STRUT
-
-
Field Detail
-
_values
@Internal public static final RectHeightMode[] _values
-
-
Method Detail
-
values
public static RectHeightMode[] 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 (RectHeightMode c : RectHeightMode.values()) System.out.println(c);
- Returns:
- an array containing the constants of this enum type, in the order they are declared
-
valueOf
public static RectHeightMode 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
-
-