CFx SDK Documentation  2023 SP0
Public Member Functions | List of all members
OdPdfPublish::OdPage Class Reference

#include <PdfPublishPage.h>

Inheritance diagram for OdPdfPublish::OdPage:
OdPdfPublish::OdObject OdRxObject

Public Member Functions

 ODRX_DECLARE_MEMBERS (OdPage)
 
 ODRX_HEAP_OPERATORS ()
 
 OdPage ()
 
virtual ~OdPage ()
 
void setFormat (Page::Format format)
 
void setOrientation (Page::Orientation orientation)
 
void setPaperSize (const Page::PaperUnits units, const double width, const double height)
 
void addAnnotation (const OdAnnotationPtr &annotation, const OdRect &location)
 
void addText (const OdTextPtr &text, const OdRect &location)
 
void addImage (const OdImagePtr &image, const OdRect &location)
 
void addTable (const OdTablePtr &table, const OdRect &location)
 
void addLink (const OdLinkPtr &link, const OdRect &location)
 
void addButton (const OdButtonPtr &button, const OdRect &location)
 
void addTextField (const OdTextFieldPtr &text_field, const OdRect &location)
 
void addSlideTable (const OdSlideTablePtr &slide_table, const OdRect &location)
 
void addCheckBox (const OdCheckBoxPtr &check_box, const OdRect &location)
 
void addRadioButton (const OdRadioButtonPtr &radio_button, const OdRect &location)
 
void addListBox (const OdListBoxPtr &list_box, const OdRect &location)
 
void addDropDownList (const OdDropDownListPtr &drop_down_list, const OdRect &location)
 
void addSignatureField (const OdSignatureFieldPtr &signature_field, const OdRect &location)
 
void add2dGeometry (const Od2dGeometryReferencePtr &geom, const OdRect &location)
 
void add2dGeometry (const Od2dGeometryReferencePtr &geom)
 
void addJavaScriptActionByField (const OdString &field_name, const OdString &source, const Action::Type action_type)
 
void getFormat (Page::Format &format) const
 
void getOrientation (Page::Orientation &orientation) const
 
void getPaperSize (const Page::PaperUnits units, double &width, double &height) const
 
void getAnnotations (OdAnnotationPtrArray &annotations, OdRectArray &locations) const
 
void getTexts (OdTextPtrArray &texts, OdRectArray &locations) const
 
void getImages (OdImagePtrArray &images, OdRectArray &locations) const
 
void getTables (OdTablePtrArray &tables, OdRectArray &locations) const
 
void getLinks (OdLinkPtrArray &links, OdRectArray &locations) const
 
void getButtons (OdButtonPtrArray &buttons, OdRectArray &locations) const
 
void getCheckBoxes (OdCheckBoxPtrArray &check_boxes, OdRectArray &locations) const
 
void getRadioButtons (OdRadioButtonPtrArray &radio_buttons, OdRectArray &locations) const
 
void getListBoxes (OdListBoxPtrArray &list_boxes, OdRectArray &locations) const
 
void getDropDownLists (OdDropDownListPtrArray &drop_down_lists, OdRectArray &locations) const
 
void getSignatureFields (OdSignatureFieldPtrArray &signature_fields, OdRectArray &locations) const
 
void getTextFields (OdTextFieldPtrArray &text_fields, OdRectArray &locations) const
 
void getSlideTables (OdSlideTablePtrArray &slide_tables, OdRectArray &locations) const
 
void getJavaScriptActionsByField (const OdString &field_name, OdStringArray &sources, OdActionTypeArray &action_types) const
 
void get2dGeoms (Od2dGeometryReferencePtrArray &geoms, OdRectArray &locations) const
 
- Public Member Functions inherited from OdPdfPublish::OdObject
 ODRX_DECLARE_MEMBERS (OdObject)
 
 ODRX_HEAP_OPERATORS ()
 
virtual ~OdObject ()
 
virtual bool isEmpty () const
 
virtual bool isValid () const
 
virtual void clear ()
 
- Public Member Functions inherited from OdRxObject
 ODRX_HEAP_OPERATORS ()
 
 OdRxObject ()
 
virtual ~OdRxObject ()
 
virtual OdRxObjectqueryX (const OdRxClass *pClass) const
 
virtual OdRxObjectx (const OdRxClass *pClass) const
 
virtual OdRxClassisA () const
 
virtual void addRef ()=0
 
virtual void release ()=0
 
virtual long numRefs () const
 
bool isKindOf (const OdRxClass *pClass) const
 
virtual OdRxObjectPtr clone () const
 
virtual void copyFrom (const OdRxObject *pSource)
 
virtual OdRx::Ordering comparedTo (const OdRxObject *pOther) const
 
virtual bool isEqualTo (const OdRxObject *pOther) const
 

Additional Inherited Members

- Static Public Member Functions inherited from OdRxObject
static OdRxObjectPtr cast (const OdRxObject *pointer)
 
static OdRxClassdesc ()
 
- Protected Member Functions inherited from OdPdfPublish::OdObject
 OdObject (OdPublishObjectImpl *pImpl)
 

Detailed Description

This class implements a page object of .pdf document created with Teigha Publish. Any page is determined with two properties: format (sizes of its sides) and orientation (which side aligns horizontally) and can contain a set of different controls and fields (such as <link OdPdfPublish::OdText, text labels>, <link OdPdfPublish::OdAnnotation, annotations>, <link OdPdfPublish::OdTextField, text fields>, <OdPdfPublish::OdButton, buttons>, <OdPdfPublish::OdLink, links>, etc.).

Definition at line 63 of file PdfPublishPage.h.

Constructor & Destructor Documentation

◆ OdPage()

OdPdfPublish::OdPage::OdPage ( )

Creates a page object.

◆ ~OdPage()

virtual OdPdfPublish::OdPage::~OdPage ( )
virtual

Destroys a page object.

Member Function Documentation

◆ add2dGeometry() [1/2]

void OdPdfPublish::OdPage::add2dGeometry ( const Od2dGeometryReferencePtr &  geom)

◆ add2dGeometry() [2/2]

void OdPdfPublish::OdPage::add2dGeometry ( const Od2dGeometryReferencePtr &  geom,
const OdRect location 
)

◆ addAnnotation()

void OdPdfPublish::OdPage::addAnnotation ( const OdAnnotationPtr &  annotation,
const OdRect location 
)

Adds a new <link OdPdfPublish::OdAnnotation, annotation> to the page.

Parameters
annotation[in] A smart pointer to an annotation object that should be added.
location[in] A rectangle that specifies the location of added annotation within the page. It determines where the annotation will be placed at the page.
See also
<link OdPdfPublish::OdAnnotation, OdAnnotation class>.

◆ addButton()

void OdPdfPublish::OdPage::addButton ( const OdButtonPtr &  button,
const OdRect location 
)

Adds a <link OdPdfPublish::OdButton, button control> to the page.

Parameters
button[in] A smart pointer to a button control that should be added.
location[in] A rectangle that specifies the location of added button control within the page. It determines where the button control will be placed at the page.
See also
<link OdPdfPublish::OdButton, OdButton class>.

◆ addCheckBox()

void OdPdfPublish::OdPage::addCheckBox ( const OdCheckBoxPtr &  check_box,
const OdRect location 
)

Adds a <link OdPdfPublish::OdCheckBox, checkbox> to the page.

Parameters
check_box[in] A smart pointer to a checkbox object that should be added.
location[in] A rectangle that specifies the location of added checkbox within the page. It determines where the checkbox is placed at the page.
See also
<link OdPdfPublish::OdCheckBox, OdCheckBox class>.

◆ addDropDownList()

void OdPdfPublish::OdPage::addDropDownList ( const OdDropDownListPtr &  drop_down_list,
const OdRect location 
)

Adds a <link OdPdfPublish::OdDropDownList, drop-down list> (combo box) to the page.

Parameters
drop_down_list[in] A smart pointer to a drop-down list object that should be added.
location[in] A rectangle that specifies the location of added drop-down list within the page. It determines where the drop-down list is placed at the page.
See also
<link OdPdfPublish::OdDropDownList, OdDropDownList class>.

◆ addImage()

void OdPdfPublish::OdPage::addImage ( const OdImagePtr &  image,
const OdRect location 
)

Adds an <link OdPdfPublish::OdImage, image> to the page.

Parameters
image[in] A smart pointer to an image object that should be added.
location[in] A rectangle that specifies the location of added image within the page. It determines where the image will be placed at the page.
See also
<link OdPdfPublish::OdImage, OdImage class>.

◆ addJavaScriptActionByField()

void OdPdfPublish::OdPage::addJavaScriptActionByField ( const OdString field_name,
const OdString source,
const Action::Type  action_type 
)

◆ addLink()

void OdPdfPublish::OdPage::addLink ( const OdLinkPtr &  link,
const OdRect location 
)

Adds a <link OdPdfPublish::OdLink, link> to the page.

Parameters
link[in] A smart pointer to a link object that should be added.
location[in] A rectangle that specifies the location of added link within the page. It determines where the link will be placed at the page.
See also
<link OdPdfPublish::OdLink, OdLink class>.

◆ addListBox()

void OdPdfPublish::OdPage::addListBox ( const OdListBoxPtr &  list_box,
const OdRect location 
)

Adds a <link OdPdfPublish::OdListBox, list box> to the page.

Parameters
list_box[in] A smart pointer to a list box object that should be added.
location[in] A rectangle that specifies the location of added list box within the page. It determines where the list box is placed at the page.
See also
<link OdPdfPublish::OdListBox, OdListBox class>.

◆ addRadioButton()

void OdPdfPublish::OdPage::addRadioButton ( const OdRadioButtonPtr &  radio_button,
const OdRect location 
)

Adds a <OdPdfPublish::OdRadioButton, radio button> to the page.

Parameters
radio_button[in] A smart pointer to a radio button object that should be added.
location[in] A rectangle that specifies the location of added radio button within the page. It determines where the radio button is placed at the page.
See also
<link OdPdfPublish::OdRadioButton, OdRadioButton class>.

◆ addSignatureField()

void OdPdfPublish::OdPage::addSignatureField ( const OdSignatureFieldPtr &  signature_field,
const OdRect location 
)

Adds a <link OdPdfPublish::OdSignatureField, signature field> to the page.

Parameters
signature_field[in] A smart pointer to a signature field object that should be added.
location[in] A rectangle that specifies the location of added signature field within the page. It determines where the signature field is placed at the page.
See also
<link OdPdfPublish::OdSignatureField, OdSignatureField class>.

◆ addSlideTable()

void OdPdfPublish::OdPage::addSlideTable ( const OdSlideTablePtr &  slide_table,
const OdRect location 
)

Adds a <link OdPdfPublish::OdSlideTable, table with slides> to the page.

Parameters
slide_table[in] A smart pointer to a slide table object that should be added.
location[in] A rectangle that specifies the location of added slide table within the page. It determines where the slide table is placed at the page.
See also
<link OdPdfPublish::OdSlideTable, OdSlideTable class>.

◆ addTable()

void OdPdfPublish::OdPage::addTable ( const OdTablePtr &  table,
const OdRect location 
)

Adds a <link OdPdfPublish::OdTable, table> to the page.

Parameters
table[in] A smart pointer to a table object that should be added.
location[in] A rectangle that specifies the location of added table within the page. It determines where the table will be placed at the page.
See also
<link OdPdfPublish::OdTable, OdTable class>.

◆ addText()

void OdPdfPublish::OdPage::addText ( const OdTextPtr &  text,
const OdRect location 
)

Adds a <link OdPdfPublish::OdText, text> label to the page.

Parameters
text[in] A smart pointer to a text label that should be added.
location[in] A rectangle that specifies the location of added text label within the page. It determines where the text will be placed at the page.
See also
<link OdPdfPublish::OdText, OdText class>.

◆ addTextField()

void OdPdfPublish::OdPage::addTextField ( const OdTextFieldPtr &  text_field,
const OdRect location 
)

Adds a <link OdPdfPublish::OdTextField, text field> to the page.

Parameters
text_field[in] A smart pointer to a text field object that should be added.
location[in] A rectangle that specifies the location of added text field within the page. It determines where the text field will be placed at the page.
See also
<link OdPdfPublish::OdTextField, OdTextField class>.

◆ get2dGeoms()

void OdPdfPublish::OdPage::get2dGeoms ( Od2dGeometryReferencePtrArray &  geoms,
OdRectArray locations 
) const

◆ getAnnotations()

void OdPdfPublish::OdPage::getAnnotations ( OdAnnotationPtrArray &  annotations,
OdRectArray locations 
) const

Returns all <link OdPdfPublish::OdAnnotation, annotations>, which the page contains, and their locations. The method fills two passed arrays with annotation objects and their locations, then returns these arrays to a calling subroutine.

Parameters
annotations[out] A placeholder for the page annotations array.
locations[out] A placeholder for the annotation locations array.
See also
<link OdPdfPublish::OdAnnotation, OdAnnotation class>.

◆ getButtons()

void OdPdfPublish::OdPage::getButtons ( OdButtonPtrArray &  buttons,
OdRectArray locations 
) const

Returns all <link OdPdfPublish::OdButton, buttons>, which the page contains, and their locations. The method fills two passed arrays with button objects and their locations, then returns these arrays to a calling subroutine.

Parameters
buttons[out] A placeholder for the page button array.
locations[out] A placeholder for the link locations array.
See also
<link OdPdfPublish::OdButton, OdButton class>.

◆ getCheckBoxes()

void OdPdfPublish::OdPage::getCheckBoxes ( OdCheckBoxPtrArray &  check_boxes,
OdRectArray locations 
) const

Returns all <link OdPdfPublish::OdCheckBox, checkboxes>, which the page contains, and their locations. The method fills two passed arrays with checkboxes objects and their locations, then returns these arrays to a calling subroutine.

Parameters
check_boxes[out] A placeholder for the page checkbox array.
locations[out] A placeholder for the checkbox locations array.
See also
<link OdPdfPublish::OdCheckBox, OdCheckBox class>.

◆ getDropDownLists()

void OdPdfPublish::OdPage::getDropDownLists ( OdDropDownListPtrArray &  drop_down_lists,
OdRectArray locations 
) const

Returns all <link OdPdfPublish::OdDropDownList, drop-down lists>, which the page contains, and their locations. The method fills two passed arrays with drop-down list objects and their locations, then returns these arrays to a calling subroutine.

Parameters
drop_down_list[out] A placeholder for the page drop-down lists array.
locations[out] A placeholder for the drop-down list locations array.

<link OdPdfPublish::OdDropDownList, OdDropDownList class>.

◆ getFormat()

void OdPdfPublish::OdPage::getFormat ( Page::Format format) const

Returns current page format value.

Parameters
format[out] A placeholder for the format value. Format value is stored here to be returned to the calling subroutine.
See also
<link OdPdfPublish::Page::Format, Page::Format enumeration>.

◆ getImages()

void OdPdfPublish::OdPage::getImages ( OdImagePtrArray &  images,
OdRectArray locations 
) const

Returns all <link OdPdfPublish::OdImage, images>, which the page contains, and their locations. The method fills two passed arrays with image objects and their locations, then returns these arrays to a calling subroutine.

Parameters
images[out] A placeholder for the page images array.
locations[out] A placeholder for the image locations array.
See also
<link OdPdfPublish::OdImage, OdImage class>.

◆ getJavaScriptActionsByField()

void OdPdfPublish::OdPage::getJavaScriptActionsByField ( const OdString field_name,
OdStringArray sources,
OdActionTypeArray action_types 
) const

◆ getLinks()

void OdPdfPublish::OdPage::getLinks ( OdLinkPtrArray &  links,
OdRectArray locations 
) const

Returns all <link OdPdfPublish::OdLink, links>, which the page contains, and their locations. The method fills two passed arrays with link objects and their locations, then returns these arrays to a calling subroutine.

Parameters
links[out] A placeholder for the page link array.
locations[out] A placeholder for the link locations array.
See also
<link OdPdfPublish::OdLink, OdLink class>.

◆ getListBoxes()

void OdPdfPublish::OdPage::getListBoxes ( OdListBoxPtrArray &  list_boxes,
OdRectArray locations 
) const

Returns all <link OdPdfPublish::OdListBox, list boxes>, which the page contains, and their locations. The method fills two passed arrays with list box objects and their locations, then returns these arrays to a calling subroutine.

Parameters
list_boxes[out] A placeholder for the page list boxes array.
locations[out] A placeholder for the list box locations array.
See also
<link OdPdfPublish::OdListBox, OdListBox class>.

◆ getOrientation()

void OdPdfPublish::OdPage::getOrientation ( Page::Orientation orientation) const

Returns current page orientation value.

Parameters
orientation[out] A placeholder for the orientation value. Format value is stored here to be returned to the calling subroutine.
See also
<link OdPdfPublish::Page::Orientation, Page::Orientation enumeration>.

◆ getPaperSize()

void OdPdfPublish::OdPage::getPaperSize ( const Page::PaperUnits  units,
double &  width,
double &  height 
) const

◆ getRadioButtons()

void OdPdfPublish::OdPage::getRadioButtons ( OdRadioButtonPtrArray &  radio_buttons,
OdRectArray locations 
) const

Returns all <link OdPdfPublish::OdRadionButton, radio buttons>, which the page contains, and their locations. The method fills two passed arrays with radion button objects and their locations, then returns these arrays to a calling subroutine.

Parameters
radio_buttons[out] A placeholder for the page radio buttons array.
locations[out] A placeholder for the radio button locations array.
See also
<link OdPdfPublish::OdRadionButton, OdRadionButton class>.

◆ getSignatureFields()

void OdPdfPublish::OdPage::getSignatureFields ( OdSignatureFieldPtrArray &  signature_fields,
OdRectArray locations 
) const

Returns all <link OdPdfPublish::OdSignatureField, signature fields>, which the page contains, and their locations. The method fills two passed arrays with signature field objects and their locations, then returns these arrays to a calling subroutine.

Parameters
signature_fields[out] A placeholder for the page signature fields array.
locations[out] A placeholder for the signature field locations array.
See also
<link OdPdfPublish::OdSignatureField, OdSignatureField class>.

◆ getSlideTables()

void OdPdfPublish::OdPage::getSlideTables ( OdSlideTablePtrArray &  slide_tables,
OdRectArray locations 
) const

Returns all <link OdPdfPublish::OdSlideTable, slide tables>, which the page contains, and their locations. The method fills two passed arrays with slide table objects and their locations, then returns these arrays to a calling subroutine.

Parameters
slide_tables[out] A placeholder for the page slide tables array.
locations[out] A placeholder for the slide table locations array.
See also
<link OdPdfPublish::OdSlideTable, OdSlideTable class>.

◆ getTables()

void OdPdfPublish::OdPage::getTables ( OdTablePtrArray &  tables,
OdRectArray locations 
) const

Returns all <link OdPdfPublish::OdTable, tables>, which the page contains, and their locations. The method fills two passed arrays with table objects and their locations, then returns these arrays to a calling subroutine.

Parameters
tables[out] A placeholder for the page tables array.
locations[out] A placeholder for the table locations array.

<link OdPdfPublish::OdTable, OdTable class>.

◆ getTextFields()

void OdPdfPublish::OdPage::getTextFields ( OdTextFieldPtrArray &  text_fields,
OdRectArray locations 
) const

Returns all <link OdPdfPublish::OdTextField, text fields>, which the page contains, and their locations. The method fills two passed arrays with text field objects and their locations, then returns these arrays to a calling subroutine.

Parameters
text_fields[out] A placeholder for the page text fields array.
locations[out] A placeholder for the text field locations array.
See also
<link OdPdfPublish::OdTextField, OdTextField class>.

◆ getTexts()

void OdPdfPublish::OdPage::getTexts ( OdTextPtrArray &  texts,
OdRectArray locations 
) const

Returns all <link OdPdfPublish::OdText, text labels>, which the page contains, and their locations. The method fills two passed arrays with text label objects and their locations, then returns these arrays to a calling subroutine.

Parameters
texts[out] A placeholder for the page text labels array.
locations[out] A placeholder for the text label locations array.
See also
<link OdPdfPublish::OdText, OdText class>.

◆ ODRX_DECLARE_MEMBERS()

OdPdfPublish::OdPage::ODRX_DECLARE_MEMBERS ( OdPage  )

◆ ODRX_HEAP_OPERATORS()

OdPdfPublish::OdPage::ODRX_HEAP_OPERATORS ( )

◆ setFormat()

void OdPdfPublish::OdPage::setFormat ( Page::Format  format)

Sets the page format.

Parameters
format[in] A new page format value.
See also
<link OdPdfPublish::Page::Format, Page::Format enumeration>.

◆ setOrientation()

void OdPdfPublish::OdPage::setOrientation ( Page::Orientation  orientation)

Sets the page orientation.

Parameters
orientation[in] A new page orientation value.
See also
<link OdPdfPublish::Page::Orientation, Page::Orientation enumeration>.

◆ setPaperSize()

void OdPdfPublish::OdPage::setPaperSize ( const Page::PaperUnits  units,
const double  width,
const double  height 
)

The documentation for this class was generated from the following file: