]> git.saurik.com Git - wxWidgets.git/blame - interface/wx/printdlg.h
support for iPhone callbacks
[wxWidgets.git] / interface / wx / printdlg.h
CommitLineData
23324ae1
FM
1/////////////////////////////////////////////////////////////////////////////
2// Name: printdlg.h
e54c96f1 3// Purpose: interface of wxPrintDialog
23324ae1
FM
4// Author: wxWidgets team
5// RCS-ID: $Id$
526954c5 6// Licence: wxWindows licence
23324ae1
FM
7/////////////////////////////////////////////////////////////////////////////
8
9/**
10 @class wxPrintDialog
7c913512 11
23324ae1 12 This class represents the print and print setup common dialogs.
b1b95a65
FM
13 You may obtain a wxPrinterDC device context from a successfully dismissed
14 print dialog.
7c913512 15
23324ae1
FM
16 @library{wxcore}
17 @category{printing}
7c913512 18
b1b95a65 19 @see @ref overview_printing, @ref overview_cmndlg_print
23324ae1 20*/
ac03e017 21class wxPrintDialog : public wxObject
23324ae1
FM
22{
23public:
24 /**
b1b95a65
FM
25 Constructor.
26
27 Pass a parent window, and optionally a pointer to a block of print
23324ae1 28 data, which will be copied to the print dialog's print data.
3c4f71cc 29
4cc4bfaf 30 @see wxPrintDialogData
23324ae1 31 */
4cc4bfaf 32 wxPrintDialog(wxWindow* parent, wxPrintDialogData* data = NULL);
ac03e017 33 wxPrintDialog(wxWindow *parent, wxPrintData* data);
23324ae1
FM
34
35 /**
b1b95a65
FM
36 Destructor.
37
38 If GetPrintDC() has not been called, the device context obtained by
39 the dialog (if any) will be deleted.
23324ae1 40 */
adaaa686 41 virtual ~wxPrintDialog();
23324ae1
FM
42
43 /**
44 Returns the device context created by the print dialog, if any.
b1b95a65 45
23324ae1
FM
46 When this function has been called, the ownership of the device context
47 is transferred to the application, so it must then be deleted
48 explicitly.
49 */
adaaa686 50 virtual wxDC* GetPrintDC();
23324ae1
FM
51
52 /**
b1b95a65
FM
53 Returns the @ref overview_printing_printdata "print dialog data" associated
54 with the print dialog.
23324ae1 55 */
43c48e1e 56 virtual wxPrintDialogData& GetPrintDialogData();
23324ae1 57
ac03e017
RD
58 /**
59 Returns the @ref overview_printing_printdata "print data" associated
60 with the print dialog.
61 */
62 virtual wxPrintData& GetPrintData();
63
23324ae1 64 /**
b1b95a65
FM
65 Shows the dialog, returning @c wxID_OK if the user pressed OK, and @c
66 wxID_CANCEL otherwise.
67
68 After this function is called, a device context may be retrievable using
69 GetPrintDC().
23324ae1 70 */
adaaa686 71 virtual int ShowModal();
23324ae1
FM
72};
73
74
e54c96f1 75
23324ae1
FM
76/**
77 @class wxPageSetupDialog
7c913512 78
947c91da 79 This class represents the page setup common dialog.
7c913512 80
947c91da
VZ
81 The page setup dialog contains controls for paper size (letter, A4, A5 etc.),
82 orientation (landscape or portrait), and, only under Windows currently,
83 controls for setting left, top, right and bottom margin sizes in millimetres.
7c913512 84
947c91da
VZ
85 The exact appearance of this dialog varies among the platforms as a native
86 dialog is used when available (currently the case for all major platforms).
7c913512 87
b1b95a65
FM
88 When the dialog has been closed, you need to query the wxPageSetupDialogData
89 object associated with the dialog.
7c913512 90
23324ae1
FM
91 Note that the OK and Cancel buttons do not destroy the dialog; this must be done
92 by the application.
7c913512 93
23324ae1
FM
94 @library{wxcore}
95 @category{printing}
7c913512 96
bb69632a 97 @see @ref overview_printing, wxPrintDialog, wxPageSetupDialogData
23324ae1 98*/
ac03e017 99class wxPageSetupDialog : public wxObject
23324ae1
FM
100{
101public:
102 /**
b1b95a65
FM
103 Constructor.
104
105 Pass a parent window, and optionally a pointer to a block of page
106 setup data, which will be copied to the print dialog's internal data.
23324ae1 107 */
b1b95a65 108 wxPageSetupDialog(wxWindow* parent, wxPageSetupDialogData* data = NULL);
23324ae1
FM
109
110 /**
111 Destructor.
112 */
adaaa686 113 virtual ~wxPageSetupDialog();
23324ae1
FM
114
115 /**
b1b95a65 116 Returns the wxPageSetupDialogData object associated with the dialog.
23324ae1 117 */
b1b95a65 118 wxPageSetupDialogData& GetPageSetupData();
23324ae1
FM
119
120 /**
b1b95a65
FM
121 Shows the dialog, returning @c wxID_OK if the user pressed OK, and
122 @c wxID_CANCEL otherwise.
23324ae1 123 */
4ccf0566 124 int ShowModal();
23324ae1 125};
e54c96f1 126