pdftools_toolbox.pdf.forms.check_box
Classes
|
A check box field |
- class pdftools_toolbox.pdf.forms.check_box.CheckBox(handle)[source]
Bases:
Field
A check box field
- static create(target_document: Document) CheckBox [source]
Create a check box form field
The returned form field object is not yet used, but it is associated with the given target document.
- Parameters:
targetDocument (pdftools_toolbox.pdf.document.Document) – the output document with which the returned object is associated
- Returns:
the newly created check box field
- Return type:
- Raises:
ValueError – if the targetDocument argument has already been closed
ValueError – if the targetDocument argument is read-only
ValueError – the target document contains form fields that have been implicitly copied by a call to
pdftools_toolbox.pdf.page.Page.copy()
with an argument options from pdftools_toolbox.pdf.page.Page.copy in whichpdftools_toolbox.pdf.page_copy_options.PageCopyOptions.form_fields
was set topdftools_toolbox.pdf.forms.form_field_copy_strategy.FormFieldCopyStrategy.COPY
ValueError – the target document contains unsigned signatures that have been implicitly copied by a call to
pdftools_toolbox.pdf.page.Page.copy()
with an argument options from pdftools_toolbox.pdf.page.Page.copy in whichpdftools_toolbox.pdf.page_copy_options.PageCopyOptions.unsigned_signatures
was set topdftools_toolbox.pdf.copy_strategy.CopyStrategy.COPY
.
- property checked_export_name: str | None
The name of the checked (‘on’) state used when exporting
- Returns:
Optional[str]
- Raises:
StateError – if the object has already been closed
- property checked: bool
The state of the check box
- Returns:
bool
- Raises:
StateError – if the object has already been closed