]> git.saurik.com Git - wxWidgets.git/blob - docs/latex/wx/prevwin.tex
added and documented wxDC::DrawCheckMark()
[wxWidgets.git] / docs / latex / wx / prevwin.tex
1 \section{\class{wxPreviewCanvas}}\label{wxpreviewcanvas}
2
3 A preview canvas is the default canvas used by the print preview
4 system to display the preview.
5
6 \wxheading{Derived from}
7
8 \helpref{wxScrolledWindow}{wxscrolledwindow}\\
9 \helpref{wxWindow}{wxwindow}\\
10 \helpref{wxevthandler}{wxevthandler}\\
11 \helpref{wxObject}{wxobject}
12
13 \wxheading{Include files}
14
15 <wx/print.h>
16
17 \wxheading{See also}
18
19 \helpref{wxPreviewFrame}{wxpreviewframe}, \helpref{wxPreviewControlBar}{wxpreviewcontrolbar},\rtfsp
20 \helpref{wxPrintPreview}{wxprintpreview}
21
22 \latexignore{\rtfignore{\wxheading{Members}}}
23
24 \membersection{wxPreviewCanvas::wxPreviewCanvas}
25
26 \func{}{wxPreviewCanvas}{\param{wxPrintPreview* }{preview}, \param{wxWindow* }{parent},
27 \param{const wxPoint\& }{pos = wxDefaultPosition}, \param{const wxSize\& }{size = wxDefaultSize},
28 \param{long}{ style = 0}, \param{const wxString\& }{name = ``canvas"}}
29
30 Constructor.
31
32 \membersection{wxPreviewCanvas::\destruct{wxPreviewCanvas}}
33
34 \func{}{\destruct{wxPreviewCanvas}}{\void}
35
36 Destructor.
37
38 \membersection{wxPreviewCanvas::OnPaint}\label{wxpreviewcanvasonpaint}
39
40 \func{void}{OnPaint}{\param{wxPaintEvent\& }{event}}
41
42 Calls \helpref{wxPrintPreview::PaintPage}{wxprintpreviewpaintpage} to refresh the canvas.
43
44 \section{\class{wxPreviewControlBar}}\label{wxpreviewcontrolbar}
45
46 This is the default implementation of the preview control bar, a panel
47 with buttons and a zoom control. You can derive a new class from this and
48 override some or all member functions to change the behaviour and appearance;
49 or you can leave it as it is.
50
51 \wxheading{Derived from}
52
53 \helpref{wxPanel}{wxpanel}\\
54 \helpref{wxWindow}{wxwindow}\\
55 \helpref{wxEvtHandler}{wxevthandler}\\
56 \helpref{wxObject}{wxobject}
57
58 \wxheading{Include files}
59
60 <wx/print.h>
61
62 \wxheading{See also}
63
64 \helpref{wxPreviewFrame}{wxpreviewframe}, \helpref{wxPreviewCanvas}{wxpreviewcanvas},\rtfsp
65 \helpref{wxPrintPreview}{wxprintpreview}
66
67 \latexignore{\rtfignore{\wxheading{Members}}}
68
69 \membersection{wxPreviewControlBar::wxPreviewControlbar}
70
71 \func{}{wxPreviewControlBar}{\param{wxPrintPreview* }{preview}, \param{long}{ buttons}, \param{wxWindow* }{parent},
72 \param{const wxPoint\& }{pos = wxDefaultPosition}, \param{const wxSize\& }{size = wxDefaultSize},
73 \param{long}{ style = 0}, \param{const wxString\& }{name = ``panel"}}
74
75 Constructor.
76
77 The buttons parameter may be a combination of the following, using the bitwise `or' operator.
78
79 \begin{twocollist}\itemsep=0pt
80 \twocolitem{wxPREVIEW\_PRINT}{Create a print button.}
81 \twocolitem{wxPREVIEW\_NEXT}{Create a next page button.}
82 \twocolitem{wxPREVIEW\_PREVIOUS}{Create a previous page button.}
83 \twocolitem{wxPREVIEW\_ZOOM}{Create a zoom control.}
84 \twocolitem{wxPREVIEW\_DEFAULT}{Equivalent to a combination of wxPREVIEW\_PREVIOUS, wxPREVIEW\_NEXT and
85 wxPREVIEW\_ZOOM.}
86 \end{twocollist}
87
88 \membersection{wxPreviewControlBar::\destruct{wxPreviewControlBar}}
89
90 \func{}{\destruct{wxPreviewControlBar}}{\void}
91
92 Destructor.
93
94 \membersection{wxPreviewControlBar::CreateButtons}
95
96 \func{void}{CreateButtons}{\void}
97
98 Creates buttons, according to value of the button style flags.
99
100 \membersection{wxPreviewControlBar::GetPrintPreview}
101
102 \func{wxPrintPreview *}{GetPrintPreview}{\void}
103
104 Gets the print preview object associated with the control bar.
105
106 \membersection{wxPreviewControlBar::GetZoomControl}
107
108 \func{int}{GetZoomControl}{\void}
109
110 Gets the current zoom setting in percent.
111
112 \membersection{wxPreviewControlBar::SetZoomControl}
113
114 \func{void}{SetZoomControl}{\param{int }{percent}}
115
116 Sets the zoom control.
117
118 \section{\class{wxPreviewFrame}}\label{wxpreviewframe}
119
120 This class provides the default method of managing the print preview interface.
121 Member functions may be overridden to replace functionality, or the
122 class may be used without derivation.
123
124 \wxheading{Derived from}
125
126 \helpref{wxFrame}{wxframe}\\
127 \helpref{wxWindow}{wxwindow}\\
128 \helpref{wxEvtHandler}{wxevthandler}\\
129 \helpref{wxObject}{wxobject}
130
131 \wxheading{Include files}
132
133 <wx/print.h>
134
135 \wxheading{See also}
136
137 \helpref{wxPreviewCanvas}{wxpreviewcanvas}, \helpref{wxPreviewControlBar}{wxpreviewcontrolbar},\rtfsp
138 \helpref{wxPrintPreview}{wxprintpreview}
139
140 \latexignore{\rtfignore{\wxheading{Members}}}
141
142 \membersection{wxPreviewFrame::wxPreviewFrame}
143
144 \func{}{wxPreviewFrame}{\param{wxPrintPreview* }{preview}, \param{wxFrame* }{parent}, \param{const wxString\& }{title},
145 \param{const wxPoint\& }{pos = wxDefaultPosition}, \param{const wxSize\& size }{size = wxDefaultSize},
146 \param{long}{ style = wxDEFAULT\_FRAME\_STYLE}, \param{const wxString\& }{name = ``frame"}}
147
148 Constructor. Pass a print preview object plus other normal frame arguments.
149
150 \membersection{wxPreviewFrame::\destruct{wxPreviewFrame}}
151
152 \func{}{\destruct{wxPreviewFrame}}{\void}
153
154 Destructor.
155
156 \membersection{wxPreviewFrame::CreateControlBar}
157
158 \func{void}{CreateControlBar}{\void}
159
160 Creates a wxPreviewControlBar. Override this function to allow
161 a user-defined preview control bar object to be created.
162
163 \membersection{wxPreviewFrame::CreateCanvas}
164
165 \func{void}{CreateCanvas}{\void}
166
167 Creates a wxPreviewCanvas. Override this function to allow
168 a user-defined preview canvas object to be created.
169
170 \membersection{wxPreviewFrame::Initialize}
171
172 \func{void}{Initialize}{\void}
173
174 Creates the preview canvas and control bar, and calls
175 wxWindow::MakeModal(TRUE) to disable other top-level windows
176 in the application.
177
178 This function should be called by the application prior to
179 showing the frame.
180
181 \membersection{wxPreviewFrame::OnCloseWindow}
182
183 \func{void}{OnCloseWindow}{\param{wxCloseEvent\&}{ event}}
184
185 Enables the other frames in the application, and deletes the print preview
186 object, implicitly deleting any printout objects associated with the print
187 preview object.
188