SetaPDF_FormFiller_Field_ButtonGroup A radio button group
File: /SetaPDF v2/FormFiller/Field/ButtonGroup.php
Class hierarchy
Implements
Summary
Methods
- __construct()
- addButton()
- cleanUp()
- delete()
- flatten()
- getButtons()
- getDefaultButton()
- getDefaultValue()
- getFields()
- getName()
- getNoExport()
- getOriginalQualifiedName()
- getPageNumber()
- getQualifiedName()
- getTooltip()
- getValue()
- isReadOnly()
- isRequired()
- isSetValueActive()
- onFieldDeleted()
- setDefaultValue()
- setNoExport()
- setReadOnly()
- setRequired()
- setTooltip()
- setValue()
Properties
$_buttons
The buttons
$_qualifiedName
The qualified name of the button group
Methods
__construct()
The constructor.
Parameters
- $fields : SetaPDF_FormFiller_Fields
- $qualifiedName : string
- $fieldObject : SetaPDF_Core_Type_IndirectReference|SetaPDF_Core_Type_IndirectObject
addButton()
Add a button to the group.
Parameters
- $button : SetaPDF_FormFiller_Field_Button
flatten()
Flatten the button group to the pages content stream.
Parameters
- $recreateAppearanceIfNeedAppearancesIsSet : boolean
Defines whether the field appearance is re-created if the NeedAppearances flag is set.
getDefaultButton()
Get the default checked button.
getDefaultValue()
Returns the default value of the button group.
This value is used if the form is reset
Parameters
- $encoding : string
See
getNoExport()
Get the info, if the button group is marked as "no export".
This flag is not get- or settable with Acrobat!
getOriginalQualifiedName()
Returns the original qualified name.
(which is the same as the qualified name for button groups)
getTooltip()
Get the tooltip value.
Parameters
- $encoding : string
getValue()
Get the export value of the current active button.
This method returns the export value of the first checked button.
onFieldDeleted()
Is called when a button in this group is deleted.
Parameters
- $button : SetaPDF_FormFiller_Field_Button
setDefaultValue()
Set the default value of this button group.
Parameters
- $value : string|null
- $encoding : string
setNoExport()
Sets the "no export" flag.
This flag is not get- or settable with Acrobat!
If you remove this flag, the element could be still not exported due to a definition in a FormSubmit actions Fields array.
Parameters
- $noExport : boolean
setTooltip()
Set the tooltip value.
Parameters
- $value : string|false
- $encoding : string
setValue()
Set the value / active button of the button group.
This method requires the button object, which should be activated as the parameter or an export value which will be used to find the desired button.
Parameters
- $value : SetaPDF_FormFiller_Field_Button|string
The button instance or an export value
Exceptions
Throws InvalidArgumentException