|
1 <?xml version="1.0"?> <!-- -*- Mode: HTML -*- --> |
|
2 |
|
3 <!-- This Source Code Form is subject to the terms of the Mozilla Public |
|
4 - License, v. 2.0. If a copy of the MPL was not distributed with this |
|
5 - file, You can obtain one at http://mozilla.org/MPL/2.0/. --> |
|
6 |
|
7 <?xml-stylesheet href="chrome://global/skin/" type="text/css"?> |
|
8 <?xml-stylesheet href="chrome://global/skin/printPageSetup.css" type="text/css"?> |
|
9 <!DOCTYPE dialog SYSTEM "chrome://global/locale/printPageSetup.dtd"> |
|
10 |
|
11 <dialog xmlns="http://www.mozilla.org/keymaster/gatekeeper/there.is.only.xul" |
|
12 id="printPageSetupDialog" |
|
13 onload="onLoad();" |
|
14 ondialogaccept="return onAccept();" |
|
15 oncancel="return onCancel();" |
|
16 title="&printSetup.title;" |
|
17 persist="screenX screenY" |
|
18 screenX="24" screenY="24"> |
|
19 |
|
20 <script type="application/javascript" src="chrome://global/content/printPageSetup.js"/> |
|
21 |
|
22 <!-- Localizable strings manipulated at run-time. --> |
|
23 <data id="marginUnits.inches">&marginUnits.inches;</data> |
|
24 <data id="marginUnits.metric">&marginUnits.metric;</data> |
|
25 <data id="customPrompt.title">&customPrompt.title;</data> |
|
26 <data id="customPrompt.prompt">&customPrompt.prompt;</data> |
|
27 |
|
28 <tabbox flex="1"> |
|
29 <tabs> |
|
30 <tab label="&basic.tab;"/> |
|
31 <tab label="&advanced.tab;"/> |
|
32 </tabs> |
|
33 <tabpanels flex="1"> |
|
34 <vbox> |
|
35 <groupbox> |
|
36 <caption label="&formatGroup.label;"/> |
|
37 <vbox> |
|
38 <hbox align="center"> |
|
39 <label control="orientation" value="&orientation.label;"/> |
|
40 <radiogroup id="orientation" oncommand="setOrientation()"> |
|
41 <hbox align="center"> |
|
42 <radio id="portrait" |
|
43 class="portrait-page" |
|
44 label="&portrait.label;" |
|
45 accesskey="&portrait.accesskey;"/> |
|
46 <radio id="landscape" |
|
47 class="landscape-page" |
|
48 label="&landscape.label;" |
|
49 accesskey="&landscape.accesskey;"/> |
|
50 </hbox> |
|
51 </radiogroup> |
|
52 </hbox> |
|
53 <separator/> |
|
54 <hbox align="center"> |
|
55 <label control="scalingInput" |
|
56 value="&scale.label;" |
|
57 accesskey="&scale.accesskey;"/> |
|
58 <textbox id="scalingInput" size="4" oninput="checkDouble(this)"/> |
|
59 <label value="&scalePercent;"/> |
|
60 <separator/> |
|
61 <checkbox id="shrinkToFit" |
|
62 label="&shrinkToFit.label;" |
|
63 accesskey="&shrinkToFit.accesskey;" |
|
64 oncommand="gDialog.scalingInput.disabled=gDialog.scalingLabel.disabled=this.checked"/> |
|
65 </hbox> |
|
66 </vbox> |
|
67 </groupbox> |
|
68 <groupbox> |
|
69 <caption label="&optionsGroup.label;"/> |
|
70 <checkbox id="printBG" |
|
71 label="&printBG.label;" |
|
72 accesskey="&printBG.accesskey;"/> |
|
73 </groupbox> |
|
74 </vbox> |
|
75 <vbox> |
|
76 <groupbox> |
|
77 <caption id="marginGroup" label="&marginGroup.label;"/> |
|
78 <vbox> |
|
79 <hbox align="center"> |
|
80 <spacer flex="1"/> |
|
81 <label control="topInput" |
|
82 value="&marginTop.label;" |
|
83 accesskey="&marginTop.accesskey;"/> |
|
84 <textbox id="topInput" size="5" oninput="changeMargin(this)"/> |
|
85 <!-- This invisible label (with same content as the visible one!) is used |
|
86 to ensure that the <textbox> is centered above the page. The same |
|
87 technique is deployed for the bottom/left/right input fields, below. --> |
|
88 <label value="&marginTop.label;" style="visibility: hidden;"/> |
|
89 <spacer flex="1"/> |
|
90 </hbox> |
|
91 <hbox dir="ltr"> |
|
92 <spacer flex="1"/> |
|
93 <vbox> |
|
94 <spacer flex="1"/> |
|
95 <label control="leftInput" |
|
96 value="&marginLeft.label;" |
|
97 accesskey="&marginLeft.accesskey;"/> |
|
98 <textbox id="leftInput" size="5" oninput="changeMargin(this)"/> |
|
99 <label value="&marginLeft.label;" style="visibility: hidden;"/> |
|
100 <spacer flex="1"/> |
|
101 </vbox> |
|
102 <!-- The "margin page" draws a simulated printout page with dashed lines |
|
103 for the margins. The height/width style attributes of the marginTop, |
|
104 marginBottom, marginLeft, and marginRight elements are set by |
|
105 the JS code dynamically based on the user input. --> |
|
106 <vbox id="marginPage" style="height:29.7mm;"> |
|
107 <box id="marginTop" style="height:0.05in;"/> |
|
108 <hbox flex="1" dir="ltr"> |
|
109 <box id="marginLeft" style="width:0.025in;"/> |
|
110 <box style="border: 1px; border-style: dashed; border-color: gray;" flex="1"/> |
|
111 <box id="marginRight" style="width:0.025in;"/> |
|
112 </hbox> |
|
113 <box id="marginBottom" style="height:0.05in;"/> |
|
114 </vbox> |
|
115 <vbox> |
|
116 <spacer flex="1"/> |
|
117 <label control="rightInput" |
|
118 value="&marginRight.label;" |
|
119 accesskey="&marginRight.accesskey;"/> |
|
120 <textbox id="rightInput" size="5" oninput="changeMargin(this)"/> |
|
121 <label value="&marginRight.label;" style="visibility: hidden;"/> |
|
122 <spacer flex="1"/> |
|
123 </vbox> |
|
124 <spacer flex="1"/> |
|
125 </hbox> |
|
126 <hbox align="center"> |
|
127 <spacer flex="1"/> |
|
128 <label control="bottomInput" |
|
129 value="&marginBottom.label;" |
|
130 accesskey="&marginBottom.accesskey;"/> |
|
131 <textbox id="bottomInput" size="5" oninput="changeMargin(this)"/> |
|
132 <label value="&marginBottom.label;" style="visibility: hidden;"/> |
|
133 <spacer flex="1"/> |
|
134 </hbox> |
|
135 </vbox> |
|
136 </groupbox> |
|
137 <groupbox> |
|
138 <caption id="headersAndFooters" label="&headerFooter.label;"/> |
|
139 <grid> |
|
140 <columns> |
|
141 <column/> |
|
142 <column/> |
|
143 <column/> |
|
144 </columns> |
|
145 <rows> |
|
146 <row dir="ltr"> |
|
147 <menulist id="hLeftOption" oncommand="customize(this)" tooltiptext="&headerLeft.tip;"> |
|
148 <menupopup> |
|
149 <menuitem value="0" label="&hfBlank;"/> |
|
150 <menuitem value="1" label="&hfTitle;"/> |
|
151 <menuitem value="2" label="&hfURL;"/> |
|
152 <menuitem value="3" label="&hfDateAndTime;"/> |
|
153 <menuitem value="4" label="&hfPage;"/> |
|
154 <menuitem value="5" label="&hfPageAndTotal;"/> |
|
155 <menuitem value="6" label="&hfCustom;"/> |
|
156 </menupopup> |
|
157 </menulist> |
|
158 <menulist id="hCenterOption" oncommand="customize(this)" tooltiptext="&headerCenter.tip;"> |
|
159 <menupopup> |
|
160 <menuitem value="0" label="&hfBlank;"/> |
|
161 <menuitem value="1" label="&hfTitle;"/> |
|
162 <menuitem value="2" label="&hfURL;"/> |
|
163 <menuitem value="3" label="&hfDateAndTime;"/> |
|
164 <menuitem value="4" label="&hfPage;"/> |
|
165 <menuitem value="5" label="&hfPageAndTotal;"/> |
|
166 <menuitem value="6" label="&hfCustom;"/> |
|
167 </menupopup> |
|
168 </menulist> |
|
169 <menulist id="hRightOption" oncommand="customize(this)" tooltiptext="&headerRight.tip;"> |
|
170 <menupopup> |
|
171 <menuitem value="0" label="&hfBlank;"/> |
|
172 <menuitem value="1" label="&hfTitle;"/> |
|
173 <menuitem value="2" label="&hfURL;"/> |
|
174 <menuitem value="3" label="&hfDateAndTime;"/> |
|
175 <menuitem value="4" label="&hfPage;"/> |
|
176 <menuitem value="5" label="&hfPageAndTotal;"/> |
|
177 <menuitem value="6" label="&hfCustom;"/> |
|
178 </menupopup> |
|
179 </menulist> |
|
180 </row> |
|
181 <row dir="ltr"> |
|
182 <vbox align="center"> |
|
183 <label value="&hfLeft.label;"/> |
|
184 </vbox> |
|
185 <vbox align="center"> |
|
186 <label value="&hfCenter.label;"/> |
|
187 </vbox> |
|
188 <vbox align="center"> |
|
189 <label value="&hfRight.label;"/> |
|
190 </vbox> |
|
191 </row> |
|
192 <row dir="ltr"> |
|
193 <menulist id="fLeftOption" oncommand="customize(this)" tooltiptext="&footerLeft.tip;"> |
|
194 <menupopup> |
|
195 <menuitem value="0" label="&hfBlank;"/> |
|
196 <menuitem value="1" label="&hfTitle;"/> |
|
197 <menuitem value="2" label="&hfURL;"/> |
|
198 <menuitem value="3" label="&hfDateAndTime;"/> |
|
199 <menuitem value="4" label="&hfPage;"/> |
|
200 <menuitem value="5" label="&hfPageAndTotal;"/> |
|
201 <menuitem value="6" label="&hfCustom;"/> |
|
202 </menupopup> |
|
203 </menulist> |
|
204 <menulist id="fCenterOption" oncommand="customize(this)" tooltiptext="&footerCenter.tip;"> |
|
205 <menupopup> |
|
206 <menuitem value="0" label="&hfBlank;"/> |
|
207 <menuitem value="1" label="&hfTitle;"/> |
|
208 <menuitem value="2" label="&hfURL;"/> |
|
209 <menuitem value="3" label="&hfDateAndTime;"/> |
|
210 <menuitem value="4" label="&hfPage;"/> |
|
211 <menuitem value="5" label="&hfPageAndTotal;"/> |
|
212 <menuitem value="6" label="&hfCustom;"/> |
|
213 </menupopup> |
|
214 </menulist> |
|
215 <menulist id="fRightOption" oncommand="customize(this)" tooltiptext="&footerRight.tip;"> |
|
216 <menupopup> |
|
217 <menuitem value="0" label="&hfBlank;"/> |
|
218 <menuitem value="1" label="&hfTitle;"/> |
|
219 <menuitem value="2" label="&hfURL;"/> |
|
220 <menuitem value="3" label="&hfDateAndTime;"/> |
|
221 <menuitem value="4" label="&hfPage;"/> |
|
222 <menuitem value="5" label="&hfPageAndTotal;"/> |
|
223 <menuitem value="6" label="&hfCustom;"/> |
|
224 </menupopup> |
|
225 </menulist> |
|
226 </row> |
|
227 </rows> |
|
228 </grid> |
|
229 </groupbox> |
|
230 </vbox> |
|
231 </tabpanels> |
|
232 </tabbox> |
|
233 </dialog> |
|
234 |