wx.PrintDialogData¶This class holds information related to the visual characteristics of wx.PrintDialog.
It contains a wx.PrintData object with underlying printing settings.
Class Hierarchy¶
Inheritance diagram for class PrintDialogData:
Methods Summary¶Default constructor. |
|
Allows or disallows selecting printing the “Current Page” in the dialog. |
|
Enables or disables the “Help” button. |
|
Enables or disables the “Page numbers” controls. |
|
Enables or disables the “Print to file” checkbox. |
|
Enables or disables the “Selection” radio button. |
|
Returns |
|
Returns |
|
Returns |
|
Returns the from page number, as entered by the user. |
|
Returns the maximum page number. |
|
Returns the maximum number of page ranges that the user can specify. |
|
Returns the minimum page number. |
|
Returns the number of copies requested by the user. |
|
Returns the page ranges to print. |
|
Returns a reference to the internal wx.PrintData object. |
|
Returns |
|
Returns |
|
Returns |
|
Returns the “print to” page number, as entered by the user. |
|
Returns |
|
Selects the “All pages” radio button. |
|
Sets the “Collate” checkbox to |
|
Selects the “Current Page” radio button when the dialog is initially shown. |
|
Sets the from page number. |
|
Sets the maximum page number. |
|
Sets the maximum number of page ranges that the user can specify. |
|
Sets the minimum page number. |
|
Sets the default number of copies the user has requested to be printed out. |
|
Sets the internal wx.PrintData. |
|
Sets the “Print to file” checkbox to |
|
Selects the “Selection” radio button. |
|
Sets the “print to” page number. |
|
Properties Summary¶See |
|
See |
|
See |
|
See |
|
See |
|
See |
|
See |
|
See |
|
See |
|
See |
|
See |
|
See |
|
Class API¶Possible constructors:
PrintDialogData() -> None
PrintDialogData(dialogData) -> None
PrintDialogData(printData) -> None
This class holds information related to the visual characteristics of PrintDialog.
__init__ (self)
Default constructor.
None
__init__ (self, dialogData)
Copy constructor.
dialogData (wx.PrintDialogData)
None
__init__ (self, printData)
Construct an object from a print dialog data object.
printData (wx.PrintData)
None
Allows or disallows selecting printing the “Current Page” in the dialog.
This currently only has an effect under MSW, where the native dialog enables the “Current Page” radio button if this function is called to allow the user to print the current page only.
flag (bool)
None
Added in version 4.3/wxWidgets-3.3.0.
Enables or disables the “Help” button.
flag (bool)
None
Enables or disables the “Page numbers” controls.
flag (bool)
None
Enables or disables the “Print to file” checkbox.
flag (bool)
None
Enables or disables the “Selection” radio button.
flag (bool)
None
Returns True if the user requested that all pages be printed.
bool
Returns True if the user requested that the document(s) be collated.
bool
Returns True if the user requested that the current page be printed.
Note that the “current page” is defined by the application.
It only makes sense to call this function if EnableCurrentPage had been called before, otherwise it always returns False.
bool
Added in version 4.3/wxWidgets-3.3.0.
Returns the from page number, as entered by the user.
This function can’t be used if multiple page ranges were specified, use GetPageRanges instead.
int
Returns the maximum page number.
int
Returns the maximum number of page ranges that the user can specify.
int
Added in version 4.3/wxWidgets-3.3.0.
See also
SetMaxRanges()
Returns the minimum page number.
int
Returns the number of copies requested by the user.
int
Returns the page ranges to print.
This vector contains the page ranges to be printed. If it is empty, all pages are printed, otherwise only the pages in the specified ranges are.
PrintPageRanges
Added in version 4.3/wxWidgets-3.3.0.
See also
SetPageRanges
Returns a reference to the internal wx.PrintData object.
Returns True if the user has selected printing to a file.
bool
Returns True if the user requested that the selection be printed (where “selection” is a concept specific to the application).
bool
Returns True if the user requested printing only the specified pages.
The pages to print can be retrieved using GetPageRanges .
bool
Added in version 4.3/wxWidgets-3.3.0.
Returns the “print to” page number, as entered by the user.
This function can’t be used if multiple page ranges were specified, use GetPageRanges instead.
int
Returns True if the print data is valid for using in print dialogs.
This can return False on Windows if the current printer is not set, for example. On all other platforms, it returns True.
bool
Selects the “All pages” radio button.
When called with True value, enables printing all pages. This is the default behaviour.
If flag is False, this function doesn’t do anything unless it had been called with True value before and in this case it switches to printing the selected pages only (see GetSpecifiedPages ).
flag (bool)
None
Sets the “Collate” checkbox to True or False.
flag (bool)
None
Selects the “Current Page” radio button when the dialog is initially shown.
This function can only be called when EnableCurrentPage is used as well.
If flag is False, this function doesn’t do anything unless it had been called with True value before and in this case it switches to printing the selected pages only (see GetSpecifiedPages ).
flag (bool)
None
Added in version 4.3/wxWidgets-3.3.0.
See also
Sets the from page number.
Together with SetToPage , this function can be used to define a single range of pages to print. If you need to specify multiple ranges, use SetPageRanges instead.
page (int)
None
Note
If SetPageRanges was used to specify multiple ranges, this function cannot be used as there is no single “from” page to set.
Sets the maximum page number.
page (int)
None
Sets the maximum number of page ranges that the user can specify.
This value is used as a limit for the number of page ranges that can be used in the print dialog. The default value is 64.
Currently this is only used in wxMSW.
maxRanges (int)
None
Added in version 4.3/wxWidgets-3.3.0.
Sets the minimum page number.
page (int)
None
Sets the default number of copies the user has requested to be printed out.
n (int)
None
Sets the internal wx.PrintData.
printData (wx.PrintData)
None
Sets the “Print to file” checkbox to True or False.
flag (bool)
None
Selects the “Selection” radio button.
The effect of printing the selection depends on how the application implements this command, if at all.
This function should only be called when EnableSelection is used as well.
If flag is False, this function doesn’t do anything unless it had been called with True value before and in this case it switches to printing the selected pages only (see GetSpecifiedPages ).
flag (bool)
None
Sets the “print to” page number.
Together with SetFromPage , this function can be used to define a single range of pages to print. If you need to specify multiple ranges, use SetPageRanges instead.
page (int)
None
Note
If SetPageRanges was used to specify multiple ranges, this function cannot be used as there is no single “to” page to set.
bool
bool
See GetAllPages and SetAllPages
See GetCollate and SetCollate
See GetCurrentPage and SetCurrentPage
See GetFromPage and SetFromPage
See GetMaxPage and SetMaxPage
See GetMaxPageRanges and SetMaxPageRanges
See GetMinPage and SetMinPage
See GetNoCopies and SetNoCopies
See GetPageRanges
See GetPrintData and SetPrintData
See GetPrintToFile and SetPrintToFile
See GetSelection and SetSelection