Before the print job dialog can be displayed an instance of the printer class must be allocated, this instance is used by the dialog to retrieve the current printer settings and store the new settings chosen by the user. If the dialog is closed by pressing on the "Ok" button the settings are stored in the printer instance, the printer instance can be assigned by the method putPrinter/1. The number of copies and the orientation of the paper can be set by the methods putNumCopies/1 and putLandscape/1. To set the size of the paper there are 41 predefined sizes, these are:ID Atomic name Name Size (Width x Height) 1 ps_letter Letter 215 x 279 mm (8 1/2 x 11 inch) 2 ps_lettersmall Letter small 215 x 279 mm (8 1/2 x 11 inch) 3 ps_tabloid Tabloid 279 x 431 mm (11 x 17 inch) 4 ps_ledger Ledger 431x 279 mm (17 x 11 inch) 5 ps_legal Legal 215 x 355 mm (8 1/2 x 14 inch) 6 ps_statement Statement 139 x 215 mm (5 1/2 x 8 1/2 inch) 7 ps_executive Executive 184 x 266 mm (7 1/4 x 10 1/2 inch) 8 ps_a3 A3 297 x 420 mm 9 ps_a4 A4 210 x 297 mm 10 ps_a4small A4 small 210 x 297 mm 11 ps_a5 A5 148 x 210 mm 12 ps_b4 B4 250 x 354 mm 13 ps_b5 B5 182 x 257mm 14 ps_folio Folio 215 x 330 mm (8 1/2 x 13 inch) 15 ps_quarto Quarto 215 x 275 mm 16 ps_10x14 10x14 254 x 355 mm (0x14 inch) 17 ps_11x17 11x17 279 x 431 mm (11x17 inch) 18 ps_note Note 215 x 279 mm (8 1/2 x 11 inch) 19 ps_env_9 Envelope #9 984 x 225 mm ( 3 7/8 x 8 7/8 inch) 20 ps_env_10 Envelope #10 104 x 241 mm (4 1/8 x 9 1/2 inch) 21 ps_env_11 Envelope #11 114 x 263 mm (4 1/2 x 10 3/8 inch) 22 ps_env_12 Envelope #12 120 x 279 mm (4 \276 x 11 inch) 23 ps_env_14 Envelope #14 127 x 292 mm (5 x 11 1/2 inch) 24 ps_csheet C size sheet 431 x 558 mm 25 ps_dsheet D size sheet 558 x 863 mm 26 ps_esheet E size sheet 863 x 1117 mm 27 ps_env_dl Envelope DL 110 x 220 mm 28 ps_env_c5 Envelope C5 162 x 229 mm 29 ps_env_c3 Envelope C3 324 x 458 mm 30 ps_env_c4 Envelope C4 229 x 324 mm 31 ps_env_c6 Envelope C6 114 x 162 mm 32 ps_env_c65 Envelope C65 114 x 229 mm 33 ps_env_b4 Envelope B4 250 x 353 mm 34 ps_env_b5 Envelope B5 176 x 250 mm 35 ps_env_b6 Envelope B6 176 x 125 mm 36 ps_env_italy Envelope Italy 110 x 230 mm 37 ps_env_monarch Envelope monarch 98 x 190) mm (3.875 x 7.5 inch) 38 ps_env_personal Envelope personal 92 x 165 mm (3 5/8 x 6 1/2 inch) 39 ps_fanfold_us Fanfold us 377 x 279 mm (14 7/8 x 11 inch) 40 ps_fanfold_std_german Fanfold standard german 215 x 304 (8 1/2 x 12 inch) 41 ps_fanfold_lgl_german Fanfold legal german 215 x 330 (8 1/2 x 13 inch)
To set the size of the paper there are 41 predefined sizes, these are:ID Atomic name Name Size (Width x Height)
1 ps_letter Letter 215 x 279 mm (8 1/2 x 11 inch)
2 ps_lettersmall Letter small 215 x 279 mm (8 1/2 x 11 inch)
3 ps_tabloid Tabloid 279 x 431 mm (11 x 17 inch)
4 ps_ledger Ledger 431x 279 mm (17 x 11 inch)
5 ps_legal Legal 215 x 355 mm (8 1/2 x 14 inch)
6 ps_statement Statement 139 x 215 mm (5 1/2 x 8 1/2 inch)
7 ps_executive Executive 184 x 266 mm (7 1/4 x 10 1/2 inch)
8 ps_a3 A3 297 x 420 mm
9 ps_a4 A4 210 x 297 mm
10 ps_a4small A4 small 210 x 297 mm
11 ps_a5 A5 148 x 210 mm
12 ps_b4 B4 250 x 354 mm
13 ps_b5 B5 182 x 257mm
14 ps_folio Folio 215 x 330 mm (8 1/2 x 13 inch)
15 ps_quarto Quarto 215 x 275 mm
16 ps_10x14 10x14 254 x 355 mm (0x14 inch)
17 ps_11x17 11x17 279 x 431 mm (11x17 inch)
18 ps_note Note 215 x 279 mm (8 1/2 x 11 inch)
19 ps_env_9 Envelope #9 984 x 225 mm ( 3 7/8 x 8 7/8 inch)
20 ps_env_10 Envelope #10 104 x 241 mm (4 1/8 x 9 1/2 inch)
21 ps_env_11 Envelope #11 114 x 263 mm (4 1/2 x 10 3/8 inch)
22 ps_env_12 Envelope #12 120 x 279 mm (4 \276 x 11 inch)
23 ps_env_14 Envelope #14 127 x 292 mm (5 x 11 1/2 inch)
24 ps_csheet C size sheet 431 x 558 mm
25 ps_dsheet D size sheet 558 x 863 mm
26 ps_esheet E size sheet 863 x 1117 mm
27 ps_env_dl Envelope DL 110 x 220 mm
28 ps_env_c5 Envelope C5 162 x 229 mm
29 ps_env_c3 Envelope C3 324 x 458 mm
30 ps_env_c4 Envelope C4 229 x 324 mm
31 ps_env_c6 Envelope C6 114 x 162 mm
32 ps_env_c65 Envelope C65 114 x 229 mm
33 ps_env_b4 Envelope B4 250 x 353 mm
34 ps_env_b5 Envelope B5 176 x 250 mm
35 ps_env_b6 Envelope B6 176 x 125 mm
36 ps_env_italy Envelope Italy 110 x 230 mm
37 ps_env_monarch Envelope monarch 98 x 190) mm (3.875 x 7.5 inch)
38 ps_env_personal Envelope personal 92 x 165 mm (3 5/8 x 6 1/2 inch)
39 ps_fanfold_us Fanfold us 377 x 279 mm (14 7/8 x 11 inch)
40 ps_fanfold_std_german Fanfold standard german 215 x 304 (8 1/2 x 12 inch)
41 ps_fanfold_lgl_german Fanfold legal german 215 x 330 (8 1/2 x 13 inch)