Class CheckBox

All Implemented Interfaces:
IFormField, IAbstractElement, IBlockElement, IElement, IPropertyContainer, IAccessibleElement

public class CheckBox extends FormField<CheckBox>
Extension of the FormField class representing a checkbox so that a CheckBoxRenderer is used instead of the default renderer for fields.
  • Field Details

    • LOGGER

      private static final org.slf4j.Logger LOGGER
  • Constructor Details

    • CheckBox

      public CheckBox(String id)
      Creates a new CheckBox instance.
      Parameters:
      id - the id
  • Method Details

    • setChecked

      public CheckBox setChecked(boolean checked)
      Sets the checked state of the checkbox.
      Parameters:
      checked - the checked state to set
      Returns:
      this checkbox instance
    • setPdfAConformanceLevel

      @Deprecated public CheckBox setPdfAConformanceLevel(PdfAConformanceLevel conformanceLevel)
      Deprecated.
      Sets the PDF/A conformance level for the checkbox. This method is deprecated use setPdfConformanceLevel.
      Parameters:
      conformanceLevel - The PDF/A conformance level to set.
      Returns:
      This checkbox instance.
    • setPdfConformanceLevel

      public CheckBox setPdfConformanceLevel(IConformanceLevel conformanceLevel)
      Sets the conformance level for the checkbox.
      Parameters:
      conformanceLevel - The PDF/A conformance level to set.
      Returns:
      tThis checkbox instance.
    • setCheckBoxType

      public CheckBox setCheckBoxType(CheckBoxType checkBoxType)
      Sets the icon of the checkbox.
      Parameters:
      checkBoxType - the type of the checkbox to set
      Returns:
      this checkbox instance
    • setSize

      public CheckBox setSize(float size)
      Sets the size of the checkbox.
      Overrides:
      setSize in class FormField<CheckBox>
      Parameters:
      size - the size of the checkbox to set, in points
      Returns:
      this checkbox instance
    • getAccessibilityProperties

      public AccessibilityProperties getAccessibilityProperties()
      Returns:
      an interface that allows to specify properties of a tagged element in Tagged PDF.
    • makeNewRenderer

      protected IRenderer makeNewRenderer()
      Description copied from class: AbstractElement
      Creates new renderer instance.
      Specified by:
      makeNewRenderer in class AbstractElement<CheckBox>
      Returns:
      new IRenderer