Enum PreserveAspectRatio.MeetOrSlice
- All Implemented Interfaces:
Serializable
,Comparable<PreserveAspectRatio.MeetOrSlice>
,java.lang.constant.Constable
- Enclosing class:
PreserveAspectRatio
-
Nested Class Summary
Nested classes/interfaces inherited from class java.lang.Enum
Enum.EnumDesc<E extends Enum<E>>
-
Enum Constant Summary
Enum Constants -
Constructor Summary
Constructors -
Method Summary
Modifier and TypeMethodDescriptionReturns the enum constant of this type with the specified name.static PreserveAspectRatio.MeetOrSlice[]
values()
Returns an array containing the constants of this enum type, in the order they are declared.
-
Enum Constant Details
-
Meet
Scale the graphic such that:- aspect ratio is preserved - the entire viewBox is visible within the viewport - the viewBox is scaled up as much as possible, while still meeting the other criteria
In this case, if the aspect ratio of the graphic does not match the viewport, some viewport will extend beyond the bounds of the viewBox (i.e., the area into which the viewBox will draw will be smaller than the viewport).
-
Slice
Scale the graphic such that:- aspect ratio is preserved - the entire viewport is covered by the viewBox - the viewBox is scaled down as much as possible, while still meeting the other criteria
In this case, if the aspect ratio of the viewBox does not match the viewport, some viewBox will extend beyond the bounds of the viewport (i.e., the area into which the viewBox will draw is larger than the viewport).
-
-
Constructor Details
-
MeetOrSlice
private MeetOrSlice()
-
-
Method Details
-
values
Returns an array containing the constants of this enum type, in the order they are declared.- Returns:
- an array containing the constants of this enum type, in the order they are declared
-
valueOf
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:
IllegalArgumentException
- if this enum type has no constant with the specified nameNullPointerException
- if the argument is null
-