X-Git-Url: https://git.saurik.com/wxWidgets.git/blobdiff_plain/fadc2df6823d988f7a264b94e69a7e1bbcac1337..efb091829601cf07df6c4316a3f6f705aaa81587:/interface/wx/print.h diff --git a/interface/wx/print.h b/interface/wx/print.h index b6f61dba8b..c782f96c9a 100644 --- a/interface/wx/print.h +++ b/interface/wx/print.h @@ -145,7 +145,7 @@ public: const wxPoint& pos = wxDefaultPosition, const wxSize& size = wxDefaultSize, long style = wxDEFAULT_FRAME_STYLE, - const wxString& name = "frame"); + const wxString& name = wxFrameNameStr); /** Destructor. @@ -231,8 +231,8 @@ public: Use IsOk() to check whether the wxPrintPreview object was created correctly. */ wxPrintPreview(wxPrintout* printout, - wxPrintout* printoutForPrinting, - wxPrintData* data = NULL); + wxPrintout* printoutForPrinting = NULL, + wxPrintDialogData* data = NULL); /** Destructor. @@ -295,7 +295,7 @@ public: The implementation simply blits the preview bitmap onto the canvas, creating a new preview bitmap if none exists. */ - bool PaintPage(wxPreviewCanvas* canvas, wxDC dc); + virtual bool PaintPage(wxPreviewCanvas* canvas, wxDC& dc); /** Invokes the print process using the second wxPrintout object @@ -321,7 +321,7 @@ public: /** Sets the current page to be previewed. */ - void SetCurrentPage(int pageNum); + virtual bool SetCurrentPage(int pageNum); /** Sets the frame to be used for displaying the print preview canvas @@ -373,7 +373,7 @@ public: /** Creates the default printing abort window, with a cancel button. */ - void CreateAbortWindow(wxWindow* parent, wxPrintout* printout); + virtual wxWindow* CreateAbortWindow(wxWindow* parent, wxPrintout* printout); /** Returns @true if the user has aborted the print job. @@ -586,6 +586,11 @@ public: @beginWxPythonOnly This method returns the output-only parameters as a tuple. @endWxPythonOnly + + @beginWxPerlOnly + In wxPerl this method takes no arguments and returns a + 2-element list (w, h). + @endWxPerlOnly */ void GetPPIPrinter(int* w, int* h) const; @@ -601,6 +606,11 @@ public: @beginWxPythonOnly This method returns the output-only parameters as a tuple. @endWxPythonOnly + + @beginWxPerlOnly + In wxPerl this method takes no arguments and returns a + 2-element list (w, h). + @endWxPerlOnly */ void GetPPIScreen(int* w, int* h) const; @@ -630,6 +640,11 @@ public: @beginWxPythonOnly This method returns the output-only parameters as a tuple. @endWxPythonOnly + + @beginWxPerlOnly + In wxPerl this method takes no arguments and returns a + 2-element list (w, h). + @endWxPerlOnly */ void GetPageSizeMM(int* w, int* h) const; @@ -646,6 +661,11 @@ public: @beginWxPythonOnly This method returns the output-only parameters as a tuple. @endWxPythonOnly + + @beginWxPerlOnly + In wxPerl this method takes no arguments and returns a + 2-element list (w, h). + @endWxPerlOnly */ void GetPageSizePixels(int* w, int* h) const; @@ -688,9 +708,26 @@ public: /** Returns @true if the printout is currently being used for previewing. + + @see GetPreview() */ virtual bool IsPreview() const; + /** + Returns the associated preview object if any. + + If this printout object is used for previewing, returns the associated + wxPrintPreview. Otherwise returns @NULL. + + The returned pointer is not owned by the printout and must not be + deleted. + + @see IsPreview() + + @since 2.9.1. + */ + wxPrintPreview *GetPreview() const; + /** Set the user scale and device origin of the wxDC associated with this wxPrintout so that one screen pixel maps to one device pixel on the DC.