PoDoFo  0.9.1
Public Member Functions | List of all members
PoDoFo::PdfCheckBox Class Reference

#include <PdfField.h>

Inherits PoDoFo::PdfButton.

Public Member Functions

 PdfCheckBox (PdfAnnotation *pWidget, PdfAcroForm *pParent)
 
 PdfCheckBox (PdfPage *pPage, const PdfRect &rRect, PdfAcroForm *pParent)
 
 PdfCheckBox (PdfPage *pPage, const PdfRect &rRect, PdfDocument *pDoc)
 
 PdfCheckBox (PdfPage *pPage, const PdfRect &rRect, PdfStreamedDocument *pDoc)
 
 PdfCheckBox (const PdfField &rhs)
 
void SetAppearanceChecked (const PdfXObject &rXObject)
 
void SetAppearanceUnchecked (const PdfXObject &rXObject)
 
void SetChecked (bool bChecked)
 
bool IsChecked () const
 
- Public Member Functions inherited from PoDoFo::PdfButton
 PdfButton (const PdfField &rhs)
 
bool IsPushButton () const
 
bool IsCheckBox () const
 
bool IsRadioButton () const
 
void SetCaption (const PdfString &rsText)
 
const PdfString GetCaption () const
 
- Public Member Functions inherited from PoDoFo::PdfField
 PdfField (PdfObject *pObject, PdfAnnotation *pWidget)
 
 PdfField (const PdfField &rhs)
 
PdfPageGetPage () const
 
void SetHighlightingMode (EPdfHighlightingMode eMode)
 
EPdfHighlightingMode GetHighlightingMode () const
 
void SetBorderColorTransparent ()
 
void SetBorderColor (double dGray)
 
void SetBorderColor (double dRed, double dGreen, double dBlue)
 
void SetBorderColor (double dCyan, double dMagenta, double dYellow, double dBlack)
 
void SetBackgroundColorTransparent ()
 
void SetBackgroundColor (double dGray)
 
void SetBackgroundColor (double dRed, double dGreen, double dBlue)
 
void SetBackgroundColor (double dCyan, double dMagenta, double dYellow, double dBlack)
 
void SetFieldName (const PdfString &rsName)
 
PdfString GetFieldName () const
 
void SetAlternateName (const PdfString &rsName)
 
PdfString GetAlternateName () const
 
void SetMappingName (const PdfString &rsName)
 
PdfString GetMappingName () const
 
void SetReadOnly (bool bReadOnly)
 
bool IsReadOnly () const
 
void SetRequired (bool bRequired)
 
bool IsRequired () const
 
void SetExport (bool bExport)
 
bool IsExport () const
 
EPdfField GetType () const
 

Additional Inherited Members

- Protected Member Functions inherited from PoDoFo::PdfButton
 PdfButton (EPdfField eField, PdfAnnotation *pWidget, PdfAcroForm *pParent)
 
 PdfButton (EPdfField eField, PdfPage *pPage, const PdfRect &rRect, PdfAcroForm *pParent)
 
 PdfButton (EPdfField eField, PdfPage *pPage, const PdfRect &rRect, PdfDocument *pDoc)
 
 PdfButton (EPdfField eField, PdfPage *pPage, const PdfRect &rRect, PdfStreamedDocument *pDoc)
 

Detailed Description

A checkbox can be checked or unchecked by the user

Constructor & Destructor Documentation

PoDoFo::PdfCheckBox::PdfCheckBox ( PdfAnnotation pWidget,
PdfAcroForm *  pParent 
)

Create a new PdfCheckBox

PoDoFo::PdfCheckBox::PdfCheckBox ( PdfPage pPage,
const PdfRect rRect,
PdfAcroForm *  pParent 
)

Create a new PdfCheckBox

PoDoFo::PdfCheckBox::PdfCheckBox ( PdfPage pPage,
const PdfRect rRect,
PdfDocument pDoc 
)

Create a new PdfCheckBox

PoDoFo::PdfCheckBox::PdfCheckBox ( PdfPage pPage,
const PdfRect rRect,
PdfStreamedDocument pDoc 
)

Create a new PdfCheckBox

PoDoFo::PdfCheckBox::PdfCheckBox ( const PdfField &  rhs)

Create a PdfCheckBox from a PdfField

Parameters
rhsa PdfField that is a check box

Raises an error if PdfField::GetType() != ePdfField_CheckBox

Member Function Documentation

bool PoDoFo::PdfCheckBox::IsChecked ( ) const
Returns
true if the checkbox is checked
void PoDoFo::PdfCheckBox::SetAppearanceChecked ( const PdfXObject rXObject)

Set the appearance stream which is displayed when the checkbox is checked.

Parameters
rXObjectan xobject which contains the drawing commands for a checked checkbox
void PoDoFo::PdfCheckBox::SetAppearanceUnchecked ( const PdfXObject rXObject)

Set the appearance stream which is displayed when the checkbox is unchecked.

Parameters
rXObjectan xobject which contains the drawing commands for an unchecked checkbox
void PoDoFo::PdfCheckBox::SetChecked ( bool  bChecked)

Sets the state of this checkbox

Parameters
bCheckedif true the checkbox will be checked