wxPdfDocument  1.4.0
Library for generating PDF documents from wxWidgets applications
Loading...
Searching...
No Matches
wxPdfPrintData Class Reference

Class for holding print configuration data. More...

#include <pdfprint.h>

Inheritance diagram for wxPdfPrintData:

Public Member Functions

 wxPdfPrintData ()
 Default constructor.
 wxPdfPrintData (wxPdfPrintData *pdfPrintData)
 Copy constructor.
 wxPdfPrintData (wxPrintData *printData)
 Constructor from wxPrintData.
 wxPdfPrintData (wxPrintDialogData *printDialogData)
 Constructor from wxPrintDialogData.
 wxPdfPrintData (wxPageSetupDialogData *pageSetupDialogData)
 Constructor from wxPageSetupDialogData.
bool Ok () const
 Check whether the print data is valid.
bool IsOk () const
 Check whether the print data is valid.
wxPrintOrientation GetOrientation () const
 Get page orientation.
void SetOrientation (wxPrintOrientation orient)
 Set page orientation.
wxPaperSize GetPaperId () const
 Get paper size ID.
void SetPaperId (wxPaperSize sizeId)
 Set paper size ID.
wxPrintQuality GetQuality () const
 Get print quality.
void SetQuality (wxPrintQuality quality)
 Set print quality.
wxString GetFilename () const
 Get output filename.
void SetFilename (const wxString &filename)
 Set output filename.
int GetFromPage () const
 Get first page to print.
int GetToPage () const
 Get last page to print.
int GetMinPage () const
 Get minimum page number.
int GetMaxPage () const
 Get maximum page number.
void SetFromPage (int v)
 Set first page to print.
void SetToPage (int v)
 Set last page to print.
void SetMinPage (int v)
 Set minimum page number.
void SetMaxPage (int v)
 Set maximum page number.
int GetPrintDialogFlags () const
 Get print dialog flags.
void SetPrintDialogFlags (int flags)
 Set print dialog flags.
void SetTemplate (wxPdfDocument *pdfDocument, double templateWidth, double templateHeight)
 Set template document.
wxPdfDocumentGetTemplateDocument () const
 Get template document.
double GetTemplateWidth () const
 Get template width.
double GetTemplateHeight () const
 Get template height.
bool GetTemplateMode () const
 Get template mode.
int GetPrintResolution () const
 Get print resolution.
void SetPrintResolution (int resolution)
 Set print resolution.
bool GetLaunchDocumentViewer () const
 Get document viewer launch flag.
void SetLaunchDocumentViewer (bool enable)
 Set document viewer launch flag.
const wxString & GetDocumentTitle () const
 Get document title.
const wxString & GetDocumentSubject () const
 Get document subject.
const wxString & GetDocumentAuthor () const
 Get document author.
const wxString & GetDocumentKeywords () const
 Get document keywords.
const wxString & GetDocumentCreator () const
 Get document creator.
void SetDocumentTitle (const wxString &title)
 Set document title.
void SetDocumentSubject (const wxString &subject)
 Set document subject.
void SetDocumentAuthor (const wxString &author)
 Set document author.
void SetDocumentKeywords (const wxString &keywords)
 Set document keywords.
void SetDocumentCreator (const wxString &creator)
 Set document creator.
bool IsProtectionEnabled () const
 Check whether document protection is enabled.
void SetDocumentProtection (int permissions, const wxString &userPassword=wxEmptyString, const wxString &ownerPassword=wxEmptyString, wxPdfEncryptionMethod encryptionMethod=wxPDF_ENCRYPTION_AESV3R6, int keyLength=0)
 Set document protection.
const wxString & GetUserPassword () const
 Get user password.
const wxString & GetOwnerPassword () const
 Get owner password.
int GetPermissions () const
 Get permissions.
wxPdfEncryptionMethod GetEncryptionMethod () const
 Get encryption method.
int GetKeyLength () const
 Get key length.
void ClearDocumentProtection ()
 Clear document protection settings.
void UpdateDocument (wxPdfDocument *pdfDoc)
 Update document metadata and protection settings.
wxPrintData * CreatePrintData () const
 Create wxPrintData from this instance.

Detailed Description

Class for holding print configuration data.

Constructor & Destructor Documentation

◆ wxPdfPrintData() [1/5]

wxPdfPrintData::wxPdfPrintData ( )

Default constructor.

◆ wxPdfPrintData() [2/5]

wxPdfPrintData::wxPdfPrintData ( wxPdfPrintData * pdfPrintData)

Copy constructor.

Parameters
pdfPrintDataThe data to copy from

◆ wxPdfPrintData() [3/5]

wxPdfPrintData::wxPdfPrintData ( wxPrintData * printData)

Constructor from wxPrintData.

Parameters
printDataThe print data to initialize from

◆ wxPdfPrintData() [4/5]

wxPdfPrintData::wxPdfPrintData ( wxPrintDialogData * printDialogData)

Constructor from wxPrintDialogData.

Parameters
printDialogDataThe print dialog data to initialize from

◆ wxPdfPrintData() [5/5]

wxPdfPrintData::wxPdfPrintData ( wxPageSetupDialogData * pageSetupDialogData)

Constructor from wxPageSetupDialogData.

Parameters
pageSetupDialogDataThe page setup dialog data to initialize from

Member Function Documentation

◆ ClearDocumentProtection()

void wxPdfPrintData::ClearDocumentProtection ( )

Clear document protection settings.

◆ CreatePrintData()

wxPrintData * wxPdfPrintData::CreatePrintData ( ) const

Create wxPrintData from this instance.

Returns
A new wxPrintData instance

◆ GetDocumentAuthor()

const wxString & wxPdfPrintData::GetDocumentAuthor ( ) const
inline

Get document author.

Returns
The document author

◆ GetDocumentCreator()

const wxString & wxPdfPrintData::GetDocumentCreator ( ) const
inline

Get document creator.

Returns
The document creator

◆ GetDocumentKeywords()

const wxString & wxPdfPrintData::GetDocumentKeywords ( ) const
inline

Get document keywords.

Returns
The document keywords

◆ GetDocumentSubject()

const wxString & wxPdfPrintData::GetDocumentSubject ( ) const
inline

Get document subject.

Returns
The document subject

◆ GetDocumentTitle()

const wxString & wxPdfPrintData::GetDocumentTitle ( ) const
inline

Get document title.

Returns
The document title

◆ GetEncryptionMethod()

wxPdfEncryptionMethod wxPdfPrintData::GetEncryptionMethod ( ) const
inline

Get encryption method.

Returns
The encryption method

◆ GetFilename()

wxString wxPdfPrintData::GetFilename ( ) const
inline

Get output filename.

Returns
The output filename

◆ GetFromPage()

int wxPdfPrintData::GetFromPage ( ) const
inline

Get first page to print.

Returns
The first page number

◆ GetKeyLength()

int wxPdfPrintData::GetKeyLength ( ) const
inline

Get key length.

Returns
The encryption key length

◆ GetLaunchDocumentViewer()

bool wxPdfPrintData::GetLaunchDocumentViewer ( ) const
inline

Get document viewer launch flag.

Returns
true if document viewer should be launched, false otherwise

◆ GetMaxPage()

int wxPdfPrintData::GetMaxPage ( ) const
inline

Get maximum page number.

Returns
The maximum page number

◆ GetMinPage()

int wxPdfPrintData::GetMinPage ( ) const
inline

Get minimum page number.

Returns
The minimum page number

◆ GetOrientation()

wxPrintOrientation wxPdfPrintData::GetOrientation ( ) const
inline

Get page orientation.

Returns
The print orientation

◆ GetOwnerPassword()

const wxString & wxPdfPrintData::GetOwnerPassword ( ) const
inline

Get owner password.

Returns
The owner password

◆ GetPaperId()

wxPaperSize wxPdfPrintData::GetPaperId ( ) const
inline

Get paper size ID.

Returns
The paper size ID

◆ GetPermissions()

int wxPdfPrintData::GetPermissions ( ) const
inline

Get permissions.

Returns
The permissions bitmask

◆ GetPrintDialogFlags()

int wxPdfPrintData::GetPrintDialogFlags ( ) const
inline

Get print dialog flags.

Returns
The print dialog flags

◆ GetPrintResolution()

int wxPdfPrintData::GetPrintResolution ( ) const

Get print resolution.

Returns
The print resolution in DPI

◆ GetQuality()

wxPrintQuality wxPdfPrintData::GetQuality ( ) const
inline

Get print quality.

Returns
The print quality

◆ GetTemplateDocument()

wxPdfDocument * wxPdfPrintData::GetTemplateDocument ( ) const
inline

Get template document.

Returns
The template document

◆ GetTemplateHeight()

double wxPdfPrintData::GetTemplateHeight ( ) const
inline

Get template height.

Returns
The template height

◆ GetTemplateMode()

bool wxPdfPrintData::GetTemplateMode ( ) const
inline

Get template mode.

Returns
true if in template mode, false otherwise

◆ GetTemplateWidth()

double wxPdfPrintData::GetTemplateWidth ( ) const
inline

Get template width.

Returns
The template width

◆ GetToPage()

int wxPdfPrintData::GetToPage ( ) const
inline

Get last page to print.

Returns
The last page number

◆ GetUserPassword()

const wxString & wxPdfPrintData::GetUserPassword ( ) const
inline

Get user password.

Returns
The user password

◆ IsOk()

bool wxPdfPrintData::IsOk ( ) const
inline

Check whether the print data is valid.

Returns
true if valid, false otherwise

◆ IsProtectionEnabled()

bool wxPdfPrintData::IsProtectionEnabled ( ) const
inline

Check whether document protection is enabled.

Returns
true if protection is enabled, false otherwise

◆ Ok()

bool wxPdfPrintData::Ok ( ) const
inline

Check whether the print data is valid.

Returns
true if valid, false otherwise

◆ SetDocumentAuthor()

void wxPdfPrintData::SetDocumentAuthor ( const wxString & author)
inline

Set document author.

Parameters
authorThe document author

◆ SetDocumentCreator()

void wxPdfPrintData::SetDocumentCreator ( const wxString & creator)
inline

Set document creator.

Parameters
creatorThe document creator

◆ SetDocumentKeywords()

void wxPdfPrintData::SetDocumentKeywords ( const wxString & keywords)
inline

Set document keywords.

Parameters
keywordsThe document keywords

◆ SetDocumentProtection()

void wxPdfPrintData::SetDocumentProtection ( int permissions,
const wxString & userPassword = wxEmptyString,
const wxString & ownerPassword = wxEmptyString,
wxPdfEncryptionMethod encryptionMethod = wxPDF_ENCRYPTION_AESV3R6,
int keyLength = 0 )

Set document protection.

Parameters
permissionsThe permissions bitmask
userPasswordThe user password
ownerPasswordThe owner password
encryptionMethodThe encryption method
keyLengthThe encryption key length

◆ SetDocumentSubject()

void wxPdfPrintData::SetDocumentSubject ( const wxString & subject)
inline

Set document subject.

Parameters
subjectThe document subject

◆ SetDocumentTitle()

void wxPdfPrintData::SetDocumentTitle ( const wxString & title)
inline

Set document title.

Parameters
titleThe document title

◆ SetFilename()

void wxPdfPrintData::SetFilename ( const wxString & filename)
inline

Set output filename.

Parameters
filenameThe output filename

◆ SetFromPage()

void wxPdfPrintData::SetFromPage ( int v)
inline

Set first page to print.

Parameters
vThe first page number

◆ SetLaunchDocumentViewer()

void wxPdfPrintData::SetLaunchDocumentViewer ( bool enable)
inline

Set document viewer launch flag.

Parameters
enabletrue if document viewer should be launched, false otherwise

◆ SetMaxPage()

void wxPdfPrintData::SetMaxPage ( int v)
inline

Set maximum page number.

Parameters
vThe maximum page number

◆ SetMinPage()

void wxPdfPrintData::SetMinPage ( int v)
inline

Set minimum page number.

Parameters
vThe minimum page number

◆ SetOrientation()

void wxPdfPrintData::SetOrientation ( wxPrintOrientation orient)
inline

Set page orientation.

Parameters
orientThe print orientation

◆ SetPaperId()

void wxPdfPrintData::SetPaperId ( wxPaperSize sizeId)
inline

Set paper size ID.

Parameters
sizeIdThe paper size ID

◆ SetPrintDialogFlags()

void wxPdfPrintData::SetPrintDialogFlags ( int flags)
inline

Set print dialog flags.

Parameters
flagsThe print dialog flags

◆ SetPrintResolution()

void wxPdfPrintData::SetPrintResolution ( int resolution)
inline

Set print resolution.

Parameters
resolutionThe print resolution in DPI

◆ SetQuality()

void wxPdfPrintData::SetQuality ( wxPrintQuality quality)
inline

Set print quality.

Parameters
qualityThe print quality

◆ SetTemplate()

void wxPdfPrintData::SetTemplate ( wxPdfDocument * pdfDocument,
double templateWidth,
double templateHeight )

Set template document.

Parameters
pdfDocumentThe template document
templateWidthThe template width
templateHeightThe template height

◆ SetToPage()

void wxPdfPrintData::SetToPage ( int v)
inline

Set last page to print.

Parameters
vThe last page number

◆ UpdateDocument()

void wxPdfPrintData::UpdateDocument ( wxPdfDocument * pdfDoc)

Update document metadata and protection settings.

Parameters
pdfDocThe document to update

The documentation for this class was generated from the following file:
  • E:/github/wxpdfdoc-current/include/wx/pdfprint.h