Package org.openpdf.pdf
Class RadioButtonFormField
java.lang.Object
org.openpdf.pdf.AbstractFormField
org.openpdf.pdf.RadioButtonFormField
- All Implemented Interfaces:
ReplacedElement,ITextReplacedElement
-
Field Summary
FieldsModifier and TypeFieldDescriptionprivate final Boxprivate final ITextReplacedElementFactoryprivate static final StringFields inherited from class org.openpdf.pdf.AbstractFormField
DEFAULT_CHECKED_STATE, OFF_STATE -
Constructor Summary
ConstructorsConstructorDescriptionRadioButtonFormField(ITextReplacedElementFactory factory, LayoutContext c, BlockBox box, int cssWidth, int cssHeight) -
Method Summary
Modifier and TypeMethodDescriptionprivate voidcreateAppearances(PdfContentByte cb, PdfFormField field, String onValue, float width, float height, boolean normal, FSColor color, FSColor darker) private voidcreateField(RenderingContext c, ITextOutputDevice outputDevice, PdfContentByte cb, PdfWriter writer, PdfFormField group, RadioButtonFormField fieldElem, RadioButtonFormField checked) voidintgetBox()private @Nullable RadioButtonFormFieldgetChecked(List<RadioButtonFormField> fields) protected Stringbooleanvoidpaint(RenderingContext c, ITextOutputDevice outputDevice, BlockBox box) private floatreduce(float value) Methods inherited from class org.openpdf.pdf.AbstractFormField
getFieldName, getHeight, getIntrinsicHeight, getIntrinsicWidth, getLocation, getValue, getWidth, getX, getY, initDimensions, isChecked, isReadOnly, isRequiresInteractivePaint, isSelected, setFillColor, setHeight, setLocation, setStrokeColor, setWidth, setX, setY, spaces
-
Field Details
-
FIELD_TYPE
- See Also:
-
_factory
-
_box
-
-
Constructor Details
-
RadioButtonFormField
public RadioButtonFormField(ITextReplacedElementFactory factory, LayoutContext c, BlockBox box, int cssWidth, int cssHeight)
-
-
Method Details
-
getFieldType
- Specified by:
getFieldTypein classAbstractFormField
-
paint
-
getChecked
-
createField
private void createField(RenderingContext c, ITextOutputDevice outputDevice, PdfContentByte cb, PdfWriter writer, PdfFormField group, RadioButtonFormField fieldElem, RadioButtonFormField checked) -
createAppearances
private void createAppearances(PdfContentByte cb, PdfFormField field, String onValue, float width, float height, boolean normal, FSColor color, FSColor darker) -
reduce
private float reduce(float value) -
detach
- Specified by:
detachin interfaceReplacedElement- Overrides:
detachin classAbstractFormField
-
getBox
-
getBaseline
public int getBaseline() -
hasBaseline
public boolean hasBaseline()
-