Checkbox
The <checkbox>
tag can be used to display checkboxes on documents. Checkboxes can have a label right of the box and checkboxes can be made editable.
It can only be used within a <body>
.
Available in Version 14.1 and above
Example
Example as editable checkbox
Example as editable radio buttons
Attributes
checked
checked
Whether the checkbox should be displayed as checked or not. It is checked for the values "true", "True" and 1. If you don't provide the property, the box is not checked.
label
(optional)
Display text on the same line height as the checkbox.
color
(optional)
The text color of the label.
fontSize
(optional)
The size of the checkbox and the font size of the label.
class
(optional)
The style class to define how the label looks like. The label fontSize will also affect the size of the checkbox.
spaceBefore
(optional)
Adds space (in pt, mm or cm) before the field.
spaceAfter
(optional)
Adds space (in pt, mm or cm) after the field.
editable
(optional)
editable
(optional)This overwrites the automatic behaviour to display a checkbox as editable. If you set editable="false"
the field can never be edited. If you set it to editable="true"
the field can always be edited, even when rendered in a normal PDF.
id
(optional)
id
(optional)The identifier / name of the field in the checkbox is rendered as editable.
name
(optional)
name
(optional)If a name is provided, the checkbox will behave as a radio button. All checkboxes with this name are part of the radio group. This will then also be the identifier / name of the field in the rendered pdf, while the id will be the value of the individual radio button.
Last updated
Was this helpful?