]>
Commit | Line | Data |
---|---|---|
23324ae1 FM |
1 | ///////////////////////////////////////////////////////////////////////////// |
2 | // Name: cmndata.h | |
e54c96f1 | 3 | // Purpose: interface of wxFontData |
23324ae1 FM |
4 | // Author: wxWidgets team |
5 | // RCS-ID: $Id$ | |
6 | // Licence: wxWindows license | |
7 | ///////////////////////////////////////////////////////////////////////////// | |
8 | ||
9 | /** | |
10 | @class wxFontData | |
11 | @wxheader{cmndata.h} | |
7c913512 | 12 | |
23324ae1 | 13 | @ref overview_wxfontdialogoverview "wxFontDialog overview" |
7c913512 | 14 | |
23324ae1 | 15 | This class holds a variety of information related to font dialogs. |
7c913512 | 16 | |
23324ae1 FM |
17 | @library{wxcore} |
18 | @category{FIXME} | |
7c913512 | 19 | |
e54c96f1 | 20 | @see Overview(), wxFont, wxFontDialog |
23324ae1 FM |
21 | */ |
22 | class wxFontData : public wxObject | |
23 | { | |
24 | public: | |
25 | /** | |
26 | Constructor. Initializes @e fontColour to black, @e showHelp to black, | |
27 | @e allowSymbols to @true, @e enableEffects to @true, | |
28 | @e minSize to 0 and @e maxSize to 0. | |
29 | */ | |
30 | wxFontData(); | |
31 | ||
32 | /** | |
33 | Enables or disables 'effects' under MS Windows or generic only. This refers to | |
34 | the | |
35 | controls for manipulating colour, strikeout and underline properties. | |
23324ae1 FM |
36 | The default value is @true. |
37 | */ | |
38 | void EnableEffects(bool enable); | |
39 | ||
40 | /** | |
41 | Under MS Windows, returns a flag determining whether symbol fonts can be | |
42 | selected. Has no | |
43 | effect on other platforms. | |
23324ae1 FM |
44 | The default value is @true. |
45 | */ | |
46 | bool GetAllowSymbols(); | |
47 | ||
48 | /** | |
49 | Gets the font chosen by the user if the user pressed OK | |
50 | (wxFontDialog::ShowModal returned wxID_OK). | |
51 | */ | |
52 | wxFont GetChosenFont(); | |
53 | ||
54 | /** | |
55 | Gets the colour associated with the font dialog. | |
23324ae1 FM |
56 | The default value is black. |
57 | */ | |
58 | wxColour GetColour(); | |
59 | ||
60 | /** | |
61 | Determines whether 'effects' are enabled under Windows. This refers to the | |
62 | controls for manipulating colour, strikeout and underline properties. | |
23324ae1 FM |
63 | The default value is @true. |
64 | */ | |
65 | bool GetEnableEffects(); | |
66 | ||
67 | /** | |
68 | Gets the font that will be initially used by the font dialog. This should have | |
69 | previously been set by the application. | |
70 | */ | |
71 | wxFont GetInitialFont(); | |
72 | ||
73 | /** | |
74 | Returns @true if the Help button will be shown (Windows only). | |
23324ae1 FM |
75 | The default value is @false. |
76 | */ | |
77 | bool GetShowHelp(); | |
78 | ||
79 | /** | |
80 | Under MS Windows, determines whether symbol fonts can be selected. Has no | |
81 | effect on other platforms. | |
23324ae1 FM |
82 | The default value is @true. |
83 | */ | |
84 | void SetAllowSymbols(bool allowSymbols); | |
85 | ||
86 | /** | |
87 | Sets the font that will be returned to the user (for internal use only). | |
88 | */ | |
89 | void SetChosenFont(const wxFont& font); | |
90 | ||
91 | /** | |
92 | Sets the colour that will be used for the font foreground colour. | |
23324ae1 FM |
93 | The default colour is black. |
94 | */ | |
95 | void SetColour(const wxColour& colour); | |
96 | ||
97 | /** | |
98 | Sets the font that will be initially used by the font dialog. | |
99 | */ | |
100 | void SetInitialFont(const wxFont& font); | |
101 | ||
102 | /** | |
103 | Sets the valid range for the font point size (Windows only). | |
23324ae1 FM |
104 | The default is 0, 0 (unrestricted range). |
105 | */ | |
106 | void SetRange(int min, int max); | |
107 | ||
108 | /** | |
109 | Determines whether the Help button will be displayed in the font dialog | |
110 | (Windows only). | |
23324ae1 FM |
111 | The default value is @false. |
112 | */ | |
113 | void SetShowHelp(bool showHelp); | |
114 | ||
115 | /** | |
116 | Assignment operator for the font data. | |
117 | */ | |
118 | void operator =(const wxFontData& data); | |
119 | }; | |
120 | ||
121 | ||
e54c96f1 | 122 | |
23324ae1 FM |
123 | /** |
124 | @class wxPageSetupDialogData | |
125 | @wxheader{cmndata.h} | |
7c913512 | 126 | |
23324ae1 | 127 | This class holds a variety of information related to wxPageSetupDialog. |
7c913512 | 128 | |
23324ae1 FM |
129 | It contains a wxPrintData member which is used to hold basic printer |
130 | configuration data (as opposed to the | |
131 | user-interface configuration settings stored by wxPageSetupDialogData). | |
7c913512 | 132 | |
23324ae1 FM |
133 | @library{wxcore} |
134 | @category{printing} | |
7c913512 | 135 | |
e54c96f1 FM |
136 | @see @ref overview_printingoverview "Printing framework overview", |
137 | wxPageSetupDialog | |
23324ae1 FM |
138 | */ |
139 | class wxPageSetupDialogData : public wxObject | |
140 | { | |
141 | public: | |
142 | //@{ | |
143 | /** | |
144 | Construct an object from a print data object. | |
145 | */ | |
146 | wxPageSetupDialogData(); | |
7c913512 FM |
147 | wxPageSetupDialogData(wxPageSetupDialogData& data); |
148 | wxPageSetupDialogData(wxPrintData& printData); | |
23324ae1 FM |
149 | //@} |
150 | ||
151 | /** | |
152 | Destructor. | |
153 | */ | |
154 | ~wxPageSetupDialogData(); | |
155 | ||
156 | /** | |
157 | Enables or disables the 'Help' button (Windows only). | |
158 | */ | |
159 | void EnableHelp(bool flag); | |
160 | ||
161 | /** | |
162 | Enables or disables the margin controls (Windows only). | |
163 | */ | |
164 | void EnableMargins(bool flag); | |
165 | ||
166 | /** | |
167 | Enables or disables the orientation control (Windows only). | |
168 | */ | |
169 | void EnableOrientation(bool flag); | |
170 | ||
171 | /** | |
172 | Enables or disables the paper size control (Windows only). | |
173 | */ | |
174 | void EnablePaper(bool flag); | |
175 | ||
176 | /** | |
177 | Enables or disables the @b Printer button, which invokes a printer setup dialog. | |
178 | */ | |
179 | void EnablePrinter(bool flag); | |
180 | ||
181 | /** | |
182 | Returns @true if the dialog will simply return default printer information (such | |
183 | as orientation) | |
184 | instead of showing a dialog. Windows only. | |
185 | */ | |
328f5751 | 186 | bool GetDefaultInfo() const; |
23324ae1 FM |
187 | |
188 | /** | |
189 | Returns @true if the page setup dialog will take its minimum margin values from | |
190 | the currently | |
191 | selected printer properties. Windows only. | |
192 | */ | |
328f5751 | 193 | bool GetDefaultMinMargins() const; |
23324ae1 FM |
194 | |
195 | /** | |
196 | Returns @true if the printer setup button is enabled. | |
197 | */ | |
328f5751 | 198 | bool GetEnableHelp() const; |
23324ae1 FM |
199 | |
200 | /** | |
201 | Returns @true if the margin controls are enabled (Windows only). | |
202 | */ | |
328f5751 | 203 | bool GetEnableMargins() const; |
23324ae1 FM |
204 | |
205 | /** | |
206 | Returns @true if the orientation control is enabled (Windows only). | |
207 | */ | |
328f5751 | 208 | bool GetEnableOrientation() const; |
23324ae1 FM |
209 | |
210 | /** | |
211 | Returns @true if the paper size control is enabled (Windows only). | |
212 | */ | |
328f5751 | 213 | bool GetEnablePaper() const; |
23324ae1 FM |
214 | |
215 | /** | |
216 | Returns @true if the printer setup button is enabled. | |
217 | */ | |
328f5751 | 218 | bool GetEnablePrinter() const; |
23324ae1 FM |
219 | |
220 | /** | |
221 | Returns the right (x) and bottom (y) margins in millimetres. | |
222 | */ | |
328f5751 | 223 | wxPoint GetMarginBottomRight() const; |
23324ae1 FM |
224 | |
225 | /** | |
226 | Returns the left (x) and top (y) margins in millimetres. | |
227 | */ | |
328f5751 | 228 | wxPoint GetMarginTopLeft() const; |
23324ae1 FM |
229 | |
230 | /** | |
231 | Returns the right (x) and bottom (y) minimum margins the user can enter | |
232 | (Windows only). Units | |
233 | are in millimetres | |
234 | */ | |
328f5751 | 235 | wxPoint GetMinMarginBottomRight() const; |
23324ae1 FM |
236 | |
237 | /** | |
238 | Returns the left (x) and top (y) minimum margins the user can enter (Windows | |
239 | only). Units | |
240 | are in millimetres | |
241 | */ | |
328f5751 | 242 | wxPoint GetMinMarginTopLeft() const; |
23324ae1 FM |
243 | |
244 | /** | |
245 | Returns the paper id (stored in the internal wxPrintData object). | |
23324ae1 FM |
246 | For further information, see wxPrintData::SetPaperId. |
247 | */ | |
328f5751 | 248 | wxPaperSize GetPaperId() const; |
23324ae1 FM |
249 | |
250 | /** | |
251 | Returns the paper size in millimetres. | |
252 | */ | |
328f5751 | 253 | wxSize GetPaperSize() const; |
23324ae1 FM |
254 | |
255 | /** | |
256 | Returns a reference to the @ref overview_wxprintdata "print data" associated | |
257 | with this object. | |
258 | */ | |
259 | wxPrintData GetPrintData(); | |
260 | ||
261 | /** | |
262 | Returns @true if the print data associated with the dialog data is valid. | |
263 | This can return @false on Windows if the current printer is not set, for example. | |
264 | On all other platforms, it returns @true. | |
265 | */ | |
328f5751 | 266 | bool IsOk() const; |
23324ae1 FM |
267 | |
268 | /** | |
269 | Pass @true if the dialog will simply return default printer information (such as | |
270 | orientation) | |
271 | instead of showing a dialog. Windows only. | |
272 | */ | |
273 | void SetDefaultInfo(bool flag); | |
274 | ||
275 | /** | |
276 | Pass @true if the page setup dialog will take its minimum margin values from the | |
277 | currently | |
278 | selected printer properties. Windows only. Units are in millimetres | |
279 | */ | |
280 | void SetDefaultMinMargins(bool flag); | |
281 | ||
282 | /** | |
283 | Sets the right (x) and bottom (y) margins in millimetres. | |
284 | */ | |
285 | void SetMarginBottomRight(const wxPoint& pt); | |
286 | ||
287 | /** | |
288 | Sets the left (x) and top (y) margins in millimetres. | |
289 | */ | |
290 | void SetMarginTopLeft(const wxPoint& pt); | |
291 | ||
292 | /** | |
293 | Sets the right (x) and bottom (y) minimum margins the user can enter (Windows | |
294 | only). Units are | |
295 | in millimetres. | |
296 | */ | |
297 | void SetMinMarginBottomRight(const wxPoint& pt); | |
298 | ||
299 | /** | |
300 | Sets the left (x) and top (y) minimum margins the user can enter (Windows | |
301 | only). Units are | |
302 | in millimetres. | |
303 | */ | |
304 | void SetMinMarginTopLeft(const wxPoint& pt); | |
305 | ||
306 | /** | |
307 | Sets the paper size id. For further information, see wxPrintData::SetPaperId. | |
23324ae1 FM |
308 | Calling this function overrides the explicit paper dimensions passed in |
309 | SetPaperSize(). | |
310 | */ | |
311 | void SetPaperId(wxPaperSize& id); | |
312 | ||
313 | /** | |
314 | Sets the paper size in millimetres. If a corresponding paper id is found, it | |
315 | will be set in the | |
316 | internal wxPrintData object, otherwise the paper size overrides the paper id. | |
317 | */ | |
318 | void SetPaperSize(const wxSize& size); | |
319 | ||
320 | /** | |
321 | Sets the @ref overview_wxprintdata "print data" associated with this object. | |
322 | */ | |
323 | void SetPrintData(const wxPrintData& printData); | |
324 | ||
325 | //@{ | |
326 | /** | |
327 | Assigns page setup data to this object. | |
328 | */ | |
329 | void operator =(const wxPrintData& data); | |
7c913512 | 330 | void operator =(const wxPageSetupDialogData& data); |
23324ae1 FM |
331 | //@} |
332 | }; | |
333 | ||
334 | ||
e54c96f1 | 335 | |
23324ae1 FM |
336 | /** |
337 | @class wxColourData | |
338 | @wxheader{cmndata.h} | |
7c913512 | 339 | |
23324ae1 | 340 | This class holds a variety of information related to colour dialogs. |
7c913512 | 341 | |
23324ae1 FM |
342 | @library{wxcore} |
343 | @category{FIXME} | |
7c913512 | 344 | |
e54c96f1 FM |
345 | @see wxColour, wxColourDialog, @ref overview_wxcolourdialogoverview |
346 | "wxColourDialog overview" | |
23324ae1 FM |
347 | */ |
348 | class wxColourData : public wxObject | |
349 | { | |
350 | public: | |
351 | /** | |
352 | Constructor. Initializes the custom colours to @c wxNullColour, | |
353 | the @e data colour setting | |
354 | to black, and the @e choose full setting to @true. | |
355 | */ | |
356 | wxColourData(); | |
357 | ||
358 | /** | |
359 | Destructor. | |
360 | */ | |
361 | ~wxColourData(); | |
362 | ||
363 | /** | |
364 | Under Windows, determines whether the Windows colour dialog will display the | |
365 | full dialog | |
366 | with custom colour selection controls. Under PalmOS, determines whether colour | |
367 | dialog | |
368 | will display full rgb colour picker or only available palette indexer. | |
369 | Has no meaning under other platforms. | |
23324ae1 FM |
370 | The default value is @true. |
371 | */ | |
328f5751 | 372 | bool GetChooseFull() const; |
23324ae1 FM |
373 | |
374 | /** | |
375 | Gets the current colour associated with the colour dialog. | |
23324ae1 FM |
376 | The default colour is black. |
377 | */ | |
328f5751 | 378 | wxColour GetColour() const; |
23324ae1 FM |
379 | |
380 | /** | |
4cc4bfaf | 381 | Gets the @e ith custom colour associated with the colour dialog. @a i should |
23324ae1 | 382 | be an integer between 0 and 15. |
23324ae1 FM |
383 | The default custom colours are invalid colours. |
384 | */ | |
328f5751 | 385 | wxColour GetCustomColour(int i) const; |
23324ae1 FM |
386 | |
387 | /** | |
388 | Under Windows, tells the Windows colour dialog to display the full dialog | |
389 | with custom colour selection controls. Under other platforms, has no effect. | |
23324ae1 FM |
390 | The default value is @true. |
391 | */ | |
392 | void SetChooseFull(const bool flag); | |
393 | ||
394 | /** | |
395 | Sets the default colour for the colour dialog. | |
23324ae1 FM |
396 | The default colour is black. |
397 | */ | |
398 | void SetColour(const wxColour& colour); | |
399 | ||
400 | /** | |
4cc4bfaf | 401 | Sets the @e ith custom colour for the colour dialog. @a i should |
23324ae1 | 402 | be an integer between 0 and 15. |
23324ae1 FM |
403 | The default custom colours are invalid colours. |
404 | */ | |
405 | void SetCustomColour(int i, const wxColour& colour); | |
406 | ||
407 | /** | |
408 | Assignment operator for the colour data. | |
409 | */ | |
410 | void operator =(const wxColourData& data); | |
411 | }; | |
412 | ||
413 | ||
e54c96f1 | 414 | |
23324ae1 FM |
415 | /** |
416 | @class wxPrintData | |
417 | @wxheader{cmndata.h} | |
7c913512 | 418 | |
23324ae1 FM |
419 | This class holds a variety of information related to printers and |
420 | printer device contexts. This class is used to create a wxPrinterDC | |
421 | and a wxPostScriptDC. It is also used as a data member of wxPrintDialogData | |
422 | and wxPageSetupDialogData, as part of the mechanism for transferring data | |
423 | between the print dialogs and the application. | |
7c913512 | 424 | |
23324ae1 FM |
425 | @library{wxcore} |
426 | @category{printing} | |
7c913512 | 427 | |
e54c96f1 FM |
428 | @see @ref overview_printingoverview "Printing framework overview", |
429 | wxPrintDialog, wxPageSetupDialog, wxPrintDialogData, wxPageSetupDialogData, @ref overview_wxprintdialogoverview "wxPrintDialog Overview", wxPrinterDC, wxPostScriptDC | |
23324ae1 FM |
430 | */ |
431 | class wxPrintData : public wxObject | |
432 | { | |
433 | public: | |
434 | //@{ | |
435 | /** | |
436 | Copy constructor. | |
437 | */ | |
438 | wxPrintData(); | |
7c913512 | 439 | wxPrintData(const wxPrintData& data); |
23324ae1 FM |
440 | //@} |
441 | ||
442 | /** | |
443 | Destructor. | |
444 | */ | |
445 | ~wxPrintData(); | |
446 | ||
447 | /** | |
448 | Returns the current bin (papersource). By default, the system is left to select | |
449 | the bin (@c wxPRINTBIN_DEFAULT is returned). | |
23324ae1 FM |
450 | See SetBin() for the full list of bin values. |
451 | */ | |
328f5751 | 452 | wxPrintBin GetBin() const; |
23324ae1 FM |
453 | |
454 | /** | |
455 | Returns @true if collation is on. | |
456 | */ | |
328f5751 | 457 | bool GetCollate() const; |
23324ae1 FM |
458 | |
459 | /** | |
460 | Returns @true if colour printing is on. | |
461 | */ | |
328f5751 | 462 | bool GetColour() const; |
23324ae1 FM |
463 | |
464 | /** | |
465 | Returns the duplex mode. One of wxDUPLEX_SIMPLEX, wxDUPLEX_HORIZONTAL, | |
466 | wxDUPLEX_VERTICAL. | |
467 | */ | |
328f5751 | 468 | wxDuplexMode GetDuplex() const; |
23324ae1 FM |
469 | |
470 | /** | |
471 | Returns the number of copies requested by the user. | |
472 | */ | |
328f5751 | 473 | int GetNoCopies() const; |
23324ae1 FM |
474 | |
475 | /** | |
476 | Gets the orientation. This can be wxLANDSCAPE or wxPORTRAIT. | |
477 | */ | |
328f5751 | 478 | int GetOrientation() const; |
23324ae1 FM |
479 | |
480 | /** | |
481 | Returns the paper size id. For more information, see SetPaperId(). | |
482 | */ | |
328f5751 | 483 | wxPaperSize GetPaperId() const; |
23324ae1 FM |
484 | |
485 | /** | |
486 | Returns the printer name. If the printer name is the empty string, it indicates | |
487 | that the default | |
488 | printer should be used. | |
489 | */ | |
328f5751 | 490 | const wxString GetPrinterName() const; |
23324ae1 FM |
491 | |
492 | /** | |
493 | Returns the current print quality. This can be a positive integer, denoting the | |
494 | number of dots per inch, or | |
495 | one of the following identifiers: | |
4cc4bfaf | 496 | |
23324ae1 FM |
497 | On input you should pass one of these identifiers, but on return you may get |
498 | back a positive integer | |
499 | indicating the current resolution setting. | |
500 | */ | |
328f5751 | 501 | wxPrintQuality GetQuality() const; |
23324ae1 FM |
502 | |
503 | /** | |
504 | Returns @true if the print data is valid for using in print dialogs. | |
505 | This can return @false on Windows if the current printer is not set, for example. | |
506 | On all other platforms, it returns @true. | |
507 | */ | |
328f5751 | 508 | bool IsOk() const; |
23324ae1 FM |
509 | |
510 | /** | |
511 | Sets the current bin. Possible values are: | |
512 | */ | |
513 | void SetBin(wxPrintBin flag); | |
514 | ||
515 | /** | |
516 | Sets collation to on or off. | |
517 | */ | |
518 | void SetCollate(bool flag); | |
519 | ||
520 | /** | |
521 | Sets colour printing on or off. | |
522 | */ | |
523 | void SetColour(bool flag); | |
524 | ||
525 | /** | |
526 | Returns the duplex mode. One of wxDUPLEX_SIMPLEX, wxDUPLEX_HORIZONTAL, | |
527 | wxDUPLEX_VERTICAL. | |
528 | */ | |
529 | void SetDuplex(wxDuplexMode mode); | |
530 | ||
531 | /** | |
532 | Sets the default number of copies to be printed out. | |
533 | */ | |
534 | void SetNoCopies(int n); | |
535 | ||
536 | /** | |
537 | Sets the orientation. This can be wxLANDSCAPE or wxPORTRAIT. | |
538 | */ | |
539 | void SetOrientation(int orientation); | |
540 | ||
541 | /** | |
542 | Sets the paper id. This indicates the type of paper to be used. For a mapping | |
543 | between | |
544 | paper id, paper size and string name, see wxPrintPaperDatabase in @c paper.h | |
545 | (not yet documented). | |
4cc4bfaf | 546 | @a paperId can be one of: |
23324ae1 FM |
547 | */ |
548 | void SetPaperId(wxPaperSize paperId); | |
549 | ||
550 | /** | |
551 | Sets the printer name. This can be the empty string to indicate that the default | |
552 | printer should be used. | |
553 | */ | |
554 | void SetPrinterName(const wxString& printerName); | |
555 | ||
556 | /** | |
557 | Sets the desired print quality. This can be a positive integer, denoting the | |
558 | number of dots per inch, or | |
559 | one of the following identifiers: | |
4cc4bfaf | 560 | |
23324ae1 FM |
561 | On input you should pass one of these identifiers, but on return you may get |
562 | back a positive integer | |
563 | indicating the current resolution setting. | |
564 | */ | |
565 | void SetQuality(wxPrintQuality quality); | |
566 | ||
567 | //@{ | |
568 | /** | |
569 | Assigns print setup data to this object. wxPrintSetupData is deprecated, | |
570 | but retained for backward compatibility. | |
571 | */ | |
572 | void operator =(const wxPrintData& data); | |
7c913512 | 573 | void operator =(const wxPrintSetupData& data); |
23324ae1 FM |
574 | //@} |
575 | }; | |
576 | ||
577 | ||
e54c96f1 | 578 | |
23324ae1 FM |
579 | /** |
580 | @class wxPrintDialogData | |
581 | @wxheader{cmndata.h} | |
7c913512 | 582 | |
23324ae1 FM |
583 | This class holds information related to the visual characteristics of |
584 | wxPrintDialog. | |
585 | It contains a wxPrintData object with underlying printing settings. | |
7c913512 | 586 | |
23324ae1 FM |
587 | @library{wxcore} |
588 | @category{printing} | |
7c913512 | 589 | |
e54c96f1 FM |
590 | @see @ref overview_printingoverview "Printing framework overview", |
591 | wxPrintDialog, @ref overview_wxprintdialogoverview "wxPrintDialog Overview" | |
23324ae1 FM |
592 | */ |
593 | class wxPrintDialogData : public wxObject | |
594 | { | |
595 | public: | |
596 | //@{ | |
597 | /** | |
598 | Construct an object from a print dialog data object. | |
599 | */ | |
600 | wxPrintDialogData(); | |
7c913512 FM |
601 | wxPrintDialogData(wxPrintDialogData& dialogData); |
602 | wxPrintDialogData(wxPrintData& printData); | |
23324ae1 FM |
603 | //@} |
604 | ||
605 | /** | |
606 | Destructor. | |
607 | */ | |
608 | ~wxPrintDialogData(); | |
609 | ||
610 | /** | |
611 | Enables or disables the 'Help' button. | |
612 | */ | |
613 | void EnableHelp(bool flag); | |
614 | ||
615 | /** | |
616 | Enables or disables the 'Page numbers' controls. | |
617 | */ | |
618 | void EnablePageNumbers(bool flag); | |
619 | ||
620 | /** | |
621 | Enables or disables the 'Print to file' checkbox. | |
622 | */ | |
623 | void EnablePrintToFile(bool flag); | |
624 | ||
625 | /** | |
626 | Enables or disables the 'Selection' radio button. | |
627 | */ | |
628 | void EnableSelection(bool flag); | |
629 | ||
630 | /** | |
631 | Returns @true if the user requested that all pages be printed. | |
632 | */ | |
328f5751 | 633 | bool GetAllPages() const; |
23324ae1 FM |
634 | |
635 | /** | |
636 | Returns @true if the user requested that the document(s) be collated. | |
637 | */ | |
328f5751 | 638 | bool GetCollate() const; |
23324ae1 FM |
639 | |
640 | /** | |
641 | Returns the @e from page number, as entered by the user. | |
642 | */ | |
328f5751 | 643 | int GetFromPage() const; |
23324ae1 FM |
644 | |
645 | /** | |
646 | Returns the @e maximum page number. | |
647 | */ | |
328f5751 | 648 | int GetMaxPage() const; |
23324ae1 FM |
649 | |
650 | /** | |
651 | Returns the @e minimum page number. | |
652 | */ | |
328f5751 | 653 | int GetMinPage() const; |
23324ae1 FM |
654 | |
655 | /** | |
656 | Returns the number of copies requested by the user. | |
657 | */ | |
328f5751 | 658 | int GetNoCopies() const; |
23324ae1 FM |
659 | |
660 | /** | |
661 | Returns a reference to the internal wxPrintData object. | |
662 | */ | |
663 | wxPrintData GetPrintData(); | |
664 | ||
665 | /** | |
666 | Returns @true if the user has selected printing to a file. | |
667 | */ | |
328f5751 | 668 | bool GetPrintToFile() const; |
23324ae1 FM |
669 | |
670 | /** | |
671 | Returns @true if the user requested that the selection be printed (where | |
672 | 'selection' is | |
673 | a concept specific to the application). | |
674 | */ | |
328f5751 | 675 | bool GetSelection() const; |
23324ae1 FM |
676 | |
677 | /** | |
678 | Returns the @e to page number, as entered by the user. | |
679 | */ | |
328f5751 | 680 | int GetToPage() const; |
23324ae1 FM |
681 | |
682 | /** | |
683 | Returns @true if the print data is valid for using in print dialogs. | |
684 | This can return @false on Windows if the current printer is not set, for example. | |
685 | On all other platforms, it returns @true. | |
686 | */ | |
328f5751 | 687 | bool IsOk() const; |
23324ae1 FM |
688 | |
689 | /** | |
690 | Sets the 'Collate' checkbox to @true or @false. | |
691 | */ | |
692 | void SetCollate(bool flag); | |
693 | ||
694 | /** | |
695 | Sets the @e from page number. | |
696 | */ | |
697 | void SetFromPage(int page); | |
698 | ||
699 | /** | |
700 | Sets the @e maximum page number. | |
701 | */ | |
702 | void SetMaxPage(int page); | |
703 | ||
704 | /** | |
705 | Sets the @e minimum page number. | |
706 | */ | |
707 | void SetMinPage(int page); | |
708 | ||
709 | /** | |
710 | Sets the default number of copies the user has requested to be printed out. | |
711 | */ | |
712 | void SetNoCopies(int n); | |
713 | ||
714 | /** | |
715 | Sets the internal wxPrintData. | |
716 | */ | |
717 | void SetPrintData(const wxPrintData& printData); | |
718 | ||
719 | /** | |
720 | Sets the 'Print to file' checkbox to @true or @false. | |
721 | */ | |
722 | void SetPrintToFile(bool flag); | |
723 | ||
724 | /** | |
725 | Selects the 'Selection' radio button. The effect of printing the selection | |
726 | depends on how the application | |
727 | implements this command, if at all. | |
728 | */ | |
729 | void SetSelection(bool flag); | |
730 | ||
731 | /** | |
732 | Determines whether the dialog to be shown will be the Print dialog | |
733 | (pass @false) or Print Setup dialog (pass @true). | |
23324ae1 FM |
734 | This function has been deprecated since version 2.5.4. |
735 | */ | |
736 | void SetSetupDialog(bool flag); | |
737 | ||
738 | /** | |
739 | Sets the @e to page number. | |
740 | */ | |
741 | void SetToPage(int page); | |
742 | ||
743 | //@{ | |
744 | /** | |
745 | Assigns another print dialog data object to this object. | |
746 | */ | |
747 | void operator =(const wxPrintData& data); | |
7c913512 | 748 | void operator =(const wxPrintDialogData& data); |
23324ae1 FM |
749 | //@} |
750 | }; | |
e54c96f1 | 751 |