]> git.saurik.com Git - wxWidgets.git/blob - docs/latex/wx/print.tex
fixed the description of wxSafeYield()
[wxWidgets.git] / docs / latex / wx / print.tex
1 \section{\class{wxPrintData}}\label{wxprintdata}
2
3 This class holds a variety of information related to print dialogs.
4
5 \wxheading{Derived from}
6
7 \helpref{wxObject}{wxobject}
8
9 \wxheading{Include files}
10
11 <wx/cmndata.h>
12
13 \wxheading{See also}
14
15 \helpref{wxPrintDialog}{wxprintdialog}, \helpref{wxPrintDialog Overview}{wxprintdialogoverview}
16
17 \latexignore{\rtfignore{\wxheading{Members}}}
18
19 \membersection{wxPrintData::wxPrintData}
20
21 \func{}{wxPrintData}{\void}
22
23 Constructor.
24
25 \membersection{wxPrintData::\destruct{wxPrintData}}
26
27 \func{}{\destruct{wxPrintData}}{\void}
28
29 Destructor.
30
31 \membersection{wxPrintData::EnableHelp}\label{wxprintdataenablehelp}
32
33 \func{void}{EnableHelp}{\param{bool }{flag}}
34
35 Enables or disables the `Help' button.
36
37 \membersection{wxPrintData::EnablePageNumbers}\label{wxprintdataenablepagenumbers}
38
39 \func{void}{EnablePageNumbers}{\param{bool }{flag}}
40
41 Enables or disables the `Page numbers' controls.
42
43 \membersection{wxPrintData::EnablePrintToFile}\label{wxprintdataenableprinttofile}
44
45 \func{void}{EnablePrintToFile}{\param{bool }{flag}}
46
47 Enables or disables the `Print to file' checkbox.
48
49 \membersection{wxPrintData::EnableSelection}\label{wxprintdataenableselection}
50
51 \func{void}{EnableSelection}{\param{bool }{flag}}
52
53 Enables or disables the `Selection' radio button.
54
55 \membersection{wxPrintData::GetAllPages}\label{wxprintdatagetallpages}
56
57 \func{bool}{GetAllPages}{\void}
58
59 Returns TRUE if the user requested that all pages be printed.
60
61 \membersection{wxPrintData::GetCollate}\label{wxprintdatagetcollate}
62
63 \func{bool}{GetCollate}{\void}
64
65 Returns TRUE if the user requested that the document(s) be collated.
66
67 \membersection{wxPrintData::GetFromPage}\label{wxprintdatagetfrompage}
68
69 \func{int}{GetFromPage}{\void}
70
71 Returns the {\it from} page number, as entered by the user.
72
73 \membersection{wxPrintData::GetMaxPage}\label{wxprintdatagetmaxpage}
74
75 \func{int}{GetMaxPage}{\void}
76
77 Returns the {\it maximum} page number.
78
79 \membersection{wxPrintData::GetMinPage}\label{wxprintdatagetminpage}
80
81 \func{int}{GetMinPage}{\void}
82
83 Returns the {\it minimum} page number.
84
85 \membersection{wxPrintData::GetNoCopies}\label{wxprintdatagetnocopies}
86
87 \func{int}{GetNoCopies}{\void}
88
89 Returns the number of copies requested by the user.
90
91 \membersection{wxPrintData::GetOrientation}\label{wxprintdatagetorientation}
92
93 \func{int}{GetOrientation}{\void}
94
95 Gets the orientation. This can be wxLANDSCAPE or wxPORTRAIT.
96
97 \membersection{wxPrintData::GetToPage}\label{wxprintdatagettopage}
98
99 \func{int}{GetToPage}{\void}
100
101 Returns the {\it to} page number, as entered by the user.
102
103 \membersection{wxPrintData::SetCollate}\label{wxprintdatasetcollate}
104
105 \func{void}{SetCollate}{\param{bool }{flag}}
106
107 Sets the 'Collate' checkbox to TRUE or FALSE.
108
109 \membersection{wxPrintData::SetFromPage}\label{wxprintdatasetfrompage}
110
111 \func{void}{SetFromPage}{\param{int }{page}}
112
113 Sets the {\it from} page number.
114
115 \membersection{wxPrintData::SetMaxPage}\label{wxprintdatasetmaxpage}
116
117 \func{void}{SetMaxPage}{\param{int }{page}}
118
119 Sets the {\it maximum} page number.
120
121 \membersection{wxPrintData::SetMinPage}\label{wxprintdatasetminpage}
122
123 \func{void}{SetMinPage}{\param{int }{page}}
124
125 Sets the {\it minimum} page number.
126
127 \membersection{wxPrintData::SetOrientation}\label{wxprintdatasetorientation}
128
129 \func{void}{SetOrientation}{\param{int }{orientation}}
130
131 Sets the orientation. This can be wxLANDSCAPE or wxPORTRAIT.
132
133 \membersection{wxPrintData::SetNoCopies}\label{wxprintdatasetnocopies}
134
135 \func{void}{SetNoCopies}{\param{int }{n}}
136
137 Sets the default number of copies to be printed out.
138
139 \membersection{wxPrintData::SetPrintToFile}\label{wxprintdatasetprinttofile}
140
141 \func{void}{SetPrintToFile}{\param{bool }{flag}}
142
143 Sets the 'Print to file' checkbox to TRUE or FALSE.
144
145 \membersection{wxPrintData::SetSetupDialog}\label{wxprintdatasetsetupdialog}
146
147 \func{void}{SetSetupDialog}{\param{bool }{flag}}
148
149 Determines whether the dialog to be shown will be the Print dialog
150 (pass FALSE) or Print Setup dialog (pass TRUE).
151
152 Note that the setup dialog is obsolete from
153 Windows 95, though retained for backward compatibility.
154
155 \membersection{wxPrintData::SetToPage}\label{wxprintdatasettopage}
156
157 \func{void}{SetToPage}{\param{int }{page}}
158
159 Sets the {\it to} page number.
160
161 \section{\class{wxPrintDialog}}\label{wxprintdialog}
162
163 This class represents the print and print setup common dialogs.
164 You may obtain a \helpref{wxPrinterDC}{wxprinterdc} device context from
165 a successfully dismissed print dialog.
166
167 \wxheading{Derived from}
168
169 \helpref{wxDialog}{wxdialog}\\
170 \helpref{wxWindow}{wxwindow}\\
171 \helpref{wxEvtHandler}{wxevthandler}\\
172 \helpref{wxObject}{wxobject}
173
174 \wxheading{Include files}
175
176 <wx/printdlg.h>
177
178 \wxheading{See also}
179
180 \helpref{wxPrintDialog Overview}{wxprintdialogoverview}
181
182 \latexignore{\rtfignore{\wxheading{Members}}}
183
184 \membersection{wxPrintDialog::wxPrintDialog}
185
186 \func{}{wxPrintDialog}{\param{wxWindow* }{parent}, \param{wxPrintData* }{data = NULL}}
187
188 Constructor. Pass a parent window, and optionally a pointer to a block of print
189 data, which will be copied to the print dialog's print data.
190
191 \wxheading{See also}
192
193 \helpref{wxPrintData}{wxprintdata}
194
195 \membersection{wxPrintDialog::\destruct{wxPrintDialog}}
196
197 \func{}{\destruct{wxPrintDialog}}{\void}
198
199 Destructor. If wxPrintDialog::GetPrintDC has {\it not} been called,
200 the device context obtained by the dialog (if any) will be deleted.
201
202 \membersection{wxPrintDialog::GetPrintData}\label{wxprintdialoggetprintdata}
203
204 \func{wxPrintData\&}{GetPrintData}{\void}
205
206 Returns the \helpref{print data}{wxprintdata} associated with the print dialog.
207
208 \membersection{wxPrintDialog::GetPrintDC}\label{wxprintdialoggetprintdc}
209
210 \func{wxDC* }{GetPrintDC}{\void}
211
212 Returns the device context created by the print dialog, if any.
213 When this function has been called, the ownership of the device context
214 is transferred to the application, so it must then be deleted
215 explicitly.
216
217 \membersection{wxPrintDialog::ShowModal}\label{wxprintdialogshowmodal}
218
219 \func{int}{ShowModal}{\void}
220
221 Shows the dialog, returning wxID\_OK if the user pressed OK, and wxID\_CANCEL
222 otherwise. After this function is called, a device context may
223 be retrievable using \helpref{wxPrintDialog::GetPrintDC}{wxprintdialoggetprintdc}.
224
225 \section{\class{wxPrinter}}\label{wxprinter}
226
227 This class represents the Windows or PostScript printer, and is the vehicle through
228 which printing may be launched by an application. Printing can also
229 be achieved through using of lower functions and classes, but
230 this and associated classes provide a more convenient and general
231 method of printing.
232
233 \wxheading{Derived from}
234
235 \helpref{wxObject}{wxobject}
236
237 \wxheading{Include files}
238
239 <wx/print.h>
240
241 \wxheading{See also}
242
243 \helpref{Printing framework overview}{printingoverview}, \helpref{wxPrinterDC}{wxprinterdc}, \helpref{wxPrintDialog}{wxprintdialog},\rtfsp
244 \helpref{wxPrintout}{wxprintout}, \helpref{wxPrintPreview}{wxprintpreview}.
245
246 \latexignore{\rtfignore{\wxheading{Members}}}
247
248 \membersection{wxPrinter::wxPrinter}
249
250 \func{}{wxPrinter}{\param{wxPrintData* }{data = NULL}}
251
252 Constructor. Pass an optional pointer to a block of print
253 data, which will be copied to the printer object's print data.
254
255 \wxheading{See also}
256
257 \helpref{wxPrintData}{wxprintdata}
258
259 \membersection{wxPrinter::\destruct{wxPrinter}}
260
261 \func{}{\destruct{wxPrinter}}{\void}
262
263 Destructor.
264
265 \membersection{wxPrinter::Abort}\label{wxprinterabort}
266
267 \func{bool}{Abort}{\void}
268
269 Returns TRUE if the user has aborted the print job.
270
271 \membersection{wxPrinter::CreateAbortWindow}\label{wxprintercreateabortwindow}
272
273 \func{void}{CreateAbortWindow}{\param{wxWindow* }{parent}, \param{wxPrintout* }{printout}}
274
275 Creates the default printing abort window, with a cancel button.
276
277 \membersection{wxPrinter::GetPrintData}\label{wxprintergetprintdata}
278
279 \func{wxPrintData\&}{GetPrintData}{\void}
280
281 Returns the \helpref{print data}{wxprintdata} associated with the printer object.
282
283 \membersection{wxPrinter::Print}\label{wxprinterprint}
284
285 \func{bool}{Print}{\param{wxWindow *}{parent}, \param{wxPrintout *}{printout}, \param{bool }{prompt=TRUE}}
286
287 Starts the printing process. Provide a parent window, a user-defined wxPrintout object which controls
288 the printing of a document, and whether the print dialog should be invoked first.
289
290 Print could return FALSE if there was a problem initializing the printer device context
291 (current printer not set, for example).
292
293 \membersection{wxPrinter::PrintDialog}\label{wxprinterprintdialog}
294
295 \func{bool}{PrintDialog}{\param{wxWindow *}{parent}}
296
297 Invokes the print dialog.
298
299 \membersection{wxPrinter::ReportError}\label{wxprinterreporterror}
300
301 \func{void}{ReportError}{\param{wxWindow *}{parent}, \param{wxPrintout *}{printout}, \param{const wxString\& }{message}}
302
303 Default error-reporting function.
304
305 \membersection{wxPrinter::Setup}\label{wxprintersetup}
306
307 \func{void}{Setup}{\param{wxWindow *}{parent}}
308
309 Invokes the print setup dialog. Note that the setup dialog is obsolete from
310 Windows 95, though retained for backward compatibility.
311
312 \section{\class{wxPrinterDC}}\label{wxprinterdc}
313
314 A printer device context is specific to Windows, and allows access to
315 any printer with a Windows driver. See \helpref{wxDC}{wxdc} for further information
316 on device contexts, and \helpref{wxDC::GetSize}{wxdcgetsize} for advice on
317 achieving the correct scaling for the page.
318
319 \wxheading{Derived from}
320
321 \helpref{wxDC}{wxdc}\\
322 \helpref{wxObject}{wxdc}
323
324 \wxheading{Include files}
325
326 <wx/dcprint.h>
327
328 \wxheading{See also}
329
330 \helpref{wxDC}{wxdc}, \helpref{Printing framework overview}{printingoverview}
331
332 \latexignore{\rtfignore{\wxheading{Members}}}
333
334 \membersection{wxPrinterDC::wxPrinterDC}
335
336 \func{}{wxPrinterDC}{\param{const wxString\& }{driver}, \param{const wxString\& }{device}, \param{const wxString\& }{output},
337 \param{const bool }{interactive = TRUE}, \param{int }{orientation = wxPORTRAIT}}
338
339 Constructor. With empty strings for the first three arguments, the default printer dialog is
340 displayed. {\it device} indicates the type of printer and {\it output}
341 is an optional file for printing to. The {\it driver} parameter is
342 currently unused. Use the {\it Ok} member to test whether the
343 constructor was successful in creating a useable device context.
344
345 \section{\class{wxPrintout}}\label{wxprintout}
346
347 This class encapsulates the functionality of printing out an
348 application document. A new class must be derived and members
349 overridden to respond to calls such as OnPrintPage and HasPage.
350 Instances of this class are passed to wxPrinter::Print or a
351 wxPrintPreview object to initiate printing or previewing.
352
353 \wxheading{Derived from}
354
355 \helpref{wxObject}{wxobject}
356
357 \wxheading{Include files}
358
359 <wx/print.h>
360
361 \wxheading{See also}
362
363 \helpref{Printing framework overview}{printingoverview}, \helpref{wxPrinterDC}{wxprinterdc}, \helpref{wxPrintDialog}{wxprintdialog},\rtfsp
364 \helpref{wxPrinter}{wxprinter}, \helpref{wxPrintPreview}{wxprintpreview}
365
366 \latexignore{\rtfignore{\wxheading{Members}}}
367
368 \membersection{wxPrintout::wxPrintout}
369
370 \func{}{wxPrintout}{\param{const wxString\& }{title = "Printout"}}
371
372 Constructor. Pass an optional title argument (currently unused).
373
374 \membersection{wxPrintout::\destruct{wxPrintout}}
375
376 \func{}{\destruct{wxPrintout}}{\void}
377
378 Destructor.
379
380 \membersection{wxPrintout::GetDC}\label{wxprintoutgetdc}
381
382 \func{wxDC *}{GetDC}{\void}
383
384 Returns the device context associated with the printout (given to the printout at start of
385 printing or previewing). This will be a wxPrinterDC if printing under Windows,
386 a wxPostScriptDC if printing on other platforms, and a wxMemoryDC if previewing.
387
388 \membersection{wxPrintout::GetPageInfo}\label{wxprintoutgetpageinfo}
389
390 \func{void}{GetPageInfo}{\param{int *}{minPage}, \param{int *}{maxPage}, \param{int *}{pageFrom}, \param{int *}{pageTo}}
391
392 Called by the framework to obtain information from the application about minimum and maximum page values that
393 the user can select, and the required page range to be printed. By default this
394 returns 1, 32000 for the page minimum and maximum values, and 1, 1 for the required page range.
395
396 If {\it minPage} is zero, the page number controls in the print dialog will be disabled.
397
398 \membersection{wxPrintout::GetPageSizeMM}\label{wxprintoutgetpagesizemm}
399
400 \func{void}{GetPageSizeMM}{\param{int *}{w}, \param{int *}{h}}
401
402 Returns the size of the printer page in millimetres.
403
404 \membersection{wxPrintout::GetPageSizePixels}\label{wxprintoutgetpagesizepixels}
405
406 \func{void}{GetPageSizePixels}{\param{int *}{w}, \param{int *}{h}}
407
408 Returns the size of the printer page in pixels. These may not be the
409 same as the values returned from \helpref{wxDC::GetSize}{wxdcgetsize} if
410 the printout is being used for previewing, since in this case, a
411 memory device context is used, using a bitmap size reflecting the current
412 preview zoom. The application must take this discrepancy into account if
413 previewing is to be supported.
414
415 \membersection{wxPrintout::GetPPIPrinter}\label{wxprintoutgetppiprinter}
416
417 \func{void}{GetPPIPrinter}{\param{int *}{w}, \param{int *}{h}}
418
419 Returns the number of pixels per logical inch of the printer device context.
420 Dividing the printer PPI by the screen PPI can give a suitable scaling
421 factor for drawing text onto the printer. Remember to multiply
422 this by a scaling factor to take the preview DC size into account.
423
424 \membersection{wxPrintout::GetPPIScreen}\label{wxprintoutgetppiscreen}
425
426 \func{void}{GetPPIScreen}{\param{int *}{w}, \param{int *}{h}}
427
428 Returns the number of pixels per logical inch of the screen device context.
429 Dividing the printer PPI by the screen PPI can give a suitable scaling
430 factor for drawing text onto the printer. Remember to multiply
431 this by a scaling factor to take the preview DC size into account.
432
433 \membersection{wxPrintout::HasPage}\label{wxprintouthaspage}
434
435 \func{bool}{HasPage}{\param{int}{ pageNum}}
436
437 Should be overriden to return TRUE if the document has this page, or FALSE
438 if not. Returning FALSE signifies the end of the document. By default,
439 HasPage behaves as if the document has only one page.
440
441 \membersection{wxPrintout::IsPreview}\label{wxprintoutispreview}
442
443 \func{bool}{IsPreview}{\void}
444
445 Returns TRUE if the printout is currently being used for previewing.
446
447 \membersection{wxPrintout::OnBeginDocument}\label{wxprintoutonbegindocument}
448
449 \func{bool}{OnBeginDocument}{\param{int}{ startPage}, \param{int}{ endPage}}
450
451 Called by the framework at the start of document printing. Return FALSE from
452 this function cancels the print job. OnBeginDocument is called once for every
453 copy printed.
454
455 The base wxPrintout::OnBeginDocument {\it must} be called (and the return value
456 checked) from within the overriden function, since it calls wxDC::StartDoc.
457
458 \membersection{wxPrintout::OnEndDocument}\label{wxprintoutonenddocument}
459
460 \func{void}{OnEndDocument}{\void}
461
462 Called by the framework at the end of document printing. OnEndDocument
463 is called once for every copy printed.
464
465 The base wxPrintout::OnEndDocument {\it must} be called
466 from within the overriden function, since it calls wxDC::EndDoc.
467
468 \membersection{wxPrintout::OnBeginPrinting}\label{wxprintoutonbeginprinting}
469
470 \func{void}{OnBeginPrinting}{\void}
471
472 Called by the framework at the start of printing. OnBeginPrinting is called once for every
473 print job (regardless of how many copies are being printed).
474
475 \membersection{wxPrintout::OnEndPrinting}\label{wxprintoutonendprinting}
476
477 \func{void}{OnEndPrinting}{\void}
478
479 Called by the framework at the end of printing. OnEndPrinting
480 is called once for every print job (regardless of how many copies are being printed).
481
482 \membersection{wxPrintout::OnPreparePrinting}\label{wxprintoutonprepareprinting}
483
484 \func{void}{OnPreparePrinting}{\void}
485
486 Called once by the framework before any other demands are made of the
487 wxPrintout object. This gives the object an opportunity to calculate the
488 number of pages in the document, for example.
489
490 \membersection{wxPrintout::OnPrintPage}\label{wxprintoutonprintpage}
491
492 \func{bool}{OnPrintPage}{\param{int}{ pageNum}}
493
494 Called by the framework when a page should be printed. Returning FALSE cancels
495 the print job. The application can use wxPrintout::GetDC to obtain a device
496 context to draw on.
497
498 \section{\class{wxPrintPreview}}\label{wxprintpreview}
499
500 \overview{Printing framework overview}{printingoverview}
501
502 Objects of this class manage the print preview process. The object is passed
503 a wxPrintout object, and the wxPrintPreview object itself is passed to
504 a wxPreviewFrame object. Previewing is started by initializing and showing
505 the preview frame. Unlike wxPrinter::Print, flow of control returns to the application
506 immediately after the frame is shown.
507
508 \wxheading{Derived from}
509
510 \helpref{wxObject}{wxobject}
511
512 \wxheading{Include files}
513
514 <wx/print.h>
515
516 \wxheading{See also}
517
518 \overview{Printing framework overview}{printingoverview}, \helpref{wxPrinterDC}{wxprinterdc}, \helpref{wxPrintDialog}{wxprintdialog},\rtfsp
519 \helpref{wxPrintout}{wxprintout}, \helpref{wxPrinter}{wxprinter},\rtfsp
520 \helpref{wxPreviewCanvas}{wxpreviewcanvas}, \helpref{wxPreviewControlBar}{wxpreviewcontrolbar},\rtfsp
521 \helpref{wxPreviewFrame}{wxpreviewframe}.
522
523 \latexignore{\rtfignore{\wxheading{Members}}}
524
525 \membersection{wxPrintPreview::wxPrintPreview}
526
527 \func{}{wxPrintPreview}{\param{wxPrintout* }{printout}, \param{wxPrintout* }{printoutForPrinting},
528 \param{wxPrintData* }{data=NULL}}
529
530 Constructor. Pass a printout object, an optional printout object to be
531 used for actual printing, and the address of an optional
532 block of printer data, which will be copied to the print preview object's
533 print data.
534
535 If {\it printoutForPrinting} is non-NULL, a {\bf Print...} button will be placed on the
536 preview frame so that the user can print directly from the preview interface.
537
538 Do not explicitly delete the printout objects once this destructor has been
539 called, since they will be deleted in the wxPrintPreview constructor.
540 The same does not apply to the {\it data} argument.
541
542 Test the Ok member to check whether the wxPrintPreview object was created correctly.
543 Ok could return FALSE if there was a problem initializing the printer device context
544 (current printer not set, for example).
545
546 \membersection{wxPrintPreview::\destruct{wxPrintPreview}}
547
548 \func{}{\destruct{wxPrinter}}{\void}
549
550 Destructor. Deletes both print preview objects, so do not destroy these objects
551 in your application.
552
553 \membersection{wxPrintPreview::DrawBlankPage}\label{wxprintpreviewdrawblankpage}
554
555 \func{bool}{DrawBlankPage}{\param{wxWindow* }{window}}
556
557 Draws a representation of the blank page into the preview window. Used
558 internally.
559
560 \membersection{wxPrintPreview::GetCanvas}\label{wxprintpreviewgetcanvas}
561
562 \func{wxWindow* }{GetCanvas}{\void}
563
564 Gets the preview window used for displaying the print preview image.
565
566 \membersection{wxPrintPreview::GetCurrentPage}\label{wxprintpreviewgetcurrentpage}
567
568 \func{int}{GetCurrentPage}{\void}
569
570 Gets the page currently being previewed.
571
572 \membersection{wxPrintPreview::GetFrame}\label{wxprintpreviewgetframe}
573
574 \func{wxFrame *}{GetFrame}{\void}
575
576 Gets the frame used for displaying the print preview canvas
577 and control bar.
578
579 \membersection{wxPrintPreview::GetMaxPage}\label{wxprintpreviewgetmaxpage}
580
581 \func{int}{GetMaxPage}{\void}
582
583 Returns the maximum page number.
584
585 \membersection{wxPrintPreview::GetMinPage}\label{wxprintpreviewgetminpage}
586
587 \func{int}{GetMinPage}{\void}
588
589 Returns the minimum page number.
590
591 \membersection{wxPrintPreview::GetPrintData}\label{wxprintpreviewgetprintdata}
592
593 \func{wxPrintData\&}{GetPrintData}{\void}
594
595 Returns a reference to the internal print data.
596
597 \membersection{wxPrintPreview::GetPrintout}\label{wxprintpreviewgetprintout}
598
599 \func{wxPrintout *}{GetPrintout}{\void}
600
601 Gets the preview printout object associated with the wxPrintPreview object.
602
603 \membersection{wxPrintPreview::GetPrintoutForPrinting}\label{wxprintpreviewgetprintoutforprinting}
604
605 \func{wxPrintout *}{GetPrintoutForPrinting}{\void}
606
607 Gets the printout object to be used for printing from within the preview interface,
608 or NULL if none exists.
609
610 \membersection{wxPrintPreview::Ok}\label{wxprintpreviewok}
611
612 \func{bool}{Ok}{\void}
613
614 Returns TRUE if the wxPrintPreview is valid, FALSE otherwise. It could return FALSE if there was a
615 problem initializing the printer device context (current printer not set, for example).
616
617 \membersection{wxPrintPreview::PaintPage}\label{wxprintpreviewpaintpage}
618
619 \func{bool}{PaintPage}{\param{wxWindow* }{window}}
620
621 This refreshes the preview window with the preview image.
622 It must be called from the preview window's OnPaint member.
623
624 The implementation simply blits the preview bitmap onto
625 the canvas, creating a new preview bitmap if none exists.
626
627 \membersection{wxPrintPreview::Print}\label{wxprintpreviewprint}
628
629 \func{bool}{Print}{\param{bool }{prompt}}
630
631 Invokes the print process using the second wxPrintout object
632 supplied in the wxPrintPreview constructor.
633 Will normally be called by the {\bf Print...} panel item on the
634 preview frame's control bar.
635
636 \membersection{wxPrintPreview::RenderPage}\label{wxprintpreviewrenderpage}
637
638 \func{bool}{RenderPage}{\param{int }{pageNum}}
639
640 Renders a page into a wxMemoryDC. Used internally by wxPrintPreview.
641
642 \membersection{wxPrintPreview::SetCanvas}\label{wxprintpreviewsetcanvas}
643
644 \func{void}{SetCanvas}{\param{wxWindow* }{window}}
645
646 Sets the window to be used for displaying the print preview image.
647
648 \membersection{wxPrintPreview::SetCurrentPage}\label{wxprintpreviewsetcurrentpage}
649
650 \func{void}{SetCurrentPage}{\param{int}{ pageNum}}
651
652 Sets the current page to be previewed.
653
654 \membersection{wxPrintPreview::SetFrame}\label{wxprintpreviewsetframe}
655
656 \func{void}{SetFrame}{\param{wxFrame *}{frame}}
657
658 Sets the frame to be used for displaying the print preview canvas
659 and control bar.
660
661 \membersection{wxPrintPreview::SetPrintout}\label{wxprintpreviewsetprintout}
662
663 \func{void}{SetPrintout}{\param{wxPrintout *}{printout}}
664
665 Associates a printout object with the wxPrintPreview object.
666
667 \membersection{wxPrintPreview::SetZoom}\label{wxprintpreviewsetzoom}
668
669 \func{void}{SetZoom}{\param{int}{ percent}}
670
671 Sets the percentage preview zoom, and refreshes the preview canvas
672 accordingly.
673
674