File: wx269.htm

package info (click to toggle)
wxwin2-doc 2.01-1
  • links: PTS
  • area: main
  • in suites: potato
  • size: 6,540 kB
  • ctags: 5,968
  • sloc: cpp: 15,157; makefile: 434; sh: 6
file content (146 lines) | stat: -rw-r--r-- 5,157 bytes parent folder | download
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
24
25
26
27
28
29
30
31
32
33
34
35
36
37
38
39
40
41
42
43
44
45
46
47
48
49
50
51
52
53
54
55
56
57
58
59
60
61
62
63
64
65
66
67
68
69
70
71
72
73
74
75
76
77
78
79
80
81
82
83
84
85
86
87
88
89
90
91
92
93
94
95
96
97
98
99
100
101
102
103
104
105
106
107
108
109
110
111
112
113
114
115
116
117
118
119
120
121
122
123
124
125
126
127
128
129
130
131
132
133
134
135
136
137
138
139
140
141
142
143
144
145
146
<HTML>
<head><title>Printer settings</title></head>

<BODY BGCOLOR=#FFFFFF>
<A NAME="printersettings"></A><CENTER>
<A HREF="wx.htm"><img align=center src="contents.gif" BORDER=0 ALT="Contents"></A> <A HREF="wx264.htm#functions"><img align=center src="up.gif" BORDER=0 ALT="Up"></A> <A HREF="wx268.htm#gdifunctions"><img align=center src="back.gif" BORDER=0 ALT="Previous"></A> <A HREF="wx270.htm#clipsboard"><img align=center src="forward.gif" BORDER=0 ALT="Next"></A> </CENTER><HR>

<H2>Printer settings</H2>
<P>
The following functions are used to control PostScript printing. Under
Windows, PostScript output can only be sent to a file.<P>
<B><FONT COLOR="#FF0000">Include files</FONT></B><P>
&lt;wx/dcps.h&gt;<P>
<A HREF="#topic1065">::wxGetPrinterCommand</A><BR>
<A HREF="#topic1066">::wxGetPrinterFile</A><BR>
<A HREF="#topic1067">::wxGetPrinterMode</A><BR>
<A HREF="#topic1068">::wxGetPrinterOptions</A><BR>
<A HREF="#topic1069">::wxGetPrinterOrientation</A><BR>
<A HREF="#topic1070">::wxGetPrinterPreviewCommand</A><BR>
<A HREF="#topic1071">::wxGetPrinterScaling</A><BR>
<A HREF="#topic1072">::wxGetPrinterTranslation</A><BR>
<A HREF="#topic1073">::wxSetPrinterCommand</A><BR>
<A HREF="#topic1074">::wxSetPrinterFile</A><BR>
<A HREF="#topic1075">::wxSetPrinterMode</A><BR>
<A HREF="#topic1076">::wxSetPrinterOptions</A><BR>
<A HREF="#topic1077">::wxSetPrinterOrientation</A><BR>
<A HREF="#topic1078">::wxSetPrinterPreviewCommand</A><BR>
<A HREF="#topic1079">::wxSetPrinterScaling</A><BR>
<A HREF="#topic1080">::wxSetPrinterTranslation</A><BR>
<P>

<HR>
<A NAME="topic1065"></A>
<H3>::wxGetPrinterCommand</H3>
<P>
<B>wxString</B> <B>wxGetPrinterCommand</B>()<P>
Gets the printer command used to print a file. The default is <TT>lpr</TT>.<P>

<HR>
<A NAME="topic1066"></A>
<H3>::wxGetPrinterFile</H3>
<P>
<B>wxString</B> <B>wxGetPrinterFile</B>()<P>
Gets the PostScript output filename.<P>

<HR>
<A NAME="topic1067"></A>
<H3>::wxGetPrinterMode</H3>
<P>
<B>int</B> <B>wxGetPrinterMode</B>()<P>
Gets the printing mode controlling where output is sent (PS_PREVIEW, PS_FILE or PS_PRINTER).
The default is PS_PREVIEW.<P>

<HR>
<A NAME="topic1068"></A>
<H3>::wxGetPrinterOptions</H3>
<P>
<B>wxString</B> <B>wxGetPrinterOptions</B>()<P>
Gets the additional options for the print command (e.g. specific printer). The default is nothing.<P>

<HR>
<A NAME="topic1069"></A>
<H3>::wxGetPrinterOrientation</H3>
<P>
<B>int</B> <B>wxGetPrinterOrientation</B>()<P>
Gets the orientation (PS_PORTRAIT or PS_LANDSCAPE). The default is PS_PORTRAIT.<P>

<HR>
<A NAME="topic1070"></A>
<H3>::wxGetPrinterPreviewCommand</H3>
<P>
<B>wxString</B> <B>wxGetPrinterPreviewCommand</B>()<P>
Gets the command used to view a PostScript file. The default depends on the platform.<P>

<HR>
<A NAME="topic1071"></A>
<H3>::wxGetPrinterScaling</H3>
<P>
<B>void</B> <B>wxGetPrinterScaling</B>(<B>float *</B><I>x</I>, <B>float *</B><I>y</I>)<P>
Gets the scaling factor for PostScript output. The default is 1.0, 1.0.<P>

<HR>
<A NAME="topic1072"></A>
<H3>::wxGetPrinterTranslation</H3>
<P>
<B>void</B> <B>wxGetPrinterTranslation</B>(<B>float *</B><I>x</I>, <B>float *</B><I>y</I>)<P>
Gets the translation (from the top left corner) for PostScript output. The default is 0.0, 0.0.<P>

<HR>
<A NAME="topic1073"></A>
<H3>::wxSetPrinterCommand</H3>
<P>
<B>void</B> <B>wxSetPrinterCommand</B>(<B>const wxString&amp; </B><I>command</I>)<P>
Sets the printer command used to print a file. The default is <TT>lpr</TT>.<P>

<HR>
<A NAME="topic1074"></A>
<H3>::wxSetPrinterFile</H3>
<P>
<B>void</B> <B>wxSetPrinterFile</B>(<B>const wxString&amp; </B><I>filename</I>)<P>
Sets the PostScript output filename.<P>

<HR>
<A NAME="topic1075"></A>
<H3>::wxSetPrinterMode</H3>
<P>
<B>void</B> <B>wxSetPrinterMode</B>(<B>int </B><I>mode</I>)<P>
Sets the printing mode controlling where output is sent (PS_PREVIEW, PS_FILE or PS_PRINTER).
The default is PS_PREVIEW.<P>

<HR>
<A NAME="topic1076"></A>
<H3>::wxSetPrinterOptions</H3>
<P>
<B>void</B> <B>wxSetPrinterOptions</B>(<B>const wxString&amp; </B><I>options</I>)<P>
Sets the additional options for the print command (e.g. specific printer). The default is nothing.<P>

<HR>
<A NAME="topic1077"></A>
<H3>::wxSetPrinterOrientation</H3>
<P>
<B>void</B> <B>wxSetPrinterOrientation</B>(<B>int</B><I> orientation</I>)<P>
Sets the orientation (PS_PORTRAIT or PS_LANDSCAPE). The default is PS_PORTRAIT.<P>

<HR>
<A NAME="topic1078"></A>
<H3>::wxSetPrinterPreviewCommand</H3>
<P>
<B>void</B> <B>wxSetPrinterPreviewCommand</B>(<B>const wxString&amp; </B><I>command</I>)<P>
Sets the command used to view a PostScript file. The default depends on the platform.<P>

<HR>
<A NAME="topic1079"></A>
<H3>::wxSetPrinterScaling</H3>
<P>
<B>void</B> <B>wxSetPrinterScaling</B>(<B>float </B><I>x</I>, <B>float </B><I>y</I>)<P>
Sets the scaling factor for PostScript output. The default is 1.0, 1.0.<P>

<HR>
<A NAME="topic1080"></A>
<H3>::wxSetPrinterTranslation</H3>
<P>
<B>void</B> <B>wxSetPrinterTranslation</B>(<B>float </B><I>x</I>, <B>float </B><I>y</I>)<P>
Sets the translation (from the top left corner) for PostScript output. The default is 0.0, 0.0.<P>

</BODY></HTML>