Package com.itextpdf.layout.properties
Class InlineVerticalAlignment
java.lang.Object
com.itextpdf.layout.properties.InlineVerticalAlignment
A property corresponding to the css vertical-align property and used to set vertical alignment on inline blocks, it specifies the type of alignment and where needed a numerical value to complete it.
-
Constructor Summary
ConstructorDescriptionCreates a default InlineVerticalAlignment, it gets the typeInlineVerticalAlignmentType.BASELINE
.Creates an InlineVerticalAlignment with a specified type.InlineVerticalAlignment
(InlineVerticalAlignmentType type, float value) Creates an InlineVerticalAlignment with a specified type and a value. -
Method Summary
Modifier and TypeMethodDescriptiongetType()
Gets the type of InlineVerticalAlignment.float
getValue()
Gets the value.void
Sets the typeInlineVerticalAlignmentType
.void
setValue
(float value) Sets the value.
-
Constructor Details
-
InlineVerticalAlignment
public InlineVerticalAlignment()Creates a default InlineVerticalAlignment, it gets the typeInlineVerticalAlignmentType.BASELINE
. -
InlineVerticalAlignment
Creates an InlineVerticalAlignment with a specified type.- Parameters:
-
type
-InlineVerticalAlignmentType
-
InlineVerticalAlignment
Creates an InlineVerticalAlignment with a specified type and a value. This will throw aPdfException
when used with a type that does not require a value.- Parameters:
-
type
-InlineVerticalAlignmentType
-
value
- In the case ofInlineVerticalAlignmentType.FIXED
a lenth in pts, in case ofInlineVerticalAlignmentType.FRACTION
a multiplier value.
-
-
Method Details
-
getType
Gets the type of InlineVerticalAlignment.- Returns:
-
the type
InlineVerticalAlignmentType
-
setType
Sets the typeInlineVerticalAlignmentType
.- Parameters:
-
type
-InlineVerticalAlignmentType
-
getValue
public float getValue()Gets the value.- Returns:
-
value In the case of
InlineVerticalAlignmentType.FIXED
a lenth in pts, in case ofInlineVerticalAlignmentType.FRACTION
a multiplier value.
-
setValue
public void setValue(float value) Sets the value.- Parameters:
-
value
- In the case ofInlineVerticalAlignmentType.FIXED
a lenth in pts, in case ofInlineVerticalAlignmentType.FRACTION
a multiplier value.
-