CFx SDK Documentation 2026 SP0
Loading...
Searching...
No Matches
OdPdfPublish::OdBookmark Class Reference

#include <PdfPublishBookmark.h>

Inheritance diagram for OdPdfPublish::OdBookmark:
OdPdfPublish::OdObject OdRxObject

Public Member Functions

 ODRX_DECLARE_MEMBERS (OdBookmark)
 
 ODRX_HEAP_OPERATORS ()
 
virtual ~OdBookmark ()
 
void setTitle (const OdString &title)
 
void setPage (OdPagePtr page)
 
void setBookmarkType (const Bookmarks::BookmarkType type)
 
void setTextStyle (const Text::FontStyle style)
 
void setTextColor (const ODCOLORREF color)
 
void appendChild (const OdBookmarkPtr child)
 
void setChildren (const OdBookmarkPtrArray &children)
 
void setParametrs (const OdArray< double > &params)
 
void getTitle (OdString &title) const
 
void getPage (OdPagePtr &page) const
 
void getBookmarkType (Bookmarks::BookmarkType &type) const
 
void getTextStyle (Text::FontStyle &style) const
 
void getTextColor (ODCOLORREF &color) const
 
void getChildren (OdBookmarkPtrArray &children) const
 
void getParametrs (OdArray< double > &params) 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
 

Protected Member Functions

 OdBookmark ()
 
- Protected Member Functions inherited from OdPdfPublish::OdObject
 OdObject (OdPublishObjectImpl *pImpl)
 

Additional Inherited Members

- Static Public Member Functions inherited from OdRxObject
static OdRxObjectPtr cast (const OdRxObject *pointer)
 
static OdRxClassdesc ()
 
static void rxInit ()
 
static void rxUninit ()
 

Detailed Description

This class implements working with a bookmark encapsulated in a PDF document created with Publish SDK. A bookmark is a kind of link with descriptive text that makes it easy to navigate through a PDF document.

Definition at line 55 of file PdfPublishBookmark.h.

Constructor & Destructor Documentation

◆ OdBookmark()

OdPdfPublish::OdBookmark::OdBookmark ( )
protected

◆ ~OdBookmark()

virtual OdPdfPublish::OdBookmark::~OdBookmark ( )
virtual

Destroys the bookmark object.

Member Function Documentation

◆ appendChild()

void OdPdfPublish::OdBookmark::appendChild ( const OdBookmarkPtr child)

Appends a new child bookmark to the current bookmark.

Parameters
child[in] A smart pointer to the descendant <link OdPdfPublish::OdBookmark, OdBookmark> object.

◆ getBookmarkType()

void OdPdfPublish::OdBookmark::getBookmarkType ( Bookmarks::BookmarkType & type) const

Returns the type of the bookmark object. The method fills a passed <link OdPdfPublish::Bookmarks::BookmarkType, Bookmarks::BookmarkType enumeration> value with the current bookmark type value and returns it to a calling subroutine.

Parameters
type[out] A placeholder for the <link OdPdfPublish::Bookmarks::BookmarkType, bookmark type> value.
See also
<link OdPdfPublish::Bookmarks::BookmarkType, Bookmarks::BookmarkType enumeration>

◆ getChildren()

void OdPdfPublish::OdBookmark::getChildren ( OdBookmarkPtrArray & children) const

Returns the descendant bookmarks of the bookmark object. This method fills the passed array with the set of descendant <link OdPdfPublish::OdBookmark, OdBookmark> objects and returns it to a calling subroutine.

Parameters
children[out] A placeholder for the array of smart pointers to descendant <link OdPdfPublish::OdBookmark, OdBookmark> objects.

◆ getPage()

void OdPdfPublish::OdBookmark::getPage ( OdPagePtr & page) const

Returns the page the bookmark object refers to. The method fills a passed parameter with the smart pointer to an <link OdPdfPublish::OdPage, OdPage> object and returns it to a calling subroutine.

Parameters
page[out] A placeholder for the <link OdPdfPublish::OdPage, page> the bookmark refers to.
See also
<link OdPdfPublish::OdPage, OdPage class>.

◆ getParametrs()

void OdPdfPublish::OdBookmark::getParametrs ( OdArray< double > & params) const

Returns parameters of the current bookmark. This method fills the passed array of doubles with parameter values and returns it to a calling subroutine.

Parameters
params[out] A placeholder for the array of parameter values of the current bookmark object.
Remarks
The number of parameters and their values depend on the type of the bookmark object: <link OdPdfPublish::Bookmarks::BookmarkType::kXYZ, BookmarkType::kXYZ>: coordinates (left, top) and the zoom scale factor. <link OdPdfPublish::Bookmarks::BookmarkType::kFit, BookmarkType::kFit>: parameters are not required. <link OdPdfPublish::Bookmarks::BookmarkType::kFitH, BookmarkType::kFitH>: top coordinate. <link OdPdfPublish::Bookmarks::BookmarkType::kFitV, BookmarkType::kFitV>: left coordinate. <link OdPdfPublish::Bookmarks::BookmarkType::kFitR, BookmarkType::kFitR>: left, bottom, right, and top coordinates. <link OdPdfPublish::Bookmarks::BookmarkType::kFitB, BookmarkType::kFitB>: parameters are not required. <link OdPdfPublish::Bookmarks::BookmarkType::kFitBH, BookmarkType::kFitBH>: top coordinate. <link OdPdfPublish::Bookmarks::BookmarkType::kFitBV, BookmarkType::kFitBV>: left coordinate.
See also
<link OdPdfPublish::Bookmarks::BookmarkType, Bookmarks::BookmarkType enumeration>

◆ getTextColor()

void OdPdfPublish::OdBookmark::getTextColor ( ODCOLORREF & color) const

Returns the current color of the bookmark title. The method fills a passed ODCOLORREF value with the current bookmark title color and returns it to a calling subroutine.

Parameters
color[out] A placeholder for the color of the bookmark title.

◆ getTextStyle()

void OdPdfPublish::OdBookmark::getTextStyle ( Text::FontStyle & style) const

Returns the <link OdPdfPublish::Text::FontStyle, font style> of the bookmark title. The method fills a passed <link OdPdfPublish::Text::FontStyle, Text::FontStyle enumeration> value and returns it to a calling subroutine.

Parameters
style[out] A placeholder for the <link OdPdfPublish::Text::FontStyle, font style> of the bookmark title.
See also
<link OdPdfPublish::Text::FontStyle, Text::FontStyle enumeration>

◆ getTitle()

void OdPdfPublish::OdBookmark::getTitle ( OdString & title) const

Returns the bookmark title. The method fills a passed <exref target="https://docs.opendesign.com/tkernel/OdString.html">string</exref> object with the title text and returns this string to a calling subroutine.

Parameters
title[out] A placeholder for the bookmark title.

◆ ODRX_DECLARE_MEMBERS()

OdPdfPublish::OdBookmark::ODRX_DECLARE_MEMBERS ( OdBookmark )

◆ ODRX_HEAP_OPERATORS()

OdPdfPublish::OdBookmark::ODRX_HEAP_OPERATORS ( )

◆ setBookmarkType()

void OdPdfPublish::OdBookmark::setBookmarkType ( const Bookmarks::BookmarkType type)

Sets the bookmark type. Bookmark types are declared in the <link OdPdfPublish::Bookmarks::BookmarkType, Bookmarks::BookmarkType enumeration>.

Parameters
type[in] A new <<link OdPdfPublish::Bookmarks::BookmarkType, bookmark type> value.
See also
<link OdPdfPublish::Bookmarks::BookmarkType, Bookmarks::BookmarkType enumeration>

◆ setChildren()

void OdPdfPublish::OdBookmark::setChildren ( const OdBookmarkPtrArray & children)

Sets descendant bookmarks for the current bookmark.

Parameters
children[in] An array of smart pointers to the descendant <link OdPdfPublish::OdBookmark, OdBookmark> objects.
Remarks
If the bookmark object has descendant bookmarks, they are replaced with new bookmarks.

◆ setPage()

void OdPdfPublish::OdBookmark::setPage ( OdPagePtr page)

Sets the <link OdPdfPublish::OdPage, page> the bookmark object refers to.

Parameters
page[in] A smart pointer to the <link OdPdfPublish::OdPage, OdPage> object that the bookmark object refers to.
See also
<link OdPdfPublish::OdPage, OdPage class>.

◆ setParametrs()

void OdPdfPublish::OdBookmark::setParametrs ( const OdArray< double > & params)

Sets parameters for the bookmark object.

Parameters
params[in] A double array that contains parameter values.
Remarks
The number of parameters and their values depend on the type of the bookmark object: <link OdPdfPublish::Bookmarks::BookmarkType::kXYZ, BookmarkType::kXYZ>: coordinates (left, top) and the zoom scale factor. <link OdPdfPublish::Bookmarks::BookmarkType::kFit, BookmarkType::kFit>: parameters are not required. <link OdPdfPublish::Bookmarks::BookmarkType::kFitH, BookmarkType::kFitH>: top coordinate. <link OdPdfPublish::Bookmarks::BookmarkType::kFitV, BookmarkType::kFitV>: left coordinate. <link OdPdfPublish::Bookmarks::BookmarkType::kFitR, BookmarkType::kFitR>: left, bottom, right, and top coordinates. <link OdPdfPublish::Bookmarks::BookmarkType::kFitB, BookmarkType::kFitB>: parameters are not required. <link OdPdfPublish::Bookmarks::BookmarkType::kFitBH, BookmarkType::kFitBH>: top coordinate. <link OdPdfPublish::Bookmarks::BookmarkType::kFitBV, BookmarkType::kFitBV>: left coordinate. If not all parameter values required by the bookmark type are passed to the method, the bookmark can't be created.
See also
<link OdPdfPublish::Bookmarks::BookmarkType, Bookmarks::BookmarkType enumeration>

◆ setTextColor()

void OdPdfPublish::OdBookmark::setTextColor ( const ODCOLORREF color)

Sets the color for the bookmark title.

Parameters
color[in] A new text color value.

◆ setTextStyle()

void OdPdfPublish::OdBookmark::setTextStyle ( const Text::FontStyle style)

Sets the <link OdPdfPublish::Text::FontStyle, font style> for the bookmark title.

Parameters
style[in] A new <link OdPdfPublish::Text::FontStyle, font style> to apply for the title.
See also
<link OdPdfPublish::Text::FontStyle, Text::FontStyle enumeration>

◆ setTitle()

void OdPdfPublish::OdBookmark::setTitle ( const OdString & title)

Sets the bookmark title.

Parameters
title[in] A <exref target="https://docs.opendesign.com/tkernel/OdString.html">string</exref> that contains the new title text of the bookmark object.

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