]> git.saurik.com Git - wxWidgets.git/blob - include/wx/printdlg.h
Don't create multiple parent-less top level frames in layout sample.
[wxWidgets.git] / include / wx / printdlg.h
1 /////////////////////////////////////////////////////////////////////////////
2 // Name: wx/printdlg.h
3 // Purpose: Base header and class for print dialogs
4 // Author: Julian Smart
5 // Modified by:
6 // Created:
7 // RCS-ID: $Id$
8 // Copyright: (c) Julian Smart
9 // Licence: wxWindows Licence
10 /////////////////////////////////////////////////////////////////////////////
11
12 #ifndef _WX_PRINTDLG_H_BASE_
13 #define _WX_PRINTDLG_H_BASE_
14
15 #include "wx/defs.h"
16
17 #if wxUSE_PRINTING_ARCHITECTURE
18
19 #include "wx/event.h"
20 #include "wx/dialog.h"
21 #include "wx/intl.h"
22 #include "wx/cmndata.h"
23
24
25 // ---------------------------------------------------------------------------
26 // wxPrintDialogBase: interface for the dialog for printing
27 // ---------------------------------------------------------------------------
28
29 class WXDLLIMPEXP_CORE wxPrintDialogBase : public wxDialog
30 {
31 public:
32 wxPrintDialogBase() { }
33 wxPrintDialogBase(wxWindow *parent,
34 wxWindowID id = wxID_ANY,
35 const wxString &title = wxEmptyString,
36 const wxPoint &pos = wxDefaultPosition,
37 const wxSize &size = wxDefaultSize,
38 long style = wxDEFAULT_DIALOG_STYLE);
39
40 virtual wxPrintDialogData& GetPrintDialogData() = 0;
41 virtual wxPrintData& GetPrintData() = 0;
42 virtual wxDC *GetPrintDC() = 0;
43
44 private:
45 DECLARE_ABSTRACT_CLASS(wxPrintDialogBase)
46 wxDECLARE_NO_COPY_CLASS(wxPrintDialogBase);
47 };
48
49 // ---------------------------------------------------------------------------
50 // wxPrintDialog: the dialog for printing.
51 // ---------------------------------------------------------------------------
52
53 class WXDLLIMPEXP_CORE wxPrintDialog : public wxObject
54 {
55 public:
56 wxPrintDialog(wxWindow *parent, wxPrintDialogData* data = NULL);
57 wxPrintDialog(wxWindow *parent, wxPrintData* data);
58 virtual ~wxPrintDialog();
59
60 virtual int ShowModal();
61
62 virtual wxPrintDialogData& GetPrintDialogData();
63 virtual wxPrintData& GetPrintData();
64 virtual wxDC *GetPrintDC();
65
66 private:
67 wxPrintDialogBase *m_pimpl;
68
69 private:
70 DECLARE_DYNAMIC_CLASS(wxPrintDialog)
71 wxDECLARE_NO_COPY_CLASS(wxPrintDialog);
72 };
73
74 // ---------------------------------------------------------------------------
75 // wxPageSetupDialogBase: interface for the page setup dialog
76 // ---------------------------------------------------------------------------
77
78 class WXDLLIMPEXP_CORE wxPageSetupDialogBase: public wxDialog
79 {
80 public:
81 wxPageSetupDialogBase() { }
82 wxPageSetupDialogBase(wxWindow *parent,
83 wxWindowID id = wxID_ANY,
84 const wxString &title = wxEmptyString,
85 const wxPoint &pos = wxDefaultPosition,
86 const wxSize &size = wxDefaultSize,
87 long style = wxDEFAULT_DIALOG_STYLE);
88
89 virtual wxPageSetupDialogData& GetPageSetupDialogData() = 0;
90
91 private:
92 DECLARE_ABSTRACT_CLASS(wxPageSetupDialogBase)
93 wxDECLARE_NO_COPY_CLASS(wxPageSetupDialogBase);
94 };
95
96 // ---------------------------------------------------------------------------
97 // wxPageSetupDialog: the page setup dialog
98 // ---------------------------------------------------------------------------
99
100 class WXDLLIMPEXP_CORE wxPageSetupDialog: public wxObject
101 {
102 public:
103 wxPageSetupDialog(wxWindow *parent, wxPageSetupDialogData *data = NULL);
104 virtual ~wxPageSetupDialog();
105
106 int ShowModal();
107 wxPageSetupDialogData& GetPageSetupDialogData();
108 // old name
109 wxPageSetupDialogData& GetPageSetupData();
110
111 private:
112 wxPageSetupDialogBase *m_pimpl;
113
114 private:
115 DECLARE_DYNAMIC_CLASS(wxPageSetupDialog)
116 wxDECLARE_NO_COPY_CLASS(wxPageSetupDialog);
117 };
118
119 #endif
120
121 #endif
122 // _WX_PRINTDLG_H_BASE_