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