Package com.oorian.css.units
Class Pc
java.lang.Object
com.oorian.css.units.Units
com.oorian.css.units.Pc
CSS pc (pica) unit value.
The pc unit is an absolute-length unit equal to one pica, a traditional printing unit. In CSS, 1pc equals 1/6th of an inch or 16px. Picas are primarily used in print design and typography.
Usage:
Units size = new Pc(6);
element.setWidth(new Pc(30));
element.setMargin(new Pc(2));
- Since:
- 2016
- Version:
- 1.0
- Author:
- Marvin P. Warble Jr.
- See Also:
-
Constructor Summary
Constructors -
Method Summary
Modifier and TypeMethodDescriptionReturns the CSS string representation of this pica value.
-
Constructor Details
-
Pc
public Pc(float value) Constructs a Pc unit with the specified value.- Parameters:
value- the pica value
-
-
Method Details
-
sizeToString
Returns the CSS string representation of this pica value.- Specified by:
sizeToStringin classUnits- Returns:
- the CSS value string (e.g., "6pc")
-