1 /////////////////////////////////////////////////////////////////////////////
3 // Purpose: wxPrintDialog, wxPageSetupDialog classes
4 // Author: Julian Smart
8 // Copyright: (c) Julian Smart
9 // Licence: wxWindows licence
10 /////////////////////////////////////////////////////////////////////////////
12 #ifndef _WX_PRINTDLG_H_
13 #define _WX_PRINTDLG_H_
15 #if wxUSE_PRINTING_ARCHITECTURE
17 #include "wx/dialog.h"
18 #include "wx/cmndata.h"
19 #include "wx/prntbase.h"
20 #include "wx/printdlg.h"
22 class WXDLLEXPORT wxDC
;
24 //----------------------------------------------------------------------------
25 // wxWindowsPrintNativeData
26 //----------------------------------------------------------------------------
28 class WXDLLEXPORT wxWindowsPrintNativeData
: public wxPrintNativeDataBase
31 wxWindowsPrintNativeData();
32 virtual ~wxWindowsPrintNativeData();
34 virtual bool TransferTo( wxPrintData
&data
);
35 virtual bool TransferFrom( const wxPrintData
&data
);
37 virtual bool Ok() const;
39 void* GetDevMode() const { return m_devMode
; }
40 void SetDevMode(void* data
) { m_devMode
= data
; }
41 void* GetDevNames() const { return m_devNames
; }
42 void SetDevNames(void* data
) { m_devNames
= data
; }
48 short m_customWindowsPaperId
;
51 DECLARE_DYNAMIC_CLASS(wxWindowsPrintNativeData
)
54 // ---------------------------------------------------------------------------
55 // wxWindowsPrintDialog: the MSW dialog for printing
56 // ---------------------------------------------------------------------------
58 class WXDLLEXPORT wxWindowsPrintDialog
: public wxPrintDialogBase
61 wxWindowsPrintDialog(wxWindow
*parent
, wxPrintDialogData
* data
= NULL
);
62 wxWindowsPrintDialog(wxWindow
*parent
, wxPrintData
* data
);
63 virtual ~wxWindowsPrintDialog();
65 bool Create(wxWindow
*parent
, wxPrintDialogData
* data
= NULL
);
66 virtual int ShowModal();
68 wxPrintDialogData
& GetPrintDialogData() { return m_printDialogData
; }
69 wxPrintData
& GetPrintData() { return m_printDialogData
.GetPrintData(); }
70 virtual wxDC
*GetPrintDC();
73 wxPrintDialogData m_printDialogData
;
76 wxWindow
* m_dialogParent
;
79 bool ConvertToNative( wxPrintDialogData
&data
);
80 bool ConvertFromNative( wxPrintDialogData
&data
);
86 DECLARE_NO_COPY_CLASS(wxWindowsPrintDialog
)
87 DECLARE_CLASS(wxWindowsPrintDialog
)
90 // ---------------------------------------------------------------------------
91 // wxWindowsPageSetupDialog: the MSW page setup dialog
92 // ---------------------------------------------------------------------------
94 class WXDLLEXPORT wxWindowsPageSetupDialog
: public wxPageSetupDialogBase
97 wxWindowsPageSetupDialog();
98 wxWindowsPageSetupDialog(wxWindow
*parent
, wxPageSetupDialogData
*data
= NULL
);
99 virtual ~wxWindowsPageSetupDialog();
101 bool Create(wxWindow
*parent
, wxPageSetupDialogData
*data
= NULL
);
102 virtual int ShowModal();
103 bool ConvertToNative( wxPageSetupDialogData
&data
);
104 bool ConvertFromNative( wxPageSetupDialogData
&data
);
106 virtual wxPageSetupData
& GetPageSetupDialogData() { return m_pageSetupData
; }
109 wxPageSetupDialogData m_pageSetupData
;
110 wxWindow
* m_dialogParent
;
116 DECLARE_DYNAMIC_CLASS_NO_COPY(wxWindowsPageSetupDialog
)
119 #endif // wxUSE_PRINTING_ARCHITECTURE