Button
extends AbstractField
in package
Pdf page button field class
Tags
Table of Contents
- $defaultValue : string
- Field default value
- $flagBits : array<string|int, mixed>
- Field flag bits
- $font : string
- Text field font
- $fontColor : ColorInterface
- Field font color
- $height : int
- Text field height
- $name : string
- Field name
- $options : array<string|int, mixed>
- Field options
- $size : int
- Text field font size
- $value : string
- Field value
- $width : int
- Text field width
- __construct() : mixed
- Constructor
- addOption() : Button
- Add an option
- getDefaultValue() : string
- Get the field default value
- getFont() : string
- Get the font
- getFontColor() : ColorInterface
- Get the field font color
- getHeight() : int
- Get the field height
- getName() : string
- Get the field name
- getSize() : int
- Get the font size
- getStream() : string
- Get the field stream
- getValue() : string
- Get the field value
- getWidth() : int
- Get the field width
- hasOptions() : bool
- Has options
- isPushButton() : Button
- Is push button
- isRadio() : bool
- Is radio
- setDefaultValue() : AbstractField
- Set the field default value
- setFont() : AbstractField
- Set the font
- setFontColor() : AbstractField
- Set the font color
- setHeight() : AbstractField
- Set the field height
- setName() : AbstractField
- Set the field name
- setNoExport() : AbstractField
- Set no export
- setNoToggleToOff() : Button
- Set no toggle to off
- setPushButton() : Button
- Set push button
- setRadio() : Button
- Set radio
- setRadiosInUnison() : Button
- Set radios in unison
- setReadOnly() : AbstractField
- Set read-only
- setRequired() : AbstractField
- Set required
- setSize() : AbstractField
- Set the font size
- setValue() : AbstractField
- Set the field value
- setWidth() : AbstractField
- Set the field width
- getFlags() : int
- Get the flags value
Properties
$defaultValue
Field default value
protected
string
$defaultValue
= null
$flagBits
Field flag bits
protected
array<string|int, mixed>
$flagBits
= []
$font
Text field font
protected
string
$font
= null
$fontColor
Field font color
protected
ColorInterface
$fontColor
= null
$height
Text field height
protected
int
$height
= null
$name
Field name
protected
string
$name
= null
$options
Field options
protected
array<string|int, mixed>
$options
= []
$size
Text field font size
protected
int
$size
= 12
$value
Field value
protected
string
$value
= null
$width
Text field width
protected
int
$width
= null
Methods
__construct()
Constructor
public
__construct(string $name[, string $font = null ][, int $size = 12 ]) : mixed
Instantiate a PDF text field object.
Parameters
- $name : string
- $font : string = null
- $size : int = 12
Return values
mixed —addOption()
Add an option
public
addOption(string $option, int $xOffset, int $yOffset) : Button
Parameters
- $option : string
- $xOffset : int
- $yOffset : int
Return values
Button —getDefaultValue()
Get the field default value
public
getDefaultValue() : string
Return values
string —getFont()
Get the font
public
getFont() : string
Return values
string —getFontColor()
Get the field font color
public
getFontColor() : ColorInterface
Return values
ColorInterface —getHeight()
Get the field height
public
getHeight() : int
Return values
int —getName()
Get the field name
public
getName() : string
Return values
string —getSize()
Get the font size
public
getSize() : int
Return values
int —getStream()
Get the field stream
public
getStream(int $i, int $pageIndex, string $fontReference, int $x, int $y) : string
Parameters
- $i : int
- $pageIndex : int
- $fontReference : string
- $x : int
- $y : int
Return values
string —getValue()
Get the field value
public
getValue() : string
Return values
string —getWidth()
Get the field width
public
getWidth() : int
Return values
int —hasOptions()
Has options
public
hasOptions() : bool
Return values
bool —isPushButton()
Is push button
public
isPushButton() : Button
Return values
Button —isRadio()
Is radio
public
isRadio() : bool
Return values
bool —setDefaultValue()
Set the field default value
public
setDefaultValue(string $value) : AbstractField
Parameters
- $value : string
Return values
AbstractField —setFont()
Set the font
public
setFont(string $font) : AbstractField
Parameters
- $font : string
Return values
AbstractField —setFontColor()
Set the font color
public
setFontColor(ColorInterface $color) : AbstractField
Parameters
- $color : ColorInterface
Return values
AbstractField —setHeight()
Set the field height
public
setHeight(int $height) : AbstractField
Parameters
- $height : int
Return values
AbstractField —setName()
Set the field name
public
setName(string $name) : AbstractField
Parameters
- $name : string
Return values
AbstractField —setNoExport()
Set no export
public
setNoExport() : AbstractField
Return values
AbstractField —setNoToggleToOff()
Set no toggle to off
public
setNoToggleToOff() : Button
Return values
Button —setPushButton()
Set push button
public
setPushButton() : Button
Return values
Button —setRadio()
Set radio
public
setRadio() : Button
Return values
Button —setRadiosInUnison()
Set radios in unison
public
setRadiosInUnison() : Button
Return values
Button —setReadOnly()
Set read-only
public
setReadOnly() : AbstractField
Return values
AbstractField —setRequired()
Set required
public
setRequired() : AbstractField
Return values
AbstractField —setSize()
Set the font size
public
setSize(int $size) : AbstractField
Parameters
- $size : int
Return values
AbstractField —setValue()
Set the field value
public
setValue(string $value) : AbstractField
Parameters
- $value : string
Return values
AbstractField —setWidth()
Set the field width
public
setWidth(int $width) : AbstractField
Parameters
- $width : int
Return values
AbstractField —getFlags()
Get the flags value
protected
getFlags() : int