]> git.saurik.com Git - wxWidgets.git/blame - include/wx/osx/printdlg.h
Applied rowspan patch #15276 (dghart)
[wxWidgets.git] / include / wx / osx / printdlg.h
CommitLineData
49b3c4df 1/////////////////////////////////////////////////////////////////////////////
233f5738 2// Name: wx/osx/printdlg.h
49b3c4df
SC
3// Purpose: wxPrintDialog, wxPageSetupDialog classes.
4// Use generic, PostScript version if no
5// platform-specific implementation.
6// Author: Stefan Csomor
7// Modified by:
8// Created: 1998-01-01
9// RCS-ID: $Id$
10// Copyright: (c) Stefan Csomor
11// Licence: wxWindows licence
12/////////////////////////////////////////////////////////////////////////////
13
14#ifndef _WX_PRINTDLG_H_
15#define _WX_PRINTDLG_H_
16
17#include "wx/dialog.h"
18#include "wx/cmndata.h"
19#include "wx/printdlg.h"
20#include "wx/prntbase.h"
03647350 21
49b3c4df
SC
22/*
23 * wxMacPrintDialog
24 * The Mac dialog for printing
25 */
26
27class WXDLLIMPEXP_FWD_CORE wxDC;
28class WXDLLIMPEXP_CORE wxMacPrintDialog: public wxPrintDialogBase
29{
30public:
31 wxMacPrintDialog();
32 wxMacPrintDialog(wxWindow *parent, wxPrintDialogData* data = NULL);
33 wxMacPrintDialog(wxWindow *parent, wxPrintData* data );
34 virtual ~wxMacPrintDialog();
35
36 bool Create(wxWindow *parent, wxPrintDialogData* data = NULL);
37 virtual int ShowModal();
38
39 virtual wxPrintDialogData& GetPrintDialogData() { return m_printDialogData; }
40 virtual wxPrintData& GetPrintData() { return m_printDialogData.GetPrintData(); }
41 virtual wxDC *GetPrintDC();
42
43private:
44 wxPrintDialogData m_printDialogData;
45 wxDC* m_printerDC;
46 bool m_destroyDC;
47 wxWindow* m_dialogParent;
03647350 48
49b3c4df
SC
49private:
50 DECLARE_DYNAMIC_CLASS(wxPrintDialog)
51};
52
53/*
54 * wxMacPageSetupDialog
55 * The Mac page setup dialog
56 */
57
58class WXDLLIMPEXP_CORE wxMacPageSetupDialog: public wxPageSetupDialogBase
59{
60public:
7193abfb 61 wxMacPageSetupDialog(wxWindow *parent, wxPageSetupDialogData *data = NULL);
49b3c4df
SC
62 virtual ~wxMacPageSetupDialog();
63
7193abfb 64 virtual wxPageSetupDialogData& GetPageSetupDialogData();
03647350 65
7193abfb 66 bool Create(wxWindow *parent, wxPageSetupDialogData *data = NULL);
49b3c4df 67 virtual int ShowModal();
03647350 68
49b3c4df 69private:
7193abfb 70 wxPageSetupDialogData m_pageSetupData;
49b3c4df 71 wxWindow* m_dialogParent;
03647350 72
49b3c4df
SC
73private:
74 DECLARE_DYNAMIC_CLASS_NO_COPY(wxMacPageSetupDialog)
75};
76
77class WXDLLIMPEXP_FWD_CORE wxTextCtrl;
78
79/*
80* wxMacPageMarginsDialog
81* A Mac dialog for setting the page margins separately from page setup since
82* (native) wxMacPageSetupDialog doesn't let you set margins.
83*/
84
85class WXDLLIMPEXP_CORE wxMacPageMarginsDialog : public wxDialog
86{
87public:
7193abfb 88 wxMacPageMarginsDialog(wxFrame* parent, wxPageSetupDialogData* data);
49b3c4df
SC
89 bool TransferToWindow();
90 bool TransferDataFromWindow();
91
7193abfb 92 virtual wxPageSetupDialogData& GetPageSetupDialogData() { return *m_pageSetupDialogData; }
49b3c4df
SC
93
94private:
7193abfb 95 wxPageSetupDialogData* m_pageSetupDialogData;
03647350 96
49b3c4df
SC
97 wxPoint m_MinMarginTopLeft;
98 wxPoint m_MinMarginBottomRight;
99 wxTextCtrl *m_LeftMargin;
100 wxTextCtrl *m_TopMargin;
101 wxTextCtrl *m_RightMargin;
102 wxTextCtrl *m_BottomMargin;
03647350 103
49b3c4df
SC
104 void GetMinMargins();
105 bool CheckValue(wxTextCtrl* textCtrl, int *value, int minValue, const wxString& name);
03647350 106
49b3c4df
SC
107private:
108 DECLARE_DYNAMIC_CLASS_NO_COPY(wxMacPageMarginsDialog)
109};
110
111
112#endif // _WX_PRINTDLG_H_