]> git.ipfire.org Git - thirdparty/cups.git/blame - doc/help/api-ppd.html
Changelog.
[thirdparty/cups.git] / doc / help / api-ppd.html
CommitLineData
abacc52b 1<!doctype html>
ef416fc2 2<html>
3<!-- SECTION: Programming -->
abacc52b
MS
4 <head>
5 <title>PPD API (DEPRECATED)</title>
6 <meta name="keywords" content="Programming">
7 <meta http-equiv="Content-Type" content="text/html;charset=utf-8">
8 <meta name="creator" content="Mini-XML v2.11">
9 <meta name="author" content="Unknown">
10 <meta name="copyright" content="Unknown">
11 <style type="text/css"><!--
5a738aea
MS
12BODY {
13 font-family: lucida grande, geneva, helvetica, arial, sans-serif;
14}
15
16H1, H2, H3, H4, H5, H6, P, TD, TH {
17 font-family: lucida grande, geneva, helvetica, arial, sans-serif;
18}
19
20KBD {
21 font-family: monaco, courier, monospace;
22 font-weight: bold;
23}
24
25PRE {
26 font-family: monaco, courier, monospace;
27}
28
29PRE.command {
10d09e33 30 border: dotted thin #7f7f7f;
5a738aea 31 margin-left: 36pt;
10d09e33 32 padding: 10px;
5a738aea
MS
33}
34
f11a948a
MS
35P.compact {
36 margin: 0;
37}
38
e4572d57
MS
39P.example {
40 font-style: italic;
41 margin-left: 36pt;
42}
ca6b43fc 43
240214ef
MS
44DL.man DD {
45 margin-left: 5em;
46}
47
48DL.man DT {
49 margin-left: 0;
50}
51
52PRE.man {
53 margin: 0;
54}
55
5a738aea
MS
56PRE.example {
57 background: #eeeeee;
58 border: dotted thin #999999;
59 margin-left: 36pt;
178cb736 60 padding: 10pt;
5a738aea
MS
61}
62
63PRE.command EM, PRE.example EM {
64 font-family: lucida grande, geneva, helvetica, arial, sans-serif;
65}
66
67P.command {
68 font-family: monaco, courier, monospace;
69 margin-left: 36pt;
70}
71
72P.formula {
73 font-style: italic;
74 margin-left: 36pt;
75}
76
77BLOCKQUOTE {
178cb736 78 background: #eeeeee;
5a738aea
MS
79 border: solid thin #999999;
80 padding: 10pt;
81}
82
e4572d57
MS
83A IMG {
84 border: none;
85}
86
87A:link:hover IMG {
88 background: #f0f0f0;
89 border-radius: 10px;
90 -moz-border-radius: 10px;
91}
92
5a738aea 93A:link, A:visited {
ca6b43fc 94 font-weight: inherit;
5a738aea 95 text-decoration: none;
5a738aea
MS
96}
97
98A:link:hover, A:visited:hover, A:active {
99 text-decoration: underline;
5a738aea
MS
100}
101
102SUB, SUP {
103 font-size: 50%;
104}
105
e4572d57
MS
106TR.data, TD.data, TR.data TD {
107 margin-top: 10pt;
108 padding: 5pt;
109 border-bottom: solid 1pt #999999;
110}
111
112TR.data TH {
113 border-bottom: solid 1pt #999999;
114 padding-top: 10pt;
115 padding-left: 5pt;
116 text-align: left;
117}
118
5a738aea
MS
119DIV.table TABLE {
120 border: solid thin #999999;
121 border-collapse: collapse;
122 border-spacing: 0;
123 margin-left: auto;
124 margin-right: auto;
125}
126
127DIV.table CAPTION {
128 caption-side: top;
129 font-size: 120%;
130 font-style: italic;
131 font-weight: bold;
132 margin-left: auto;
133 margin-right: auto;
134}
135
136DIV.table TABLE TD {
137 border: solid thin #cccccc;
138 padding-top: 5pt;
139}
140
141DIV.table TABLE TH {
142 background: #cccccc;
143 border: none;
144 border-bottom: solid thin #999999;
145}
146
147DIV.figure TABLE {
148 margin-left: auto;
149 margin-right: auto;
150}
151
152DIV.figure CAPTION {
153 caption-side: bottom;
154 font-size: 120%;
155 font-style: italic;
156 font-weight: bold;
157 margin-left: auto;
158 margin-right: auto;
159}
160
161TH.label {
5a738aea
MS
162 text-align: right;
163 vertical-align: top;
164}
165
e4572d57
MS
166TH.sublabel {
167 text-align: right;
168 font-weight: normal;
169}
170
5a738aea
MS
171HR {
172 border: solid thin;
173}
174
175SPAN.info {
e4572d57
MS
176 background: black;
177 border: thin solid black;
178 color: white;
5a738aea
MS
179 font-size: 80%;
180 font-style: italic;
181 font-weight: bold;
182 white-space: nowrap;
183}
184
185H2 SPAN.info, H3 SPAN.info, H4 SPAN.info {
186 float: right;
187 font-size: 100%;
188}
189
178cb736
MS
190H1.title {
191}
192
5a738aea
MS
193H2.title, H3.title {
194 border-bottom: solid 2pt #000000;
195}
196
e4572d57
MS
197DIV.indent, TABLE.indent {
198 margin-top: 2em;
199 margin-left: auto;
200 margin-right: auto;
201 width: 90%;
202}
203
204TABLE.indent {
205 border-collapse: collapse;
206}
207
208TABLE.indent TD, TABLE.indent TH {
209 padding: 0;
210}
211
212TABLE.list {
213 border-collapse: collapse;
214 margin-left: auto;
215 margin-right: auto;
216 width: 90%;
217}
218
219TABLE.list TH {
220 background: white;
221 border-bottom: solid thin #cccccc;
222 color: #444444;
223 padding-top: 10pt;
224 padding-left: 5pt;
225 text-align: left;
226 vertical-align: bottom;
227 white-space: nowrap;
228}
229
230TABLE.list TH A {
231 color: #4444cc;
232}
233
234TABLE.list TD {
235 border-bottom: solid thin #eeeeee;
236 padding-top: 5pt;
237 padding-left: 5pt;
238}
239
240TABLE.list TR:nth-child(even) {
241 background: #f8f8f8;
242}
243
244TABLE.list TR:nth-child(odd) {
245 background: #f4f4f4;
246}
247
5a738aea
MS
248DT {
249 margin-left: 36pt;
250 margin-top: 12pt;
251}
252
253DD {
254 margin-left: 54pt;
255}
256
257DL.category DT {
258 font-weight: bold;
259}
260
261P.summary {
262 margin-left: 36pt;
263 font-family: monaco, courier, monospace;
264}
265
5a738aea
MS
266DIV.summary TABLE {
267 border: solid thin #999999;
268 border-collapse: collapse;
269 border-spacing: 0;
270 margin: 10px;
271}
272
273DIV.summary TABLE TD, DIV.summary TABLE TH {
274 border: solid thin #999999;
275 padding: 5px;
276 text-align: left;
277 vertical-align: top;
278}
279
280DIV.summary TABLE THEAD TH {
281 background: #eeeeee;
282}
283
284/* API documentation styles... */
285div.body h1 {
286 margin: 0;
287}
288div.body h2 {
289 margin-top: 1.5em;
290}
291div.body h3, div.body h4, div.body h5 {
292 margin-bottom: 0.5em;
293 margin-top: 1.5em;
294}
295.class, .enumeration, .function, .struct, .typedef, .union {
296 border-bottom: solid thin #999999;
297 margin-bottom: 0;
298 margin-top: 2em;
299}
300.description {
301 margin-top: 0.5em;
302}
303code, p.code, pre, ul.code li {
304 font-family: monaco, courier, monospace;
305 font-size: 90%;
306}
307ul.code, ul.contents, ul.subcontents {
308 list-style-type: none;
309 margin: 0;
310 padding-left: 0;
311}
312ul.code li {
313 margin: 0;
314}
315ul.contents > li {
316 margin-top: 1em;
317}
318ul.contents li ul.code, ul.contents li ul.subcontents {
319 padding-left: 2em;
320}
321div.body dl {
322 margin-left: 0;
323 margin-top: 0;
324}
325div.body dt {
326 font-style: italic;
327 margin-left: 0;
328 margin-top: 0;
329}
330div.body dd {
331 margin-bottom: 0.5em;
332}
333
334/* This is just for the HTML files generated with the framedhelp target */
335div.contents {
336 background: #e8e8e8;
337 border: solid thin black;
338 padding: 10px;
339}
340div.contents h1 {
341 font-size: 110%;
342}
343div.contents h2 {
344 font-size: 100%;
345}
346div.contents ul.contents {
347 font-size: 80%;
348}
ac884b6a
MS
349div.contents ul.subcontents li {
350 margin-left: 1em;
351 text-indent: -1em;
352}
5a738aea 353--></style>
abacc52b
MS
354 </head>
355 <body>
ef416fc2 356<!--
321d8d57 357 PPD API header for CUPS.
5a738aea 358
f3c17241 359 Copyright 2008-2012 by Apple Inc.
5a738aea
MS
360
361 These coded instructions, statements, and computer programs are the
362 property of Apple Inc. and are protected by Federal copyright
363 law. Distribution and use rights are outlined in the file "LICENSE.txt"
364 which should have been included with this file. If this file is
365 file is missing or damaged, see the license at "http://www.cups.org/".
366-->
367
a2326b5b
MS
368<h1 class='title'>PPD API (DEPRECATED)</h1>
369
8072030b 370<blockquote>The PPD API is deprecated starting in CUPS 1.6/macOS 10.8. Please use the new Job Ticket APIs in the <a href="api-cups.html">CUPS API</a> documentation. These functions will be removed in a future release of CUPS.</blockquote>
178cb736 371
5a738aea
MS
372<div class='summary'><table summary='General Information'>
373<thead>
374<tr>
375 <th>Header</th>
376 <th>cups/ppd.h</th>
377</tr>
378</thead>
379<tbody>
380<tr>
381 <th>Library</th>
382 <td>-lcups</td>
383</tr>
384<tr>
385 <th>See Also</th>
386 <td>Programming: <a href='api-overview.html' target='_top'>Introduction to CUPS Programming</a><br>
387 Programming: <a href='api-cups.html' target='_top'>CUPS API</a><br>
79e1d494 388 Specifications: <a href='spec-ppd.html' target='_top'>CUPS PPD Extensions</a></td>
5a738aea
MS
389</tr>
390</tbody>
391</table></div>
abacc52b
MS
392 <div class="contents">
393 <h2 class="title">Contents</h2>
394 <ul class="contents">
395 <li><a href="#OVERVIEW">Overview</a><ul class="subcontents">
396 <li><a href="#LOADING">Loading a PPD File</a></li>
397 <li><a href="#OPTIONS_AND_GROUPS">Options and Groups</a></li>
398 <li><a href="#CONSTRAINTS">Constraints</a></li>
399 <li><a href="#PAGE_SIZES">Page Sizes</a></li>
400 <li><a href="#ATTRIBUTES">Attributes</a></li>
401 </ul></li>
402 <li><a href="#FUNCTIONS">Functions</a><ul class="subcontents">
403 <li><a href="#cupsGetConflicts">cupsGetConflicts</a></li>
404 <li><a href="#cupsGetPPD">cupsGetPPD</a></li>
405 <li><a href="#cupsGetPPD2">cupsGetPPD2</a></li>
406 <li><a href="#cupsGetPPD3">cupsGetPPD3</a></li>
407 <li><a href="#cupsGetServerPPD">cupsGetServerPPD</a></li>
408 <li><a href="#cupsMarkOptions">cupsMarkOptions</a></li>
409 <li><a href="#cupsResolveConflicts">cupsResolveConflicts</a></li>
410 <li><a href="#ppdCollect">ppdCollect</a></li>
411 <li><a href="#ppdCollect2">ppdCollect2</a></li>
412 <li><a href="#ppdConflicts">ppdConflicts</a></li>
413 <li><a href="#ppdEmit">ppdEmit</a></li>
414 <li><a href="#ppdEmitAfterOrder">ppdEmitAfterOrder</a></li>
415 <li><a href="#ppdEmitFd">ppdEmitFd</a></li>
416 <li><a href="#ppdEmitJCL">ppdEmitJCL</a></li>
417 <li><a href="#ppdEmitJCLEnd">ppdEmitJCLEnd</a></li>
418 <li><a href="#ppdEmitString">ppdEmitString</a></li>
419 <li><a href="#ppdFindAttr">ppdFindAttr</a></li>
420 <li><a href="#ppdFindChoice">ppdFindChoice</a></li>
421 <li><a href="#ppdFindCustomOption">ppdFindCustomOption</a></li>
422 <li><a href="#ppdFindCustomParam">ppdFindCustomParam</a></li>
423 <li><a href="#ppdFindMarkedChoice">ppdFindMarkedChoice</a></li>
424 <li><a href="#ppdFindNextAttr">ppdFindNextAttr</a></li>
425 <li><a href="#ppdFindOption">ppdFindOption</a></li>
426 <li><a href="#ppdFirstCustomParam">ppdFirstCustomParam</a></li>
427 <li><a href="#ppdFirstOption">ppdFirstOption</a></li>
428 <li><a href="#ppdInstallableConflict">ppdInstallableConflict</a></li>
429 <li><a href="#ppdIsMarked">ppdIsMarked</a></li>
430 <li><a href="#ppdLocalize">ppdLocalize</a></li>
431 <li><a href="#ppdLocalizeAttr">ppdLocalizeAttr</a></li>
432 <li><a href="#ppdLocalizeIPPReason">ppdLocalizeIPPReason</a></li>
433 <li><a href="#ppdLocalizeMarkerName">ppdLocalizeMarkerName</a></li>
434 <li><a href="#ppdMarkDefaults">ppdMarkDefaults</a></li>
435 <li><a href="#ppdMarkOption">ppdMarkOption</a></li>
436 <li><a href="#ppdNextCustomParam">ppdNextCustomParam</a></li>
437 <li><a href="#ppdNextOption">ppdNextOption</a></li>
438 <li><a href="#ppdPageLength">ppdPageLength</a></li>
439 <li><a href="#ppdPageSize">ppdPageSize</a></li>
440 <li><a href="#ppdPageSizeLimits">ppdPageSizeLimits</a></li>
441 <li><a href="#ppdPageWidth">ppdPageWidth</a></li>
442 </ul></li>
443 <li><a href="#TYPES">Data Types</a><ul class="subcontents">
444 <li><a href="#ppd_attr_t">ppd_attr_t</a></li>
445 <li><a href="#ppd_choice_t">ppd_choice_t</a></li>
446 <li><a href="#ppd_conform_t">ppd_conform_t</a></li>
447 <li><a href="#ppd_const_t">ppd_const_t</a></li>
448 <li><a href="#ppd_coption_t">ppd_coption_t</a></li>
449 <li><a href="#ppd_cparam_t">ppd_cparam_t</a></li>
450 <li><a href="#ppd_cplimit_t">ppd_cplimit_t</a></li>
451 <li><a href="#ppd_cptype_t">ppd_cptype_t</a></li>
452 <li><a href="#ppd_cpvalue_t">ppd_cpvalue_t</a></li>
453 <li><a href="#ppd_cs_t">ppd_cs_t</a></li>
454 <li><a href="#ppd_emul_t">ppd_emul_t</a></li>
455 <li><a href="#ppd_file_t">ppd_file_t</a></li>
456 <li><a href="#ppd_group_t">ppd_group_t</a></li>
457 <li><a href="#ppd_option_t">ppd_option_t</a></li>
458 <li><a href="#ppd_profile_t">ppd_profile_t</a></li>
459 <li><a href="#ppd_section_t">ppd_section_t</a></li>
460 <li><a href="#ppd_size_t">ppd_size_t</a></li>
461 <li><a href="#ppd_status_t">ppd_status_t</a></li>
462 <li><a href="#ppd_ui_t">ppd_ui_t</a></li>
463 </ul></li>
464 <li><a href="#STRUCTURES">Structures</a><ul class="subcontents">
465 <li><a href="#ppd_attr_s">ppd_attr_s</a></li>
466 <li><a href="#ppd_choice_s">ppd_choice_s</a></li>
467 <li><a href="#ppd_const_s">ppd_const_s</a></li>
468 <li><a href="#ppd_coption_s">ppd_coption_s</a></li>
469 <li><a href="#ppd_cparam_s">ppd_cparam_s</a></li>
470 <li><a href="#ppd_emul_s">ppd_emul_s</a></li>
471 <li><a href="#ppd_file_s">ppd_file_s</a></li>
472 <li><a href="#ppd_group_s">ppd_group_s</a></li>
473 <li><a href="#ppd_option_s">ppd_option_s</a></li>
474 <li><a href="#ppd_profile_s">ppd_profile_s</a></li>
475 <li><a href="#ppd_size_s">ppd_size_s</a></li>
476 </ul></li>
477 <li><a href="#UNIONS">Unions</a><ul class="subcontents">
478 <li><a href="#ppd_cplimit_u">ppd_cplimit_u</a></li>
479 <li><a href="#ppd_cpvalue_u">ppd_cpvalue_u</a></li>
480 </ul></li>
481 <li><a href="#ENUMERATIONS">Enumerations</a><ul class="subcontents">
482 <li><a href="#ppd_conform_e">ppd_conform_e</a></li>
483 <li><a href="#ppd_cs_e">ppd_cs_e</a></li>
484 <li><a href="#ppd_section_e">ppd_section_e</a></li>
485 <li><a href="#ppd_status_e">ppd_status_e</a></li>
486 <li><a href="#ppd_ui_e">ppd_ui_e</a></li>
487 </ul></li>
488 </ul>
489 </div>
490 <div class="body">
5a738aea 491<!--
eac3a0a0 492 PPD API introduction for CUPS.
ef416fc2 493
f3c17241 494 Copyright 2007-2012 by Apple Inc.
bc44d920 495 Copyright 1997-2006 by Easy Software Products, all rights reserved.
ef416fc2 496
497 These coded instructions, statements, and computer programs are the
bc44d920 498 property of Apple Inc. and are protected by Federal copyright
499 law. Distribution and use rights are outlined in the file "LICENSE.txt"
500 which should have been included with this file. If this file is
501 file is missing or damaged, see the license at "http://www.cups.org/".
ef416fc2 502-->
503
5a738aea 504<h2 class='title'><a name='OVERVIEW'>Overview</a></h2>
ef416fc2 505
8072030b 506<blockquote>The PPD API is deprecated starting in CUPS 1.6/macOS 10.8. Please use the new Job Ticket APIs in the <a href="api-cups.html">CUPS API</a> documentation. These functions will be removed in a future release of CUPS.</blockquote>
a2326b5b 507
5a738aea
MS
508<p>The CUPS PPD API provides read-only access the data in PostScript Printer
509Description ("PPD") files which are used for all printers with a driver. With
79e1d494
MS
510it you can obtain the data necessary to display printer options to users, mark
511option choices and check for conflicting choices, and output marked choices in
512PostScript output. The <a href="#ppd_file_t"><code>ppd_file_t</code></a>
513structure contains all of the information in a PPD file.</p>
514
515<blockquote><b>Note:</b>
516
517<p>The CUPS PPD API uses the terms "option" and "choice" instead of the Adobe
518terms "MainKeyword" and "OptionKeyword" to refer to specific printer options and
519features. CUPS also treats option ("MainKeyword") and choice ("OptionKeyword")
520values as case-insensitive strings, so option "InputSlot" and choice "Upper"
521are equivalent to "inputslot" and "upper", respectively.</p>
522</blockquote>
ef416fc2 523
5a738aea 524<h3><a name="LOADING">Loading a PPD File</a></h3>
ef416fc2 525
5a738aea
MS
526<p>The <a href="#ppdOpenFile"><code>ppdOpenFile</code></a> function "opens" a
527PPD file and loads it into memory. For example, the following code opens the
528current printer's PPD file in a CUPS filter:</p>
ef416fc2 529
5a738aea
MS
530<pre class="example">
531#include &lt;cups/ppd.h&gt;
ef416fc2 532
5a738aea 533<a href="#ppd_file_t">ppd_file_t</a> *ppd = <a href="#ppdOpenFile">ppdOpenFile</a>(getenv("PPD"));
ef416fc2 534</pre>
535
5a738aea
MS
536<p>The return value is a pointer to a new
537<a href="#ppd_file_t"><code>ppd_file_t</code></a> structure or <code>NULL</code>
538if the PPD file does not exist or cannot be loaded. The
539<a href="#ppdClose"><code>ppdClose</code></a> function frees the memory used
540by the structure:</p>
541
542<pre class="example">
543#include &lt;cups/ppd.h&gt;
544
545<a href="#ppd_file_t">ppd_file_t</a> *ppd;
546
547<a href="#ppdClose">ppdClose</a>(ppd);
548</pre>
549
79e1d494
MS
550<p>Once closed, pointers to the <a href="#ppd_file_t"><code>ppd_file_t</code></a>
551structure and any data in it will no longer be valid.</p>
552
5a738aea
MS
553<h3><a name="OPTIONS_AND_GROUPS">Options and Groups</a></h3>
554
555<p>PPD files support multiple options, which are stored in arrays of
556<a href="#ppd_option_t"><code>ppd_option_t</code></a> and
557<a href="#ppd_choice_t"><code>ppd_choice_t</code></a> structures.</p>
558
559<p>Each option in turn is associated with a group stored in a
560<a href="#ppd_group_t"><code>ppd_group_t</code></a> structure. Groups can be
561specified in the PPD file; if an option is not associated with a group
562then it is put in an automatically-generated "General" group. Groups can also
563have sub-groups, however CUPS currently ignores sub-groups because of past
564abuses of this functionality.</p>
565
79e1d494 566<p>Option choices are selected by marking them using one of three functions. The
5a738aea
MS
567first is <a href="#ppdMarkDefaults"><code>ppdMarkDefaults</code></a> which
568selects all of the default options in the PPD file:</p>
569
570<pre class="example">
571#include &lt;cups/ppd.h&gt;
572
573<a href="#ppd_file_t">ppd_file_t</a> *ppd;
574
575<a href="#ppdMarkDefaults">ppdMarkDefaults</a>(ppd);
576</pre>
577
578<p>The second is <a href="#ppdMarkOption"><code>ppdMarkOption</code></a>
579which selects a single option choice in the PPD file. For example, the following
79e1d494 580code selects the upper paper tray:</p>
5a738aea
MS
581
582<pre class="example">
583#include &lt;cups/ppd.h&gt;
584
585<a href="#ppd_file_t">ppd_file_t</a> *ppd;
586
79e1d494 587<a href="#ppdMarkOption">ppdMarkOption</a>(ppd, "InputSlot", "Upper");
5a738aea
MS
588</pre>
589
590<p>The last function is
591<a href="#cupsMarkOptions"><code>cupsMarkOptions</code></a> which selects
592multiple option choices in the PPD file from an array of CUPS options, mapping
593IPP attributes like "media" and "sides" to their corresponding PPD options. You
594typically use this function in a print filter with
595<code>cupsParseOptions</code> and
596<a href="#ppdMarkDefaults"><code>ppdMarkDefaults</code></a> to select all of
597the option choices needed for the job, for example:</p>
598
599<pre class="example">
600#include &lt;cups/ppd.h&gt;
601
602<a href="#ppd_file_t">ppd_file_t</a> *ppd = <a href="#ppdOpenFile">ppdOpenFile</a>(getenv("PPD"));
603cups_option_t *options = NULL;
604int num_options = cupsParseOptions(argv[5], 0, &amp;options);
605
606<a href="#ppdMarkDefaults">ppdMarkDefaults</a>(ppd);
607<a href="#cupsMarkOptions">cupsMarkOptions</a>(ppd, num_options, options);
79e1d494 608cupsFreeOptions(num_options, options);
5a738aea
MS
609</pre>
610
611<h3><a name="CONSTRAINTS">Constraints</a></h3>
612
613<p>PPD files support specification of conflict conditions, called
614constraints, between different options. Constraints are stored in an array of
615<a href="#ppd_const_t"><code>ppd_const_t</code></a> structures which specify
616the options and choices that conflict with each other. The
617<a href="#ppdConflicts"><code>ppdConflicts</code></a> function tells you
79e1d494
MS
618how many of the selected options are incompatible. Since constraints are
619normally specified in pairs, the returned value is typically an even number.</p>
5a738aea
MS
620
621<h3><a name="PAGE_SIZES">Page Sizes</a></h3>
622
623<p>Page sizes are special options which have physical dimensions and margins
624associated with them. The size information is stored in
625<a href="#ppd_size_t"><code>ppd_size_t</code></a> structures and is available
626by looking up the named size with the
627<a href="#ppdPageSize"><code>ppdPageSize</code></a> function. The page size and
628margins are returned in units called points; there are 72 points per inch. If
629you pass <code>NULL</code> for the size, the currently selected size is
630returned:</p>
631
632<pre class="example">
633#include &lt;cups/ppd.h&gt;
634
635<a href="#ppd_file_t">ppd_file_t</a> *ppd;
636<a href="#ppd_size_t">ppd_size_t</a> *size = <a href="#ppdPageSize">ppdPageSize</a>(ppd, NULL);
637</pre>
638
639<p>Besides the standard page sizes listed in a PPD file, some printers
640support variable or custom page sizes. Custom page sizes are supported if the
641<code>variables_sizes</code> member of the
642<a href="#ppd_file_t"><code>ppd_file_t</code></a> structure is non-zero.
643The <code>custom_min</code>, <code>custom_max</code>, and
644<code>custom_margins</code> members of the
645<a href="#ppd_file_t"><code>ppd_file_t</code></a> structure define the limits
646of the printable area. To get the resulting media size, use a page size string
647of the form "Custom.<I>width</I>x<I>length</I>", where "width" and "length" are
648in points. Custom page size names can also be specified in inches
649("Custom.<i>width</i>x<i>height</i>in"), centimeters
650("Custom.<i>width</i>x<i>height</i>cm"), or millimeters
651("Custom.<i>width</i>x<i>height</i>mm"):</p>
652
653<pre class="example">
654#include &lt;cups/ppd.h&gt;
655
656<a href="#ppd_file_t">ppd_file_t</a> *ppd;
657
658/* Get an 576x720 point custom page size */
659<a href="#ppd_size_t">ppd_size_t</a> *size = <a href="#ppdPageSize">ppdPageSize</a>(ppd, "Custom.576x720");
660
661/* Get an 8x10 inch custom page size */
662<a href="#ppd_size_t">ppd_size_t</a> *size = <a href="#ppdPageSize">ppdPageSize</a>(ppd, "Custom.8x10in");
663
664/* Get a 100x200 millimeter custom page size */
665<a href="#ppd_size_t">ppd_size_t</a> *size = <a href="#ppdPageSize">ppdPageSize</a>(ppd, "Custom.100x200mm");
666
667/* Get a 12.7x34.5 centimeter custom page size */
668<a href="#ppd_size_t">ppd_size_t</a> *size = <a href="#ppdPageSize">ppdPageSize</a>(ppd, "Custom.12.7x34.5cm");
669</pre>
670
79e1d494
MS
671<p>If the PPD does not support variable page sizes, the
672<a href="#ppdPageSize"><code>ppdPageSize</code></a> function will return
673<code>NULL</code>.</p>
674
5a738aea
MS
675<h3><a name="ATTRIBUTES">Attributes</a></h3>
676
677<p>Every PPD file is composed of one or more attributes. Most of these
678attributes are used to define groups, options, choices, and page sizes,
79e1d494
MS
679however several informational attributes may be present which you can access
680in your program or filter. Attributes normally look like one of the following
681examples in a PPD file:</p>
5a738aea
MS
682
683<pre class="example">
684*name: "value"
685*name spec: "value"
686*name spec/text: "value"
687</pre>
688
689<p>The <a href="#ppdFindAttr"><code>ppdFindAttr</code></a> and
690<a href="#ppdFindNextAttr"><code>ppdFindNextAttr</code></a> functions find the
691first and next instances, respectively, of the named attribute with the given
692"spec" string and return a <a href="#ppd_attr_t"><code>ppd_attr_t</code></a>
693structure. If you provide a NULL specifier string, all attributes with the
694given name will be returned. For example, the following code lists all of the
695<code>Product</code> attributes in a PPD file:</p>
696
697<pre class="example">
698#include &lt;cups/ppd.h&gt;
699
700<a href="#ppd_file_t">ppd_file_t</a> *ppd;
701<a href="#ppd_attr_t">ppd_attr_t</a> *attr;
702
703for (attr = <a href="#ppdFindAttr">ppdFindAttr</a>(ppd, "Product", NULL);
704 attr != NULL;
705 attr = <a href="#ppdFindNextAttr">ppdFindNextAttr</a>(ppd, "Product", NULL))
706 puts(attr->value);
707</pre>
abacc52b
MS
708 <h2 class="title"><a id="FUNCTIONS">Functions</a></h2>
709<h3 class="function"><span class="info">&#160;CUPS 1.4/macOS 10.6&#160;</span><a id="cupsGetConflicts">cupsGetConflicts</a></h3>
710 <p class="description">Get a list of conflicting options in a marked PPD.</p>
d2354e63 711<p class="code">
abacc52b
MS
712int cupsGetConflicts (<br />
713&#160;&#160;&#160;&#160;<a href="#ppd_file_t">ppd_file_t</a> *ppd,<br />
714&#160;&#160;&#160;&#160;const char *option,<br />
715&#160;&#160;&#160;&#160;const char *choice,<br />
716&#160;&#160;&#160;&#160;cups_option_t **options<br />
d2354e63
MS
717);</p>
718<h4 class="parameters">Parameters</h4>
719<dl>
720<dt>ppd</dt>
abacc52b 721 <dd class="description">PPD file</dd>
d2354e63 722<dt>option</dt>
abacc52b 723 <dd class="description">Option to test</dd>
d2354e63 724<dt>choice</dt>
abacc52b 725 <dd class="description">Choice to test</dd>
d2354e63 726<dt>options</dt>
abacc52b 727 <dd class="description">Conflicting options</dd>
d2354e63
MS
728</dl>
729<h4 class="returnvalue">Return Value</h4>
abacc52b 730 <p class="description">Number of conflicting options</p>
d2354e63 731<h4 class="discussion">Discussion</h4>
abacc52b 732 <p class="discussion">This function gets a list of options that would conflict if &quot;option&quot; and
d2354e63
MS
733&quot;choice&quot; were marked in the PPD. You would typically call this function
734after marking the currently selected options in the PPD in order to
735determine whether a new option selection would cause a conflict.<br>
736<br>
737The number of conflicting options are returned with &quot;options&quot; pointing to
738the conflicting options. The returned option array must be freed using
739<a href="#cupsFreeOptions"><code>cupsFreeOptions</code></a>.
740
6e5a57e8 741</p>
abacc52b
MS
742<h3 class="function"><a id="cupsGetPPD">cupsGetPPD</a></h3>
743 <p class="description">Get the PPD file for a printer on the default server.</p>
6e5a57e8 744<p class="code">
abacc52b
MS
745const char *cupsGetPPD (<br />
746&#160;&#160;&#160;&#160;const char *name<br />
6e5a57e8
MS
747);</p>
748<h4 class="parameters">Parameters</h4>
749<dl>
750<dt>name</dt>
abacc52b 751 <dd class="description">Destination name</dd>
6e5a57e8
MS
752</dl>
753<h4 class="returnvalue">Return Value</h4>
abacc52b 754 <p class="description">Filename for PPD file</p>
6e5a57e8 755<h4 class="discussion">Discussion</h4>
abacc52b 756 <p class="discussion">For classes, <code>cupsGetPPD</code> returns the PPD file for the first printer
6e5a57e8
MS
757in the class.<br>
758<br>
759The returned filename is stored in a static buffer and is overwritten with
760each call to <code>cupsGetPPD</code> or <a href="#cupsGetPPD2"><code>cupsGetPPD2</code></a>. The caller &quot;owns&quot; the
761file that is created and must <code>unlink</code> the returned filename.</p>
abacc52b
MS
762<h3 class="function"><span class="info">&#160;CUPS 1.1.21/macOS 10.4&#160;</span><a id="cupsGetPPD2">cupsGetPPD2</a></h3>
763 <p class="description">Get the PPD file for a printer from the specified server.</p>
6e5a57e8 764<p class="code">
abacc52b
MS
765const char *cupsGetPPD2 (<br />
766&#160;&#160;&#160;&#160;http_t *http,<br />
767&#160;&#160;&#160;&#160;const char *name<br />
6e5a57e8
MS
768);</p>
769<h4 class="parameters">Parameters</h4>
770<dl>
771<dt>http</dt>
abacc52b 772 <dd class="description">Connection to server or <code>CUPS_HTTP_DEFAULT</code></dd>
6e5a57e8 773<dt>name</dt>
abacc52b 774 <dd class="description">Destination name</dd>
6e5a57e8
MS
775</dl>
776<h4 class="returnvalue">Return Value</h4>
abacc52b 777 <p class="description">Filename for PPD file</p>
6e5a57e8 778<h4 class="discussion">Discussion</h4>
abacc52b 779 <p class="discussion">For classes, <code>cupsGetPPD2</code> returns the PPD file for the first printer
6e5a57e8
MS
780in the class.<br>
781<br>
782The returned filename is stored in a static buffer and is overwritten with
783each call to <a href="#cupsGetPPD"><code>cupsGetPPD</code></a> or <code>cupsGetPPD2</code>. The caller &quot;owns&quot; the
784file that is created and must <code>unlink</code> the returned filename.
785
786</p>
abacc52b
MS
787<h3 class="function"><span class="info">&#160;CUPS 1.4/macOS 10.6&#160;</span><a id="cupsGetPPD3">cupsGetPPD3</a></h3>
788 <p class="description">Get the PPD file for a printer on the specified
6e5a57e8
MS
789server if it has changed.</p>
790<p class="code">
abacc52b
MS
791http_status_t cupsGetPPD3 (<br />
792&#160;&#160;&#160;&#160;http_t *http,<br />
793&#160;&#160;&#160;&#160;const char *name,<br />
794&#160;&#160;&#160;&#160;time_t *modtime,<br />
795&#160;&#160;&#160;&#160;char *buffer,<br />
796&#160;&#160;&#160;&#160;size_t bufsize<br />
6e5a57e8
MS
797);</p>
798<h4 class="parameters">Parameters</h4>
799<dl>
800<dt>http</dt>
abacc52b 801 <dd class="description">HTTP connection or <code>CUPS_HTTP_DEFAULT</code></dd>
6e5a57e8 802<dt>name</dt>
abacc52b 803 <dd class="description">Destination name</dd>
6e5a57e8 804<dt>modtime</dt>
abacc52b 805 <dd class="description">Modification time</dd>
6e5a57e8 806<dt>buffer</dt>
abacc52b 807 <dd class="description">Filename buffer</dd>
6e5a57e8 808<dt>bufsize</dt>
abacc52b 809 <dd class="description">Size of filename buffer</dd>
6e5a57e8
MS
810</dl>
811<h4 class="returnvalue">Return Value</h4>
abacc52b 812 <p class="description">HTTP status</p>
6e5a57e8 813<h4 class="discussion">Discussion</h4>
abacc52b 814 <p class="discussion">The &quot;modtime&quot; parameter contains the modification time of any
6e5a57e8
MS
815locally-cached content and is updated with the time from the PPD file on
816the server.<br>
817<br>
818The &quot;buffer&quot; parameter contains the local PPD filename. If it contains
819the empty string, a new temporary file is created, otherwise the existing
820file will be overwritten as needed. The caller &quot;owns&quot; the file that is
821created and must <code>unlink</code> the returned filename.<br>
822<br>
823On success, <code>HTTP_STATUS_OK</code> is returned for a new PPD file and
824<code>HTTP_STATUS_NOT_MODIFIED</code> if the existing PPD file is up-to-date. Any other
825status is an error.<br>
826<br>
827For classes, <code>cupsGetPPD3</code> returns the PPD file for the first printer
828in the class.
829
830</p>
abacc52b
MS
831<h3 class="function"><span class="info">&#160;CUPS 1.3/macOS 10.5&#160;</span><a id="cupsGetServerPPD">cupsGetServerPPD</a></h3>
832 <p class="description">Get an available PPD file from the server.</p>
6e5a57e8 833<p class="code">
abacc52b
MS
834char *cupsGetServerPPD (<br />
835&#160;&#160;&#160;&#160;http_t *http,<br />
836&#160;&#160;&#160;&#160;const char *name<br />
6e5a57e8
MS
837);</p>
838<h4 class="parameters">Parameters</h4>
839<dl>
840<dt>http</dt>
abacc52b 841 <dd class="description">Connection to server or <code>CUPS_HTTP_DEFAULT</code></dd>
6e5a57e8 842<dt>name</dt>
abacc52b 843 <dd class="description">Name of PPD file (&quot;ppd-name&quot;)</dd>
6e5a57e8
MS
844</dl>
845<h4 class="returnvalue">Return Value</h4>
abacc52b 846 <p class="description">Name of PPD file or <code>NULL</code> on error</p>
6e5a57e8 847<h4 class="discussion">Discussion</h4>
abacc52b 848 <p class="discussion">This function returns the named PPD file from the server. The
6e5a57e8
MS
849list of available PPDs is provided by the IPP <code>CUPS_GET_PPDS</code>
850operation.<br>
851<br>
852You must remove (unlink) the PPD file when you are finished with
853it. The PPD filename is stored in a static location that will be
854overwritten on the next call to <a href="#cupsGetPPD"><code>cupsGetPPD</code></a>, <a href="#cupsGetPPD2"><code>cupsGetPPD2</code></a>,
855or <a href="#cupsGetServerPPD"><code>cupsGetServerPPD</code></a>.
856
d2354e63 857</p>
abacc52b
MS
858<h3 class="function"><a id="cupsMarkOptions">cupsMarkOptions</a></h3>
859 <p class="description">Mark command-line options in a PPD file.</p>
5a738aea 860<p class="code">
abacc52b
MS
861int cupsMarkOptions (<br />
862&#160;&#160;&#160;&#160;<a href="#ppd_file_t">ppd_file_t</a> *ppd,<br />
863&#160;&#160;&#160;&#160;int num_options,<br />
864&#160;&#160;&#160;&#160;cups_option_t *options<br />
5a738aea
MS
865);</p>
866<h4 class="parameters">Parameters</h4>
867<dl>
868<dt>ppd</dt>
abacc52b 869 <dd class="description">PPD file</dd>
5a738aea 870<dt>num_options</dt>
abacc52b 871 <dd class="description">Number of options</dd>
5a738aea 872<dt>options</dt>
abacc52b 873 <dd class="description">Options</dd>
5a738aea
MS
874</dl>
875<h4 class="returnvalue">Return Value</h4>
abacc52b 876 <p class="description">1 if conflicts exist, 0 otherwise</p>
5a738aea 877<h4 class="discussion">Discussion</h4>
abacc52b 878 <p class="discussion">This function maps the IPP &quot;finishings&quot;, &quot;media&quot;, &quot;mirror&quot;,
82f97232
MS
879&quot;multiple-document-handling&quot;, &quot;output-bin&quot;, &quot;print-color-mode&quot;,
880&quot;print-quality&quot;, &quot;printer-resolution&quot;, and &quot;sides&quot; attributes to their
881corresponding PPD options and choices.</p>
abacc52b
MS
882<h3 class="function"><span class="info">&#160;CUPS 1.4/macOS 10.6&#160;</span><a id="cupsResolveConflicts">cupsResolveConflicts</a></h3>
883 <p class="description">Resolve conflicts in a marked PPD.</p>
66ab9486 884<p class="code">
abacc52b
MS
885int cupsResolveConflicts (<br />
886&#160;&#160;&#160;&#160;<a href="#ppd_file_t">ppd_file_t</a> *ppd,<br />
887&#160;&#160;&#160;&#160;const char *option,<br />
888&#160;&#160;&#160;&#160;const char *choice,<br />
889&#160;&#160;&#160;&#160;int *num_options,<br />
890&#160;&#160;&#160;&#160;cups_option_t **options<br />
66ab9486
MS
891);</p>
892<h4 class="parameters">Parameters</h4>
893<dl>
894<dt>ppd</dt>
abacc52b 895 <dd class="description">PPD file</dd>
66ab9486 896<dt>option</dt>
abacc52b 897 <dd class="description">Newly selected option or <code>NULL</code> for none</dd>
66ab9486 898<dt>choice</dt>
abacc52b 899 <dd class="description">Newly selected choice or <code>NULL</code> for none</dd>
66ab9486 900<dt>num_options</dt>
abacc52b 901 <dd class="description">Number of additional selected options</dd>
66ab9486 902<dt>options</dt>
abacc52b 903 <dd class="description">Additional selected options</dd>
66ab9486
MS
904</dl>
905<h4 class="returnvalue">Return Value</h4>
abacc52b 906 <p class="description">1 on success, 0 on failure</p>
66ab9486 907<h4 class="discussion">Discussion</h4>
abacc52b 908 <p class="discussion">This function attempts to resolve any conflicts in a marked PPD, returning
06d4e77b
MS
909a list of option changes that are required to resolve them. On input,
910&quot;num_options&quot; and &quot;options&quot; contain any pending option changes that have
911not yet been marked, while &quot;option&quot; and &quot;choice&quot; contain the most recent
66ab9486
MS
912selection which may or may not be in &quot;num_options&quot; or &quot;options&quot;.<br>
913<br>
914On successful return, &quot;num_options&quot; and &quot;options&quot; are updated to contain
915&quot;option&quot; and &quot;choice&quot; along with any changes required to resolve conflicts
06d4e77b
MS
916specified in the PPD file and 1 is returned.<br>
917<br>
918If option conflicts cannot be resolved, &quot;num_options&quot; and &quot;options&quot; are not
919changed and 0 is returned.<br>
920<br>
921When resolving conflicts, <code>cupsResolveConflicts</code> does not consider
922changes to the current page size (<code>media</code>, <code>PageSize</code>, and
923<code>PageRegion</code>) or to the most recent option specified in &quot;option&quot;.
924Thus, if the only way to resolve a conflict is to change the page size
925or the option the user most recently changed, <code>cupsResolveConflicts</code>
926will return 0 to indicate it was unable to resolve the conflicts.<br>
927<br>
928The <code>cupsResolveConflicts</code> function uses one of two sources of option
929constraint information. The preferred constraint information is defined by
66ab9486 930<code>cupsUIConstraints</code> and <code>cupsUIResolver</code> attributes - in this
06d4e77b 931case, the PPD file provides constraint resolution actions.<br>
66ab9486 932<br>
06d4e77b 933The backup constraint information is defined by the
66ab9486 934<code>UIConstraints</code> and <code>NonUIConstraints</code> attributes. These
06d4e77b
MS
935constraints are resolved algorithmically by first selecting the default
936choice for the conflicting option, then iterating over all possible choices
937until a non-conflicting option choice is found.
66ab9486
MS
938
939</p>
abacc52b
MS
940<h3 class="function"><a id="ppdCollect">ppdCollect</a></h3>
941 <p class="description">Collect all marked options that reside in the specified
5a738aea
MS
942section.</p>
943<p class="code">
abacc52b
MS
944int ppdCollect (<br />
945&#160;&#160;&#160;&#160;<a href="#ppd_file_t">ppd_file_t</a> *ppd,<br />
946&#160;&#160;&#160;&#160;<a href="#ppd_section_t">ppd_section_t</a> section,<br />
947&#160;&#160;&#160;&#160;<a href="#ppd_choice_t">ppd_choice_t</a> ***choices<br />
5a738aea
MS
948);</p>
949<h4 class="parameters">Parameters</h4>
950<dl>
951<dt>ppd</dt>
abacc52b 952 <dd class="description">PPD file data</dd>
5a738aea 953<dt>section</dt>
abacc52b 954 <dd class="description">Section to collect</dd>
5a738aea 955<dt>choices</dt>
abacc52b 956 <dd class="description">Pointers to choices</dd>
5a738aea
MS
957</dl>
958<h4 class="returnvalue">Return Value</h4>
abacc52b 959 <p class="description">Number of options marked</p>
5a738aea 960<h4 class="discussion">Discussion</h4>
abacc52b 961 <p class="discussion">The choices array should be freed using <code>free</code> when you are
5a738aea 962finished with it.</p>
abacc52b
MS
963<h3 class="function"><span class="info">&#160;CUPS 1.2/macOS 10.5&#160;</span><a id="ppdCollect2">ppdCollect2</a></h3>
964 <p class="description">Collect all marked options that reside in the
5a738aea
MS
965specified section and minimum order.</p>
966<p class="code">
abacc52b
MS
967int ppdCollect2 (<br />
968&#160;&#160;&#160;&#160;<a href="#ppd_file_t">ppd_file_t</a> *ppd,<br />
969&#160;&#160;&#160;&#160;<a href="#ppd_section_t">ppd_section_t</a> section,<br />
970&#160;&#160;&#160;&#160;float min_order,<br />
971&#160;&#160;&#160;&#160;<a href="#ppd_choice_t">ppd_choice_t</a> ***choices<br />
5a738aea
MS
972);</p>
973<h4 class="parameters">Parameters</h4>
974<dl>
975<dt>ppd</dt>
abacc52b 976 <dd class="description">PPD file data</dd>
5a738aea 977<dt>section</dt>
abacc52b 978 <dd class="description">Section to collect</dd>
5a738aea 979<dt>min_order</dt>
abacc52b 980 <dd class="description">Minimum OrderDependency value</dd>
5a738aea 981<dt>choices</dt>
abacc52b 982 <dd class="description">Pointers to choices</dd>
5a738aea
MS
983</dl>
984<h4 class="returnvalue">Return Value</h4>
abacc52b 985 <p class="description">Number of options marked</p>
5a738aea 986<h4 class="discussion">Discussion</h4>
abacc52b 987 <p class="discussion">The choices array should be freed using <code>free</code> when you are
5a738aea
MS
988finished with it.
989
990</p>
abacc52b
MS
991<h3 class="function"><a id="ppdConflicts">ppdConflicts</a></h3>
992 <p class="description">Check to see if there are any conflicts among the
5a738aea
MS
993marked option choices.</p>
994<p class="code">
abacc52b
MS
995int ppdConflicts (<br />
996&#160;&#160;&#160;&#160;<a href="#ppd_file_t">ppd_file_t</a> *ppd<br />
5a738aea
MS
997);</p>
998<h4 class="parameters">Parameters</h4>
999<dl>
1000<dt>ppd</dt>
abacc52b 1001 <dd class="description">PPD to check</dd>
5a738aea
MS
1002</dl>
1003<h4 class="returnvalue">Return Value</h4>
abacc52b 1004 <p class="description">Number of conflicts found</p>
5a738aea 1005<h4 class="discussion">Discussion</h4>
abacc52b
MS
1006 <p class="discussion">The returned value is the same as returned by <a href="#ppdMarkOption"><code>ppdMarkOption</code></a>.</p>
1007<h3 class="function"><a id="ppdEmit">ppdEmit</a></h3>
1008 <p class="description">Emit code for marked options to a file.</p>
5a738aea 1009<p class="code">
abacc52b
MS
1010int ppdEmit (<br />
1011&#160;&#160;&#160;&#160;<a href="#ppd_file_t">ppd_file_t</a> *ppd,<br />
1012&#160;&#160;&#160;&#160;FILE *fp,<br />
1013&#160;&#160;&#160;&#160;<a href="#ppd_section_t">ppd_section_t</a> section<br />
5a738aea
MS
1014);</p>
1015<h4 class="parameters">Parameters</h4>
1016<dl>
1017<dt>ppd</dt>
abacc52b 1018 <dd class="description">PPD file record</dd>
5a738aea 1019<dt>fp</dt>
abacc52b 1020 <dd class="description">File to write to</dd>
5a738aea 1021<dt>section</dt>
abacc52b 1022 <dd class="description">Section to write</dd>
5a738aea
MS
1023</dl>
1024<h4 class="returnvalue">Return Value</h4>
abacc52b
MS
1025 <p class="description">0 on success, -1 on failure</p>
1026<h3 class="function"><span class="info">&#160;CUPS 1.2/macOS 10.5&#160;</span><a id="ppdEmitAfterOrder">ppdEmitAfterOrder</a></h3>
1027 <p class="description">Emit a subset of the code for marked options to a file.</p>
5a738aea 1028<p class="code">
abacc52b
MS
1029int ppdEmitAfterOrder (<br />
1030&#160;&#160;&#160;&#160;<a href="#ppd_file_t">ppd_file_t</a> *ppd,<br />
1031&#160;&#160;&#160;&#160;FILE *fp,<br />
1032&#160;&#160;&#160;&#160;<a href="#ppd_section_t">ppd_section_t</a> section,<br />
1033&#160;&#160;&#160;&#160;int limit,<br />
1034&#160;&#160;&#160;&#160;float min_order<br />
5a738aea
MS
1035);</p>
1036<h4 class="parameters">Parameters</h4>
1037<dl>
1038<dt>ppd</dt>
abacc52b 1039 <dd class="description">PPD file record</dd>
5a738aea 1040<dt>fp</dt>
abacc52b 1041 <dd class="description">File to write to</dd>
5a738aea 1042<dt>section</dt>
abacc52b 1043 <dd class="description">Section to write</dd>
5a738aea 1044<dt>limit</dt>
abacc52b 1045 <dd class="description">Non-zero to use min_order</dd>
5a738aea 1046<dt>min_order</dt>
abacc52b 1047 <dd class="description">Lowest OrderDependency</dd>
5a738aea
MS
1048</dl>
1049<h4 class="returnvalue">Return Value</h4>
abacc52b 1050 <p class="description">0 on success, -1 on failure</p>
5a738aea 1051<h4 class="discussion">Discussion</h4>
abacc52b 1052 <p class="discussion">When &quot;limit&quot; is non-zero, this function only emits options whose
5a738aea
MS
1053OrderDependency value is greater than or equal to &quot;min_order&quot;.<br>
1054<br>
1055When &quot;limit&quot; is zero, this function is identical to ppdEmit().
1056
1057</p>
abacc52b
MS
1058<h3 class="function"><a id="ppdEmitFd">ppdEmitFd</a></h3>
1059 <p class="description">Emit code for marked options to a file.</p>
5a738aea 1060<p class="code">
abacc52b
MS
1061int ppdEmitFd (<br />
1062&#160;&#160;&#160;&#160;<a href="#ppd_file_t">ppd_file_t</a> *ppd,<br />
1063&#160;&#160;&#160;&#160;int fd,<br />
1064&#160;&#160;&#160;&#160;<a href="#ppd_section_t">ppd_section_t</a> section<br />
5a738aea
MS
1065);</p>
1066<h4 class="parameters">Parameters</h4>
1067<dl>
1068<dt>ppd</dt>
abacc52b 1069 <dd class="description">PPD file record</dd>
5a738aea 1070<dt>fd</dt>
abacc52b 1071 <dd class="description">File to write to</dd>
5a738aea 1072<dt>section</dt>
abacc52b 1073 <dd class="description">Section to write</dd>
5a738aea
MS
1074</dl>
1075<h4 class="returnvalue">Return Value</h4>
abacc52b
MS
1076 <p class="description">0 on success, -1 on failure</p>
1077<h3 class="function"><a id="ppdEmitJCL">ppdEmitJCL</a></h3>
1078 <p class="description">Emit code for JCL options to a file.</p>
5a738aea 1079<p class="code">
abacc52b
MS
1080int ppdEmitJCL (<br />
1081&#160;&#160;&#160;&#160;<a href="#ppd_file_t">ppd_file_t</a> *ppd,<br />
1082&#160;&#160;&#160;&#160;FILE *fp,<br />
1083&#160;&#160;&#160;&#160;int job_id,<br />
1084&#160;&#160;&#160;&#160;const char *user,<br />
1085&#160;&#160;&#160;&#160;const char *title<br />
5a738aea
MS
1086);</p>
1087<h4 class="parameters">Parameters</h4>
1088<dl>
1089<dt>ppd</dt>
abacc52b 1090 <dd class="description">PPD file record</dd>
5a738aea 1091<dt>fp</dt>
abacc52b 1092 <dd class="description">File to write to</dd>
5a738aea 1093<dt>job_id</dt>
abacc52b 1094 <dd class="description">Job ID</dd>
5a738aea 1095<dt>user</dt>
abacc52b 1096 <dd class="description">Username</dd>
5a738aea 1097<dt>title</dt>
abacc52b 1098 <dd class="description">Title</dd>
5a738aea
MS
1099</dl>
1100<h4 class="returnvalue">Return Value</h4>
abacc52b
MS
1101 <p class="description">0 on success, -1 on failure</p>
1102<h3 class="function"><span class="info">&#160;CUPS 1.2/macOS 10.5&#160;</span><a id="ppdEmitJCLEnd">ppdEmitJCLEnd</a></h3>
1103 <p class="description">Emit JCLEnd code to a file.</p>
5a738aea 1104<p class="code">
abacc52b
MS
1105int ppdEmitJCLEnd (<br />
1106&#160;&#160;&#160;&#160;<a href="#ppd_file_t">ppd_file_t</a> *ppd,<br />
1107&#160;&#160;&#160;&#160;FILE *fp<br />
5a738aea
MS
1108);</p>
1109<h4 class="parameters">Parameters</h4>
1110<dl>
1111<dt>ppd</dt>
abacc52b 1112 <dd class="description">PPD file record</dd>
5a738aea 1113<dt>fp</dt>
abacc52b 1114 <dd class="description">File to write to</dd>
5a738aea
MS
1115</dl>
1116<h4 class="returnvalue">Return Value</h4>
abacc52b
MS
1117 <p class="description">0 on success, -1 on failure</p>
1118<h3 class="function"><span class="info">&#160;CUPS 1.2/macOS 10.5&#160;</span><a id="ppdEmitString">ppdEmitString</a></h3>
1119 <p class="description">Get a string containing the code for marked options.</p>
5a738aea 1120<p class="code">
abacc52b
MS
1121char *ppdEmitString (<br />
1122&#160;&#160;&#160;&#160;<a href="#ppd_file_t">ppd_file_t</a> *ppd,<br />
1123&#160;&#160;&#160;&#160;<a href="#ppd_section_t">ppd_section_t</a> section,<br />
1124&#160;&#160;&#160;&#160;float min_order<br />
5a738aea
MS
1125);</p>
1126<h4 class="parameters">Parameters</h4>
1127<dl>
1128<dt>ppd</dt>
abacc52b 1129 <dd class="description">PPD file record</dd>
5a738aea 1130<dt>section</dt>
abacc52b 1131 <dd class="description">Section to write</dd>
5a738aea 1132<dt>min_order</dt>
abacc52b 1133 <dd class="description">Lowest OrderDependency</dd>
5a738aea
MS
1134</dl>
1135<h4 class="returnvalue">Return Value</h4>
abacc52b 1136 <p class="description">String containing option code or <code>NULL</code> if there is no option code</p>
5a738aea 1137<h4 class="discussion">Discussion</h4>
abacc52b 1138 <p class="discussion">When &quot;min_order&quot; is greater than zero, this function only includes options
80ca4592 1139whose OrderDependency value is greater than or equal to &quot;min_order&quot;.
1140Otherwise, all options in the specified section are included in the
5a738aea
MS
1141returned string.<br>
1142<br>
1143The return string is allocated on the heap and should be freed using
1144<code>free</code> when you are done with it.
1145
1146</p>
abacc52b
MS
1147<h3 class="function"><span class="info">&#160;CUPS 1.1.19/macOS 10.3&#160;</span><a id="ppdFindAttr">ppdFindAttr</a></h3>
1148 <p class="description">Find the first matching attribute.</p>
5a738aea 1149<p class="code">
abacc52b
MS
1150<a href="#ppd_attr_t">ppd_attr_t</a> *ppdFindAttr (<br />
1151&#160;&#160;&#160;&#160;<a href="#ppd_file_t">ppd_file_t</a> *ppd,<br />
1152&#160;&#160;&#160;&#160;const char *name,<br />
1153&#160;&#160;&#160;&#160;const char *spec<br />
5a738aea
MS
1154);</p>
1155<h4 class="parameters">Parameters</h4>
1156<dl>
1157<dt>ppd</dt>
abacc52b 1158 <dd class="description">PPD file data</dd>
5a738aea 1159<dt>name</dt>
abacc52b 1160 <dd class="description">Attribute name</dd>
5a738aea 1161<dt>spec</dt>
abacc52b 1162 <dd class="description">Specifier string or <code>NULL</code></dd>
5a738aea
MS
1163</dl>
1164<h4 class="returnvalue">Return Value</h4>
abacc52b
MS
1165 <p class="description">Attribute or <code>NULL</code> if not found</p>
1166<h3 class="function"><a id="ppdFindChoice">ppdFindChoice</a></h3>
1167 <p class="description">Return a pointer to an option choice.</p>
5a738aea 1168<p class="code">
abacc52b
MS
1169<a href="#ppd_choice_t">ppd_choice_t</a> *ppdFindChoice (<br />
1170&#160;&#160;&#160;&#160;<a href="#ppd_option_t">ppd_option_t</a> *o,<br />
1171&#160;&#160;&#160;&#160;const char *choice<br />
5a738aea
MS
1172);</p>
1173<h4 class="parameters">Parameters</h4>
1174<dl>
1175<dt>o</dt>
abacc52b 1176 <dd class="description">Pointer to option</dd>
5a738aea 1177<dt>choice</dt>
abacc52b 1178 <dd class="description">Name of choice</dd>
5a738aea
MS
1179</dl>
1180<h4 class="returnvalue">Return Value</h4>
abacc52b
MS
1181 <p class="description">Choice pointer or <code>NULL</code></p>
1182<h3 class="function"><span class="info">&#160;CUPS 1.2/macOS 10.5&#160;</span><a id="ppdFindCustomOption">ppdFindCustomOption</a></h3>
1183 <p class="description">Find a custom option.</p>
5a738aea 1184<p class="code">
abacc52b
MS
1185<a href="#ppd_coption_t">ppd_coption_t</a> *ppdFindCustomOption (<br />
1186&#160;&#160;&#160;&#160;<a href="#ppd_file_t">ppd_file_t</a> *ppd,<br />
1187&#160;&#160;&#160;&#160;const char *keyword<br />
5a738aea
MS
1188);</p>
1189<h4 class="parameters">Parameters</h4>
1190<dl>
1191<dt>ppd</dt>
abacc52b 1192 <dd class="description">PPD file</dd>
5a738aea 1193<dt>keyword</dt>
abacc52b 1194 <dd class="description">Custom option name</dd>
5a738aea
MS
1195</dl>
1196<h4 class="returnvalue">Return Value</h4>
abacc52b
MS
1197 <p class="description">Custom option or NULL</p>
1198<h3 class="function"><span class="info">&#160;CUPS 1.2/macOS 10.5&#160;</span><a id="ppdFindCustomParam">ppdFindCustomParam</a></h3>
1199 <p class="description">Find a parameter for a custom option.</p>
5a738aea 1200<p class="code">
abacc52b
MS
1201<a href="#ppd_cparam_t">ppd_cparam_t</a> *ppdFindCustomParam (<br />
1202&#160;&#160;&#160;&#160;<a href="#ppd_coption_t">ppd_coption_t</a> *opt,<br />
1203&#160;&#160;&#160;&#160;const char *name<br />
5a738aea
MS
1204);</p>
1205<h4 class="parameters">Parameters</h4>
1206<dl>
1207<dt>opt</dt>
abacc52b 1208 <dd class="description">Custom option</dd>
5a738aea 1209<dt>name</dt>
abacc52b 1210 <dd class="description">Parameter name</dd>
5a738aea
MS
1211</dl>
1212<h4 class="returnvalue">Return Value</h4>
abacc52b
MS
1213 <p class="description">Custom parameter or NULL</p>
1214<h3 class="function"><a id="ppdFindMarkedChoice">ppdFindMarkedChoice</a></h3>
1215 <p class="description">Return the marked choice for the specified option.</p>
5a738aea 1216<p class="code">
abacc52b
MS
1217<a href="#ppd_choice_t">ppd_choice_t</a> *ppdFindMarkedChoice (<br />
1218&#160;&#160;&#160;&#160;<a href="#ppd_file_t">ppd_file_t</a> *ppd,<br />
1219&#160;&#160;&#160;&#160;const char *option<br />
5a738aea
MS
1220);</p>
1221<h4 class="parameters">Parameters</h4>
1222<dl>
1223<dt>ppd</dt>
abacc52b 1224 <dd class="description">PPD file</dd>
5a738aea 1225<dt>option</dt>
abacc52b 1226 <dd class="description">Keyword/option name</dd>
5a738aea
MS
1227</dl>
1228<h4 class="returnvalue">Return Value</h4>
abacc52b
MS
1229 <p class="description">Pointer to choice or <code>NULL</code></p>
1230<h3 class="function"><span class="info">&#160;CUPS 1.1.19/macOS 10.3&#160;</span><a id="ppdFindNextAttr">ppdFindNextAttr</a></h3>
1231 <p class="description">Find the next matching attribute.</p>
5a738aea 1232<p class="code">
abacc52b
MS
1233<a href="#ppd_attr_t">ppd_attr_t</a> *ppdFindNextAttr (<br />
1234&#160;&#160;&#160;&#160;<a href="#ppd_file_t">ppd_file_t</a> *ppd,<br />
1235&#160;&#160;&#160;&#160;const char *name,<br />
1236&#160;&#160;&#160;&#160;const char *spec<br />
5a738aea
MS
1237);</p>
1238<h4 class="parameters">Parameters</h4>
1239<dl>
1240<dt>ppd</dt>
abacc52b 1241 <dd class="description">PPD file data</dd>
5a738aea 1242<dt>name</dt>
abacc52b 1243 <dd class="description">Attribute name</dd>
5a738aea 1244<dt>spec</dt>
abacc52b 1245 <dd class="description">Specifier string or <code>NULL</code></dd>
5a738aea
MS
1246</dl>
1247<h4 class="returnvalue">Return Value</h4>
abacc52b
MS
1248 <p class="description">Attribute or <code>NULL</code> if not found</p>
1249<h3 class="function"><a id="ppdFindOption">ppdFindOption</a></h3>
1250 <p class="description">Return a pointer to the specified option.</p>
5a738aea 1251<p class="code">
abacc52b
MS
1252<a href="#ppd_option_t">ppd_option_t</a> *ppdFindOption (<br />
1253&#160;&#160;&#160;&#160;<a href="#ppd_file_t">ppd_file_t</a> *ppd,<br />
1254&#160;&#160;&#160;&#160;const char *option<br />
5a738aea
MS
1255);</p>
1256<h4 class="parameters">Parameters</h4>
1257<dl>
1258<dt>ppd</dt>
abacc52b 1259 <dd class="description">PPD file data</dd>
5a738aea 1260<dt>option</dt>
abacc52b 1261 <dd class="description">Option/Keyword name</dd>
5a738aea
MS
1262</dl>
1263<h4 class="returnvalue">Return Value</h4>
abacc52b
MS
1264 <p class="description">Pointer to option or <code>NULL</code></p>
1265<h3 class="function"><span class="info">&#160;CUPS 1.2/macOS 10.5&#160;</span><a id="ppdFirstCustomParam">ppdFirstCustomParam</a></h3>
1266 <p class="description">Return the first parameter for a custom option.</p>
5a738aea 1267<p class="code">
abacc52b
MS
1268<a href="#ppd_cparam_t">ppd_cparam_t</a> *ppdFirstCustomParam (<br />
1269&#160;&#160;&#160;&#160;<a href="#ppd_coption_t">ppd_coption_t</a> *opt<br />
5a738aea
MS
1270);</p>
1271<h4 class="parameters">Parameters</h4>
1272<dl>
1273<dt>opt</dt>
abacc52b 1274 <dd class="description">Custom option</dd>
5a738aea
MS
1275</dl>
1276<h4 class="returnvalue">Return Value</h4>
abacc52b
MS
1277 <p class="description">Custom parameter or NULL</p>
1278<h3 class="function"><span class="info">&#160;CUPS 1.2/macOS 10.5&#160;</span><a id="ppdFirstOption">ppdFirstOption</a></h3>
1279 <p class="description">Return the first option in the PPD file.</p>
5a738aea 1280<p class="code">
abacc52b
MS
1281<a href="#ppd_option_t">ppd_option_t</a> *ppdFirstOption (<br />
1282&#160;&#160;&#160;&#160;<a href="#ppd_file_t">ppd_file_t</a> *ppd<br />
5a738aea
MS
1283);</p>
1284<h4 class="parameters">Parameters</h4>
1285<dl>
1286<dt>ppd</dt>
abacc52b 1287 <dd class="description">PPD file</dd>
5a738aea
MS
1288</dl>
1289<h4 class="returnvalue">Return Value</h4>
abacc52b 1290 <p class="description">First option or <code>NULL</code></p>
5a738aea 1291<h4 class="discussion">Discussion</h4>
abacc52b 1292 <p class="discussion">Options are returned from all groups in ascending alphanumeric order.
5a738aea 1293
66ab9486 1294</p>
abacc52b
MS
1295<h3 class="function"><span class="info">&#160;CUPS 1.4/macOS 10.6&#160;</span><a id="ppdInstallableConflict">ppdInstallableConflict</a></h3>
1296 <p class="description">Test whether an option choice conflicts with
66ab9486
MS
1297an installable option.</p>
1298<p class="code">
abacc52b
MS
1299int ppdInstallableConflict (<br />
1300&#160;&#160;&#160;&#160;<a href="#ppd_file_t">ppd_file_t</a> *ppd,<br />
1301&#160;&#160;&#160;&#160;const char *option,<br />
1302&#160;&#160;&#160;&#160;const char *choice<br />
66ab9486
MS
1303);</p>
1304<h4 class="parameters">Parameters</h4>
1305<dl>
1306<dt>ppd</dt>
abacc52b 1307 <dd class="description">PPD file</dd>
66ab9486 1308<dt>option</dt>
abacc52b 1309 <dd class="description">Option</dd>
66ab9486 1310<dt>choice</dt>
abacc52b 1311 <dd class="description">Choice</dd>
66ab9486
MS
1312</dl>
1313<h4 class="returnvalue">Return Value</h4>
abacc52b 1314 <p class="description">1 if conflicting, 0 if not conflicting</p>
66ab9486 1315<h4 class="discussion">Discussion</h4>
abacc52b 1316 <p class="discussion">This function tests whether a particular option choice is available based
66ab9486
MS
1317on constraints against options in the &quot;InstallableOptions&quot; group.
1318
5a738aea 1319</p>
abacc52b
MS
1320<h3 class="function"><a id="ppdIsMarked">ppdIsMarked</a></h3>
1321 <p class="description">Check to see if an option is marked.</p>
5a738aea 1322<p class="code">
abacc52b
MS
1323int ppdIsMarked (<br />
1324&#160;&#160;&#160;&#160;<a href="#ppd_file_t">ppd_file_t</a> *ppd,<br />
1325&#160;&#160;&#160;&#160;const char *option,<br />
1326&#160;&#160;&#160;&#160;const char *choice<br />
5a738aea
MS
1327);</p>
1328<h4 class="parameters">Parameters</h4>
1329<dl>
1330<dt>ppd</dt>
abacc52b 1331 <dd class="description">PPD file data</dd>
5a738aea 1332<dt>option</dt>
abacc52b 1333 <dd class="description">Option/Keyword name</dd>
5a738aea 1334<dt>choice</dt>
abacc52b 1335 <dd class="description">Choice name</dd>
5a738aea
MS
1336</dl>
1337<h4 class="returnvalue">Return Value</h4>
abacc52b
MS
1338 <p class="description">Non-zero if option is marked</p>
1339<h3 class="function"><span class="info">&#160;CUPS 1.2/macOS 10.5&#160;</span><a id="ppdLocalize">ppdLocalize</a></h3>
1340 <p class="description">Localize the PPD file to the current locale.</p>
5a738aea 1341<p class="code">
abacc52b
MS
1342int ppdLocalize (<br />
1343&#160;&#160;&#160;&#160;<a href="#ppd_file_t">ppd_file_t</a> *ppd<br />
5a738aea
MS
1344);</p>
1345<h4 class="parameters">Parameters</h4>
1346<dl>
1347<dt>ppd</dt>
abacc52b 1348 <dd class="description">PPD file</dd>
5a738aea
MS
1349</dl>
1350<h4 class="returnvalue">Return Value</h4>
abacc52b 1351 <p class="description">0 on success, -1 on error</p>
5a738aea 1352<h4 class="discussion">Discussion</h4>
abacc52b 1353 <p class="discussion">All groups, options, and choices are localized, as are ICC profile
bc44d920 1354descriptions, printer presets, and custom option parameters. Each
1355localized string uses the UTF-8 character encoding.
1356
5a738aea 1357</p>
abacc52b
MS
1358<h3 class="function"><a id="ppdLocalizeAttr">ppdLocalizeAttr</a></h3>
1359 <p class="description">Localize an attribute.</p>
75bd9771 1360<p class="code">
abacc52b
MS
1361<a href="#ppd_attr_t">ppd_attr_t</a> *ppdLocalizeAttr (<br />
1362&#160;&#160;&#160;&#160;<a href="#ppd_file_t">ppd_file_t</a> *ppd,<br />
1363&#160;&#160;&#160;&#160;const char *keyword,<br />
1364&#160;&#160;&#160;&#160;const char *spec<br />
75bd9771
MS
1365);</p>
1366<h4 class="parameters">Parameters</h4>
1367<dl>
1368<dt>ppd</dt>
abacc52b 1369 <dd class="description">PPD file</dd>
75bd9771 1370<dt>keyword</dt>
abacc52b 1371 <dd class="description">Main keyword</dd>
75bd9771 1372<dt>spec</dt>
abacc52b 1373 <dd class="description">Option keyword or <code>NULL</code> for none</dd>
75bd9771
MS
1374</dl>
1375<h4 class="returnvalue">Return Value</h4>
abacc52b 1376 <p class="description">Localized attribute or <code>NULL</code> if none exists</p>
75bd9771 1377<h4 class="discussion">Discussion</h4>
abacc52b 1378 <p class="discussion">This function uses the current locale to find the localized attribute for
75bd9771
MS
1379the given main and option keywords. If no localized version of the
1380attribute exists for the current locale, the unlocalized version is returned.</p>
abacc52b
MS
1381<h3 class="function"><span class="info">&#160;CUPS 1.3/macOS 10.5&#160;</span><a id="ppdLocalizeIPPReason">ppdLocalizeIPPReason</a></h3>
1382 <p class="description">Get the localized version of a cupsIPPReason
5a738aea
MS
1383attribute.</p>
1384<p class="code">
abacc52b
MS
1385const char *ppdLocalizeIPPReason (<br />
1386&#160;&#160;&#160;&#160;<a href="#ppd_file_t">ppd_file_t</a> *ppd,<br />
1387&#160;&#160;&#160;&#160;const char *reason,<br />
1388&#160;&#160;&#160;&#160;const char *scheme,<br />
1389&#160;&#160;&#160;&#160;char *buffer,<br />
1390&#160;&#160;&#160;&#160;size_t bufsize<br />
5a738aea
MS
1391);</p>
1392<h4 class="parameters">Parameters</h4>
1393<dl>
1394<dt>ppd</dt>
abacc52b 1395 <dd class="description">PPD file</dd>
5a738aea 1396<dt>reason</dt>
abacc52b 1397 <dd class="description">IPP reason keyword to look up</dd>
5a738aea 1398<dt>scheme</dt>
abacc52b 1399 <dd class="description">URI scheme or NULL for text</dd>
5a738aea 1400<dt>buffer</dt>
abacc52b 1401 <dd class="description">Value buffer</dd>
5a738aea 1402<dt>bufsize</dt>
abacc52b 1403 <dd class="description">Size of value buffer</dd>
5a738aea
MS
1404</dl>
1405<h4 class="returnvalue">Return Value</h4>
abacc52b 1406 <p class="description">Value or NULL if not found</p>
5a738aea 1407<h4 class="discussion">Discussion</h4>
abacc52b 1408 <p class="discussion">This function uses the current locale to find the corresponding reason
bc44d920 1409text or URI from the attribute value. If &quot;scheme&quot; is NULL or &quot;text&quot;,
1410the returned value contains human-readable (UTF-8) text from the translation
5a738aea
MS
1411string or attribute value. Otherwise the corresponding URI is returned.<br>
1412<br>
1413If no value of the requested scheme can be found, NULL is returned.
1414
1415</p>
abacc52b
MS
1416<h3 class="function"><span class="info">&#160;CUPS 1.4/macOS 10.6&#160;</span><a id="ppdLocalizeMarkerName">ppdLocalizeMarkerName</a></h3>
1417 <p class="description">Get the localized version of a marker-names
5a738aea
MS
1418attribute value.</p>
1419<p class="code">
abacc52b
MS
1420const char *ppdLocalizeMarkerName (<br />
1421&#160;&#160;&#160;&#160;<a href="#ppd_file_t">ppd_file_t</a> *ppd,<br />
1422&#160;&#160;&#160;&#160;const char *name<br />
5a738aea
MS
1423);</p>
1424<h4 class="parameters">Parameters</h4>
1425<dl>
1426<dt>ppd</dt>
abacc52b 1427 <dd class="description">PPD file</dd>
5a738aea 1428<dt>name</dt>
abacc52b 1429 <dd class="description">Marker name to look up</dd>
5a738aea
MS
1430</dl>
1431<h4 class="returnvalue">Return Value</h4>
abacc52b 1432 <p class="description">Value or <code>NULL</code> if not found</p>
5a738aea 1433<h4 class="discussion">Discussion</h4>
abacc52b 1434 <p class="discussion">This function uses the current locale to find the corresponding name
5a738aea
MS
1435text from the attribute value. If no localized text for the requested
1436name can be found, <code>NULL</code> is returned.
1437
1438</p>
abacc52b
MS
1439<h3 class="function"><a id="ppdMarkDefaults">ppdMarkDefaults</a></h3>
1440 <p class="description">Mark all default options in the PPD file.</p>
5a738aea 1441<p class="code">
abacc52b
MS
1442void ppdMarkDefaults (<br />
1443&#160;&#160;&#160;&#160;<a href="#ppd_file_t">ppd_file_t</a> *ppd<br />
5a738aea
MS
1444);</p>
1445<h4 class="parameters">Parameters</h4>
1446<dl>
1447<dt>ppd</dt>
abacc52b 1448 <dd class="description">PPD file record</dd>
5a738aea 1449</dl>
abacc52b
MS
1450<h3 class="function"><a id="ppdMarkOption">ppdMarkOption</a></h3>
1451 <p class="description">Mark an option in a PPD file and return the number of
66ab9486 1452conflicts.</p>
5a738aea 1453<p class="code">
abacc52b
MS
1454int ppdMarkOption (<br />
1455&#160;&#160;&#160;&#160;<a href="#ppd_file_t">ppd_file_t</a> *ppd,<br />
1456&#160;&#160;&#160;&#160;const char *option,<br />
1457&#160;&#160;&#160;&#160;const char *choice<br />
5a738aea
MS
1458);</p>
1459<h4 class="parameters">Parameters</h4>
1460<dl>
1461<dt>ppd</dt>
abacc52b 1462 <dd class="description">PPD file record</dd>
5a738aea 1463<dt>option</dt>
abacc52b 1464 <dd class="description">Keyword</dd>
5a738aea 1465<dt>choice</dt>
abacc52b 1466 <dd class="description">Option name</dd>
5a738aea
MS
1467</dl>
1468<h4 class="returnvalue">Return Value</h4>
abacc52b
MS
1469 <p class="description">Number of conflicts</p>
1470<h3 class="function"><span class="info">&#160;CUPS 1.2/macOS 10.5&#160;</span><a id="ppdNextCustomParam">ppdNextCustomParam</a></h3>
1471 <p class="description">Return the next parameter for a custom option.</p>
5a738aea 1472<p class="code">
abacc52b
MS
1473<a href="#ppd_cparam_t">ppd_cparam_t</a> *ppdNextCustomParam (<br />
1474&#160;&#160;&#160;&#160;<a href="#ppd_coption_t">ppd_coption_t</a> *opt<br />
5a738aea
MS
1475);</p>
1476<h4 class="parameters">Parameters</h4>
1477<dl>
1478<dt>opt</dt>
abacc52b 1479 <dd class="description">Custom option</dd>
5a738aea
MS
1480</dl>
1481<h4 class="returnvalue">Return Value</h4>
abacc52b
MS
1482 <p class="description">Custom parameter or NULL</p>
1483<h3 class="function"><span class="info">&#160;CUPS 1.2/macOS 10.5&#160;</span><a id="ppdNextOption">ppdNextOption</a></h3>
1484 <p class="description">Return the next option in the PPD file.</p>
5a738aea 1485<p class="code">
abacc52b
MS
1486<a href="#ppd_option_t">ppd_option_t</a> *ppdNextOption (<br />
1487&#160;&#160;&#160;&#160;<a href="#ppd_file_t">ppd_file_t</a> *ppd<br />
5a738aea
MS
1488);</p>
1489<h4 class="parameters">Parameters</h4>
1490<dl>
1491<dt>ppd</dt>
abacc52b 1492 <dd class="description">PPD file</dd>
5a738aea
MS
1493</dl>
1494<h4 class="returnvalue">Return Value</h4>
abacc52b 1495 <p class="description">Next option or <code>NULL</code></p>
5a738aea 1496<h4 class="discussion">Discussion</h4>
abacc52b 1497 <p class="discussion">Options are returned from all groups in ascending alphanumeric order.
5a738aea
MS
1498
1499</p>
abacc52b
MS
1500<h3 class="function"><a id="ppdPageLength">ppdPageLength</a></h3>
1501 <p class="description">Get the page length for the given size.</p>
5a738aea 1502<p class="code">
abacc52b
MS
1503float ppdPageLength (<br />
1504&#160;&#160;&#160;&#160;<a href="#ppd_file_t">ppd_file_t</a> *ppd,<br />
1505&#160;&#160;&#160;&#160;const char *name<br />
5a738aea
MS
1506);</p>
1507<h4 class="parameters">Parameters</h4>
1508<dl>
1509<dt>ppd</dt>
abacc52b 1510 <dd class="description">PPD file</dd>
5a738aea 1511<dt>name</dt>
abacc52b 1512 <dd class="description">Size name</dd>
5a738aea
MS
1513</dl>
1514<h4 class="returnvalue">Return Value</h4>
abacc52b
MS
1515 <p class="description">Length of page in points or 0.0</p>
1516<h3 class="function"><a id="ppdPageSize">ppdPageSize</a></h3>
1517 <p class="description">Get the page size record for the named size.</p>
5a738aea 1518<p class="code">
abacc52b
MS
1519<a href="#ppd_size_t">ppd_size_t</a> *ppdPageSize (<br />
1520&#160;&#160;&#160;&#160;<a href="#ppd_file_t">ppd_file_t</a> *ppd,<br />
1521&#160;&#160;&#160;&#160;const char *name<br />
5a738aea
MS
1522);</p>
1523<h4 class="parameters">Parameters</h4>
1524<dl>
1525<dt>ppd</dt>
abacc52b 1526 <dd class="description">PPD file record</dd>
5a738aea 1527<dt>name</dt>
abacc52b 1528 <dd class="description">Size name</dd>
5a738aea
MS
1529</dl>
1530<h4 class="returnvalue">Return Value</h4>
abacc52b
MS
1531 <p class="description">Size record for page or NULL</p>
1532<h3 class="function"><span class="info">&#160;CUPS 1.4/macOS 10.6&#160;</span><a id="ppdPageSizeLimits">ppdPageSizeLimits</a></h3>
1533 <p class="description">Return the custom page size limits.</p>
005dd1eb 1534<p class="code">
abacc52b
MS
1535int ppdPageSizeLimits (<br />
1536&#160;&#160;&#160;&#160;<a href="#ppd_file_t">ppd_file_t</a> *ppd,<br />
1537&#160;&#160;&#160;&#160;<a href="#ppd_size_t">ppd_size_t</a> *minimum,<br />
1538&#160;&#160;&#160;&#160;<a href="#ppd_size_t">ppd_size_t</a> *maximum<br />
005dd1eb
MS
1539);</p>
1540<h4 class="parameters">Parameters</h4>
1541<dl>
1542<dt>ppd</dt>
abacc52b 1543 <dd class="description">PPD file record</dd>
005dd1eb 1544<dt>minimum</dt>
abacc52b 1545 <dd class="description">Minimum custom size</dd>
005dd1eb 1546<dt>maximum</dt>
abacc52b 1547 <dd class="description">Maximum custom size</dd>
005dd1eb
MS
1548</dl>
1549<h4 class="returnvalue">Return Value</h4>
abacc52b 1550 <p class="description">1 if custom sizes are supported, 0 otherwise</p>
005dd1eb 1551<h4 class="discussion">Discussion</h4>
abacc52b 1552 <p class="discussion">This function returns the minimum and maximum custom page sizes and printable
005dd1eb
MS
1553areas based on the currently-marked (selected) options.<br>
1554<br>
1555If the specified PPD file does not support custom page sizes, both
1556&quot;minimum&quot; and &quot;maximum&quot; are filled with zeroes.
1557
1558</p>
abacc52b
MS
1559<h3 class="function"><a id="ppdPageWidth">ppdPageWidth</a></h3>
1560 <p class="description">Get the page width for the given size.</p>
5a738aea 1561<p class="code">
abacc52b
MS
1562float ppdPageWidth (<br />
1563&#160;&#160;&#160;&#160;<a href="#ppd_file_t">ppd_file_t</a> *ppd,<br />
1564&#160;&#160;&#160;&#160;const char *name<br />
5a738aea
MS
1565);</p>
1566<h4 class="parameters">Parameters</h4>
1567<dl>
1568<dt>ppd</dt>
abacc52b 1569 <dd class="description">PPD file record</dd>
5a738aea 1570<dt>name</dt>
abacc52b 1571 <dd class="description">Size name</dd>
5a738aea
MS
1572</dl>
1573<h4 class="returnvalue">Return Value</h4>
abacc52b
MS
1574 <p class="description">Width of page in points or 0.0</p>
1575 <h2 class="title"><a id="TYPES">Data Types</a></h2>
1576 <h3 class="typedef"><a id="ppd_attr_t"><span class="info">&#160;CUPS 1.1.19/macOS 10.3&#160;</span>ppd_attr_t</a></h3>
1577 <p class="description">PPD Attribute Structure </p>
1578 <p class="code">
5a738aea
MS
1579typedef struct <a href="#ppd_attr_s">ppd_attr_s</a> ppd_attr_t;
1580</p>
abacc52b
MS
1581 <h3 class="typedef"><a id="ppd_choice_t">ppd_choice_t</a></h3>
1582 <p class="description">Option choices</p>
1583 <p class="code">
5a738aea
MS
1584typedef struct <a href="#ppd_choice_s">ppd_choice_s</a> ppd_choice_t;
1585</p>
abacc52b
MS
1586 <h3 class="typedef"><a id="ppd_conform_t"><span class="info">&#160;CUPS 1.1.19/macOS 10.3&#160;</span>ppd_conform_t</a></h3>
1587 <p class="description">Conformance Levels </p>
1588 <p class="code">
5a738aea
MS
1589typedef enum <a href="#ppd_conform_e">ppd_conform_e</a> ppd_conform_t;
1590</p>
abacc52b
MS
1591 <h3 class="typedef"><a id="ppd_const_t">ppd_const_t</a></h3>
1592 <p class="description">Constraints</p>
1593 <p class="code">
5a738aea
MS
1594typedef struct <a href="#ppd_const_s">ppd_const_s</a> ppd_const_t;
1595</p>
abacc52b
MS
1596 <h3 class="typedef"><a id="ppd_coption_t"><span class="info">&#160;CUPS 1.2/macOS 10.5&#160;</span>ppd_coption_t</a></h3>
1597 <p class="description">Custom Option </p>
1598 <p class="code">
5a738aea
MS
1599typedef struct <a href="#ppd_coption_s">ppd_coption_s</a> ppd_coption_t;
1600</p>
abacc52b
MS
1601 <h3 class="typedef"><a id="ppd_cparam_t"><span class="info">&#160;CUPS 1.2/macOS 10.5&#160;</span>ppd_cparam_t</a></h3>
1602 <p class="description">Custom Parameter </p>
1603 <p class="code">
5a738aea
MS
1604typedef struct <a href="#ppd_cparam_s">ppd_cparam_s</a> ppd_cparam_t;
1605</p>
abacc52b
MS
1606 <h3 class="typedef"><a id="ppd_cplimit_t"><span class="info">&#160;CUPS 1.2/macOS 10.5&#160;</span>ppd_cplimit_t</a></h3>
1607 <p class="description">Custom Parameter Limit </p>
1608 <p class="code">
5a738aea
MS
1609typedef union <a href="#ppd_cplimit_u">ppd_cplimit_u</a> ppd_cplimit_t;
1610</p>
abacc52b
MS
1611 <h3 class="typedef"><a id="ppd_cptype_t"><span class="info">&#160;CUPS 1.2/macOS 10.5&#160;</span>ppd_cptype_t</a></h3>
1612 <p class="description">Custom Parameter Type </p>
1613 <p class="code">
82f97232 1614typedef enum ppd_cptype_e ppd_cptype_t;
5a738aea 1615</p>
abacc52b
MS
1616 <h3 class="typedef"><a id="ppd_cpvalue_t"><span class="info">&#160;CUPS 1.2/macOS 10.5&#160;</span>ppd_cpvalue_t</a></h3>
1617 <p class="description">Custom Parameter Value </p>
1618 <p class="code">
5a738aea
MS
1619typedef union <a href="#ppd_cpvalue_u">ppd_cpvalue_u</a> ppd_cpvalue_t;
1620</p>
abacc52b
MS
1621 <h3 class="typedef"><a id="ppd_cs_t">ppd_cs_t</a></h3>
1622 <p class="description">Colorspaces</p>
1623 <p class="code">
79e1d494
MS
1624typedef enum <a href="#ppd_cs_e">ppd_cs_e</a> ppd_cs_t;
1625</p>
abacc52b
MS
1626 <h3 class="typedef"><a id="ppd_emul_t">ppd_emul_t</a></h3>
1627 <p class="description">Emulators</p>
1628 <p class="code">
5a738aea
MS
1629typedef struct <a href="#ppd_emul_s">ppd_emul_s</a> ppd_emul_t;
1630</p>
abacc52b
MS
1631 <h3 class="typedef"><a id="ppd_file_t">ppd_file_t</a></h3>
1632 <p class="description">PPD File</p>
1633 <p class="code">
5a738aea
MS
1634typedef struct <a href="#ppd_file_s">ppd_file_s</a> ppd_file_t;
1635</p>
abacc52b
MS
1636 <h3 class="typedef"><a id="ppd_group_t">ppd_group_t</a></h3>
1637 <p class="description">Groups</p>
1638 <p class="code">
5a738aea
MS
1639typedef struct <a href="#ppd_group_s">ppd_group_s</a> ppd_group_t;
1640</p>
abacc52b
MS
1641 <h3 class="typedef"><a id="ppd_option_t">ppd_option_t</a></h3>
1642 <p class="description">Options</p>
1643 <p class="code">
5a738aea
MS
1644typedef struct <a href="#ppd_option_s">ppd_option_s</a> ppd_option_t;
1645</p>
abacc52b
MS
1646 <h3 class="typedef"><a id="ppd_profile_t">ppd_profile_t</a></h3>
1647 <p class="description">sRGB Color Profiles</p>
1648 <p class="code">
5a738aea
MS
1649typedef struct <a href="#ppd_profile_s">ppd_profile_s</a> ppd_profile_t;
1650</p>
abacc52b
MS
1651 <h3 class="typedef"><a id="ppd_section_t">ppd_section_t</a></h3>
1652 <p class="description">Order dependency sections</p>
1653 <p class="code">
5a738aea
MS
1654typedef enum <a href="#ppd_section_e">ppd_section_e</a> ppd_section_t;
1655</p>
abacc52b
MS
1656 <h3 class="typedef"><a id="ppd_size_t">ppd_size_t</a></h3>
1657 <p class="description">Page Sizes</p>
1658 <p class="code">
5a738aea
MS
1659typedef struct <a href="#ppd_size_s">ppd_size_s</a> ppd_size_t;
1660</p>
abacc52b
MS
1661 <h3 class="typedef"><a id="ppd_status_t"><span class="info">&#160;CUPS 1.1.19/macOS 10.3&#160;</span>ppd_status_t</a></h3>
1662 <p class="description">Status Codes </p>
1663 <p class="code">
79e1d494
MS
1664typedef enum <a href="#ppd_status_e">ppd_status_e</a> ppd_status_t;
1665</p>
abacc52b
MS
1666 <h3 class="typedef"><a id="ppd_ui_t">ppd_ui_t</a></h3>
1667 <p class="description">UI Types</p>
1668 <p class="code">
5a738aea
MS
1669typedef enum <a href="#ppd_ui_e">ppd_ui_e</a> ppd_ui_t;
1670</p>
abacc52b
MS
1671 <h2 class="title"><a id="STRUCTURES">Structures</a></h2>
1672<h3 class="struct"><span class="info">&#160;CUPS 1.1.19/macOS 10.3&#160;</span><a id="ppd_attr_s">ppd_attr_s</a></h3>
1673 <p class="description">PPD Attribute Structure </p>
1674<p class="code">struct ppd_attr_s {<br />
1675&#160;&#160;&#160;&#160;char name[PPD_MAX_NAME];<br />
1676&#160;&#160;&#160;&#160;char spec[PPD_MAX_NAME];<br />
1677&#160;&#160;&#160;&#160;char text[PPD_MAX_TEXT];<br />
1678&#160;&#160;&#160;&#160;char *value;<br />
5a738aea
MS
1679};</p>
1680<h4 class="members">Members</h4>
1681<dl>
1682<dt>name[PPD_MAX_NAME] </dt>
abacc52b 1683 <dd class="description">Name of attribute (cupsXYZ)</dd>
5a738aea 1684<dt>spec[PPD_MAX_NAME] </dt>
abacc52b 1685 <dd class="description">Specifier string, if any</dd>
5a738aea 1686<dt>text[PPD_MAX_TEXT] </dt>
abacc52b 1687 <dd class="description">Human-readable text, if any</dd>
5a738aea 1688<dt>value </dt>
abacc52b 1689 <dd class="description">Value string</dd>
5a738aea 1690</dl>
abacc52b
MS
1691<h3 class="struct"><a id="ppd_choice_s">ppd_choice_s</a></h3>
1692 <p class="description">Option choices</p>
1693<p class="code">struct ppd_choice_s {<br />
1694&#160;&#160;&#160;&#160;char choice[PPD_MAX_NAME];<br />
1695&#160;&#160;&#160;&#160;char *code;<br />
1696&#160;&#160;&#160;&#160;char marked;<br />
1697&#160;&#160;&#160;&#160;<a href="#ppd_option_t">ppd_option_t</a> *option;<br />
1698&#160;&#160;&#160;&#160;char text[PPD_MAX_TEXT];<br />
5a738aea
MS
1699};</p>
1700<h4 class="members">Members</h4>
1701<dl>
1702<dt>choice[PPD_MAX_NAME] </dt>
abacc52b 1703 <dd class="description">Computer-readable option name</dd>
5a738aea 1704<dt>code </dt>
abacc52b 1705 <dd class="description">Code to send for this option</dd>
5a738aea 1706<dt>marked </dt>
abacc52b 1707 <dd class="description">0 if not selected, 1 otherwise</dd>
5a738aea 1708<dt>option </dt>
abacc52b 1709 <dd class="description">Pointer to parent option structure</dd>
5a738aea 1710<dt>text[PPD_MAX_TEXT] </dt>
abacc52b 1711 <dd class="description">Human-readable option name</dd>
5a738aea 1712</dl>
abacc52b
MS
1713<h3 class="struct"><a id="ppd_const_s">ppd_const_s</a></h3>
1714 <p class="description">Constraints</p>
1715<p class="code">struct ppd_const_s {<br />
1716&#160;&#160;&#160;&#160;char choice1[PPD_MAX_NAME];<br />
1717&#160;&#160;&#160;&#160;char choice2[PPD_MAX_NAME];<br />
1718&#160;&#160;&#160;&#160;char option1[PPD_MAX_NAME];<br />
1719&#160;&#160;&#160;&#160;char option2[PPD_MAX_NAME];<br />
5a738aea
MS
1720};</p>
1721<h4 class="members">Members</h4>
1722<dl>
1723<dt>choice1[PPD_MAX_NAME] </dt>
abacc52b 1724 <dd class="description">First option/choice (blank for all)</dd>
5a738aea 1725<dt>choice2[PPD_MAX_NAME] </dt>
abacc52b 1726 <dd class="description">Second option/choice (blank for all)</dd>
5a738aea 1727<dt>option1[PPD_MAX_NAME] </dt>
abacc52b 1728 <dd class="description">First keyword</dd>
5a738aea 1729<dt>option2[PPD_MAX_NAME] </dt>
abacc52b 1730 <dd class="description">Second keyword</dd>
5a738aea 1731</dl>
abacc52b
MS
1732<h3 class="struct"><span class="info">&#160;CUPS 1.2/macOS 10.5&#160;</span><a id="ppd_coption_s">ppd_coption_s</a></h3>
1733 <p class="description">Custom Option </p>
1734<p class="code">struct ppd_coption_s {<br />
1735&#160;&#160;&#160;&#160;char keyword[PPD_MAX_NAME];<br />
1736&#160;&#160;&#160;&#160;int marked;<br />
1737&#160;&#160;&#160;&#160;<a href="#ppd_option_t">ppd_option_t</a> *option;<br />
1738&#160;&#160;&#160;&#160;cups_array_t *params;<br />
5a738aea
MS
1739};</p>
1740<h4 class="members">Members</h4>
1741<dl>
1742<dt>keyword[PPD_MAX_NAME] </dt>
abacc52b 1743 <dd class="description">Name of option that is being extended...</dd>
5a738aea 1744<dt>marked </dt>
abacc52b 1745 <dd class="description">Extended option is marked</dd>
5a738aea 1746<dt>option </dt>
abacc52b 1747 <dd class="description">Option that is being extended...</dd>
5a738aea 1748<dt>params </dt>
abacc52b 1749 <dd class="description">Parameters</dd>
5a738aea 1750</dl>
abacc52b
MS
1751<h3 class="struct"><span class="info">&#160;CUPS 1.2/macOS 10.5&#160;</span><a id="ppd_cparam_s">ppd_cparam_s</a></h3>
1752 <p class="description">Custom Parameter </p>
1753<p class="code">struct ppd_cparam_s {<br />
1754&#160;&#160;&#160;&#160;<a href="#ppd_cpvalue_t">ppd_cpvalue_t</a> current;<br />
1755&#160;&#160;&#160;&#160;<a href="#ppd_cplimit_t">ppd_cplimit_t</a> minimum, maximum;<br />
1756&#160;&#160;&#160;&#160;char name[PPD_MAX_NAME];<br />
1757&#160;&#160;&#160;&#160;int order;<br />
1758&#160;&#160;&#160;&#160;char text[PPD_MAX_TEXT];<br />
1759&#160;&#160;&#160;&#160;<a href="#ppd_cptype_t">ppd_cptype_t</a> type;<br />
5a738aea
MS
1760};</p>
1761<h4 class="members">Members</h4>
1762<dl>
1763<dt>current </dt>
abacc52b 1764 <dd class="description">Current value</dd>
5a738aea 1765<dt>maximum </dt>
abacc52b 1766 <dd class="description">Maximum value</dd>
5a738aea 1767<dt>name[PPD_MAX_NAME] </dt>
abacc52b 1768 <dd class="description">Parameter name</dd>
5a738aea 1769<dt>order </dt>
abacc52b 1770 <dd class="description">Order (0 to N)</dd>
5a738aea 1771<dt>text[PPD_MAX_TEXT] </dt>
abacc52b 1772 <dd class="description">Human-readable text</dd>
5a738aea 1773<dt>type </dt>
abacc52b 1774 <dd class="description">Parameter type</dd>
5a738aea 1775</dl>
abacc52b
MS
1776<h3 class="struct"><a id="ppd_emul_s">ppd_emul_s</a></h3>
1777 <p class="description">Emulators</p>
1778<p class="code">struct ppd_emul_s {<br />
1779&#160;&#160;&#160;&#160;char name[PPD_MAX_NAME];<br />
1780&#160;&#160;&#160;&#160;char *start;<br />
1781&#160;&#160;&#160;&#160;char *stop;<br />
5a738aea
MS
1782};</p>
1783<h4 class="members">Members</h4>
1784<dl>
1785<dt>name[PPD_MAX_NAME] </dt>
abacc52b 1786 <dd class="description">Emulator name</dd>
5a738aea 1787<dt>start </dt>
abacc52b 1788 <dd class="description">Code to switch to this emulation</dd>
5a738aea 1789<dt>stop </dt>
abacc52b 1790 <dd class="description">Code to stop this emulation</dd>
5a738aea 1791</dl>
abacc52b
MS
1792<h3 class="struct"><a id="ppd_file_s">ppd_file_s</a></h3>
1793 <p class="description">PPD File</p>
1794<p class="code">struct ppd_file_s {<br />
1795&#160;&#160;&#160;&#160;int accurate_screens;<br />
1796&#160;&#160;&#160;&#160;int color_device;<br />
1797&#160;&#160;&#160;&#160;<a href="#ppd_cs_t">ppd_cs_t</a> colorspace;<br />
1798&#160;&#160;&#160;&#160;<a href="#ppd_const_t">ppd_const_t</a> *consts;<br />
1799&#160;&#160;&#160;&#160;int contone_only;<br />
1800&#160;&#160;&#160;&#160;float custom_margins[4];<br />
1801&#160;&#160;&#160;&#160;float custom_max[2];<br />
1802&#160;&#160;&#160;&#160;float custom_min[2];<br />
1803&#160;&#160;&#160;&#160;<a href="#ppd_emul_t">ppd_emul_t</a> *emulations;<br />
1804&#160;&#160;&#160;&#160;char **filters;<br />
1805&#160;&#160;&#160;&#160;int flip_duplex;<br />
1806&#160;&#160;&#160;&#160;char **fonts;<br />
1807&#160;&#160;&#160;&#160;<a href="#ppd_group_t">ppd_group_t</a> *groups;<br />
1808&#160;&#160;&#160;&#160;char *jcl_begin;<br />
1809&#160;&#160;&#160;&#160;char *jcl_end;<br />
1810&#160;&#160;&#160;&#160;char *jcl_ps;<br />
1811&#160;&#160;&#160;&#160;int landscape;<br />
1812&#160;&#160;&#160;&#160;char *lang_encoding;<br />
1813&#160;&#160;&#160;&#160;char *lang_version;<br />
1814&#160;&#160;&#160;&#160;int language_level;<br />
1815&#160;&#160;&#160;&#160;int manual_copies;<br />
1816&#160;&#160;&#160;&#160;char *manufacturer;<br />
1817&#160;&#160;&#160;&#160;int model_number;<br />
1818&#160;&#160;&#160;&#160;char *modelname;<br />
1819&#160;&#160;&#160;&#160;char *nickname;<br />
1820&#160;&#160;&#160;&#160;int num_consts;<br />
1821&#160;&#160;&#160;&#160;int num_emulations;<br />
1822&#160;&#160;&#160;&#160;int num_filters;<br />
1823&#160;&#160;&#160;&#160;int num_fonts;<br />
1824&#160;&#160;&#160;&#160;int num_groups;<br />
1825&#160;&#160;&#160;&#160;int num_profiles;<br />
1826&#160;&#160;&#160;&#160;int num_sizes;<br />
1827&#160;&#160;&#160;&#160;char *patches;<br />
1828&#160;&#160;&#160;&#160;char *pcfilename;<br />
1829&#160;&#160;&#160;&#160;char *product;<br />
1830&#160;&#160;&#160;&#160;<a href="#ppd_profile_t">ppd_profile_t</a> *profiles;<br />
1831&#160;&#160;&#160;&#160;char *protocols;<br />
1832&#160;&#160;&#160;&#160;char *shortnickname;<br />
1833&#160;&#160;&#160;&#160;<a href="#ppd_size_t">ppd_size_t</a> *sizes;<br />
1834&#160;&#160;&#160;&#160;int throughput;<br />
1835&#160;&#160;&#160;&#160;char *ttrasterizer;<br />
1836&#160;&#160;&#160;&#160;int variable_sizes;<br />
5a738aea
MS
1837};</p>
1838<h4 class="members">Members</h4>
1839<dl>
1840<dt>accurate_screens </dt>
abacc52b 1841 <dd class="description">1 = supports accurate screens, 0 = not</dd>
5a738aea 1842<dt>color_device </dt>
abacc52b 1843 <dd class="description">1 = color device, 0 = grayscale</dd>
5a738aea 1844<dt>colorspace </dt>
abacc52b 1845 <dd class="description">Default colorspace</dd>
5a738aea 1846<dt>consts </dt>
abacc52b 1847 <dd class="description">UI/Non-UI constraints</dd>
5a738aea 1848<dt>contone_only </dt>
abacc52b 1849 <dd class="description">1 = continuous tone only, 0 = not</dd>
5a738aea 1850<dt>custom_margins[4] </dt>
abacc52b 1851 <dd class="description">Margins around page</dd>
5a738aea 1852<dt>custom_max[2] </dt>
abacc52b 1853 <dd class="description">Maximum variable page size</dd>
5a738aea 1854<dt>custom_min[2] </dt>
abacc52b 1855 <dd class="description">Minimum variable page size</dd>
5a738aea 1856<dt>emulations </dt>
abacc52b 1857 <dd class="description">Emulations and the code to invoke them</dd>
5a738aea 1858<dt>filters </dt>
abacc52b
MS
1859 <dd class="description">Filter strings...</dd>
1860<dt>flip_duplex <span class="info">&#160;DEPRECATED&#160;</span></dt>
1861 <dd class="description">1 = Flip page for back sides </dd>
5a738aea 1862<dt>fonts </dt>
abacc52b 1863 <dd class="description">Pre-loaded fonts</dd>
5a738aea 1864<dt>groups </dt>
abacc52b 1865 <dd class="description">UI groups</dd>
5a738aea 1866<dt>jcl_begin </dt>
abacc52b 1867 <dd class="description">Start JCL commands</dd>
5a738aea 1868<dt>jcl_end </dt>
abacc52b 1869 <dd class="description">End JCL commands</dd>
5a738aea 1870<dt>jcl_ps </dt>
abacc52b 1871 <dd class="description">Enter PostScript interpreter</dd>
5a738aea 1872<dt>landscape </dt>
abacc52b 1873 <dd class="description">-90 or 90</dd>
5a738aea 1874<dt>lang_encoding </dt>
abacc52b 1875 <dd class="description">Language encoding</dd>
5a738aea 1876<dt>lang_version </dt>
abacc52b 1877 <dd class="description">Language version (English, Spanish, etc.)</dd>
5a738aea 1878<dt>language_level </dt>
abacc52b 1879 <dd class="description">Language level of device</dd>
5a738aea 1880<dt>manual_copies </dt>
abacc52b 1881 <dd class="description">1 = Copies done manually, 0 = hardware</dd>
5a738aea 1882<dt>manufacturer </dt>
abacc52b 1883 <dd class="description">Manufacturer name</dd>
5a738aea 1884<dt>model_number </dt>
abacc52b 1885 <dd class="description">Device-specific model number</dd>
5a738aea 1886<dt>modelname </dt>
abacc52b 1887 <dd class="description">Model name (general)</dd>
5a738aea 1888<dt>nickname </dt>
abacc52b 1889 <dd class="description">Nickname (specific)</dd>
5a738aea 1890<dt>num_consts </dt>
abacc52b 1891 <dd class="description">Number of UI/Non-UI constraints</dd>
5a738aea 1892<dt>num_emulations </dt>
abacc52b 1893 <dd class="description">Number of emulations supported</dd>
5a738aea 1894<dt>num_filters </dt>
abacc52b 1895 <dd class="description">Number of filters</dd>
5a738aea 1896<dt>num_fonts </dt>
abacc52b 1897 <dd class="description">Number of pre-loaded fonts</dd>
5a738aea 1898<dt>num_groups </dt>
abacc52b
MS
1899 <dd class="description">Number of UI groups</dd>
1900<dt>num_profiles <span class="info">&#160;DEPRECATED&#160;</span></dt>
1901 <dd class="description">Number of sRGB color profiles </dd>
5a738aea 1902<dt>num_sizes </dt>
abacc52b 1903 <dd class="description">Number of page sizes</dd>
5a738aea 1904<dt>patches </dt>
abacc52b
MS
1905 <dd class="description">Patch commands to be sent to printer</dd>
1906<dt>pcfilename <span class="info">&#160;CUPS 1.1.19/macOS 10.3&#160;</span></dt>
1907 <dd class="description">PCFileName string </dd>
5a738aea 1908<dt>product </dt>
abacc52b
MS
1909 <dd class="description">Product name (from PS RIP/interpreter)</dd>
1910<dt>profiles <span class="info">&#160;DEPRECATED&#160;</span></dt>
1911 <dd class="description">sRGB color profiles </dd>
1912<dt>protocols <span class="info">&#160;CUPS 1.1.19/macOS 10.3&#160;</span></dt>
1913 <dd class="description">Protocols (BCP, TBCP) string </dd>
5a738aea 1914<dt>shortnickname </dt>
abacc52b 1915 <dd class="description">Short version of nickname</dd>
5a738aea 1916<dt>sizes </dt>
abacc52b 1917 <dd class="description">Page sizes</dd>
5a738aea 1918<dt>throughput </dt>
abacc52b 1919 <dd class="description">Pages per minute</dd>
5a738aea 1920<dt>ttrasterizer </dt>
abacc52b 1921 <dd class="description">Truetype rasterizer</dd>
5a738aea 1922<dt>variable_sizes </dt>
abacc52b 1923 <dd class="description">1 = supports variable sizes, 0 = doesn't</dd>
5a738aea 1924</dl>
abacc52b
MS
1925<h3 class="struct"><a id="ppd_group_s">ppd_group_s</a></h3>
1926 <p class="description">Groups</p>
1927<p class="code">struct ppd_group_s {<br />
1928&#160;&#160;&#160;&#160;char text[PPD_MAX_TEXT - PPD_MAX_NAME];<br />
1929&#160;&#160;&#160;&#160;char name[PPD_MAX_NAME];<br />
1930&#160;&#160;&#160;&#160;int num_options;<br />
1931&#160;&#160;&#160;&#160;int num_subgroups;<br />
1932&#160;&#160;&#160;&#160;<a href="#ppd_option_t">ppd_option_t</a> *options;<br />
1933&#160;&#160;&#160;&#160;struct <a href="#ppd_group_s">ppd_group_s</a> *subgroups;<br />
5a738aea
MS
1934};</p>
1935<h4 class="members">Members</h4>
1936<dl>
1937<dt>PPD_MAX_NAME] </dt>
abacc52b
MS
1938 <dd class="description">Human-readable group name</dd>
1939<dt>name[PPD_MAX_NAME] <span class="info">&#160;CUPS 1.1.18/macOS 10.3&#160;</span></dt>
1940 <dd class="description">Group name </dd>
5a738aea 1941<dt>num_options </dt>
abacc52b 1942 <dd class="description">Number of options</dd>
5a738aea 1943<dt>num_subgroups </dt>
abacc52b 1944 <dd class="description">Number of sub-groups</dd>
5a738aea 1945<dt>options </dt>
abacc52b 1946 <dd class="description">Options</dd>
5a738aea 1947<dt>subgroups </dt>
abacc52b 1948 <dd class="description">Sub-groups (max depth = 1)</dd>
5a738aea 1949</dl>
abacc52b
MS
1950<h3 class="struct"><a id="ppd_option_s">ppd_option_s</a></h3>
1951 <p class="description">Options</p>
1952<p class="code">struct ppd_option_s {<br />
1953&#160;&#160;&#160;&#160;<a href="#ppd_choice_t">ppd_choice_t</a> *choices;<br />
1954&#160;&#160;&#160;&#160;char conflicted;<br />
1955&#160;&#160;&#160;&#160;char defchoice[PPD_MAX_NAME];<br />
1956&#160;&#160;&#160;&#160;char keyword[PPD_MAX_NAME];<br />
1957&#160;&#160;&#160;&#160;int num_choices;<br />
1958&#160;&#160;&#160;&#160;float order;<br />
1959&#160;&#160;&#160;&#160;<a href="#ppd_section_t">ppd_section_t</a> section;<br />
1960&#160;&#160;&#160;&#160;char text[PPD_MAX_TEXT];<br />
1961&#160;&#160;&#160;&#160;<a href="#ppd_ui_t">ppd_ui_t</a> ui;<br />
5a738aea
MS
1962};</p>
1963<h4 class="members">Members</h4>
1964<dl>
1965<dt>choices </dt>
abacc52b 1966 <dd class="description">Option choices</dd>
5a738aea 1967<dt>conflicted </dt>
abacc52b 1968 <dd class="description">0 if no conflicts exist, 1 otherwise</dd>
5a738aea 1969<dt>defchoice[PPD_MAX_NAME] </dt>
abacc52b 1970 <dd class="description">Default option choice</dd>
5a738aea 1971<dt>keyword[PPD_MAX_NAME] </dt>
abacc52b 1972 <dd class="description">Option keyword name (&quot;PageSize&quot;, etc.)</dd>
5a738aea 1973<dt>num_choices </dt>
abacc52b 1974 <dd class="description">Number of option choices</dd>
5a738aea 1975<dt>order </dt>
abacc52b 1976 <dd class="description">Order number</dd>
5a738aea 1977<dt>section </dt>
abacc52b 1978 <dd class="description">Section for command</dd>
5a738aea 1979<dt>text[PPD_MAX_TEXT] </dt>
abacc52b 1980 <dd class="description">Human-readable text</dd>
5a738aea 1981<dt>ui </dt>
abacc52b 1982 <dd class="description">Type of UI option</dd>
5a738aea 1983</dl>
abacc52b
MS
1984<h3 class="struct"><a id="ppd_profile_s">ppd_profile_s</a></h3>
1985 <p class="description">sRGB Color Profiles</p>
1986<p class="code">struct ppd_profile_s {<br />
1987&#160;&#160;&#160;&#160;float density;<br />
1988&#160;&#160;&#160;&#160;float gamma;<br />
1989&#160;&#160;&#160;&#160;float matrix[3][3];<br />
1990&#160;&#160;&#160;&#160;char media_type[PPD_MAX_NAME];<br />
1991&#160;&#160;&#160;&#160;char resolution[PPD_MAX_NAME];<br />
5a738aea
MS
1992};</p>
1993<h4 class="members">Members</h4>
1994<dl>
1995<dt>density </dt>
abacc52b 1996 <dd class="description">Ink density to use</dd>
5a738aea 1997<dt>gamma </dt>
abacc52b 1998 <dd class="description">Gamma correction to use</dd>
5a738aea 1999<dt>matrix[3][3] </dt>
abacc52b 2000 <dd class="description">Transform matrix</dd>
5a738aea 2001<dt>media_type[PPD_MAX_NAME] </dt>
abacc52b 2002 <dd class="description">Media type or &quot;-&quot;</dd>
5a738aea 2003<dt>resolution[PPD_MAX_NAME] </dt>
abacc52b 2004 <dd class="description">Resolution or &quot;-&quot;</dd>
5a738aea 2005</dl>
abacc52b
MS
2006<h3 class="struct"><a id="ppd_size_s">ppd_size_s</a></h3>
2007 <p class="description">Page Sizes</p>
2008<p class="code">struct ppd_size_s {<br />
2009&#160;&#160;&#160;&#160;float bottom;<br />
2010&#160;&#160;&#160;&#160;float left;<br />
2011&#160;&#160;&#160;&#160;float length;<br />
2012&#160;&#160;&#160;&#160;int marked;<br />
2013&#160;&#160;&#160;&#160;char name[PPD_MAX_NAME];<br />
2014&#160;&#160;&#160;&#160;float right;<br />
2015&#160;&#160;&#160;&#160;float top;<br />
2016&#160;&#160;&#160;&#160;float width;<br />
5a738aea
MS
2017};</p>
2018<h4 class="members">Members</h4>
2019<dl>
2020<dt>bottom </dt>
abacc52b 2021 <dd class="description">Bottom printable margin in points</dd>
5a738aea 2022<dt>left </dt>
abacc52b 2023 <dd class="description">Left printable margin in points</dd>
5a738aea 2024<dt>length </dt>
abacc52b 2025 <dd class="description">Length of media in points</dd>
5a738aea 2026<dt>marked </dt>
abacc52b 2027 <dd class="description">Page size selected?</dd>
5a738aea 2028<dt>name[PPD_MAX_NAME] </dt>
abacc52b 2029 <dd class="description">Media size option</dd>
5a738aea 2030<dt>right </dt>
abacc52b 2031 <dd class="description">Right printable margin in points</dd>
5a738aea 2032<dt>top </dt>
abacc52b 2033 <dd class="description">Top printable margin in points</dd>
5a738aea 2034<dt>width </dt>
abacc52b 2035 <dd class="description">Width of media in points</dd>
5a738aea 2036</dl>
abacc52b
MS
2037 <h2 class="title"><a id="UNIONS">Unions</a></h2>
2038<h3 class="union"><span class="info">&#160;CUPS 1.2/macOS 10.5&#160;</span><a id="ppd_cplimit_u">ppd_cplimit_u</a></h3>
2039 <p class="description">Custom Parameter Limit </p>
2040<p class="code">union ppd_cplimit_u {<br />
2041&#160;&#160;&#160;&#160;float custom_curve;<br />
2042&#160;&#160;&#160;&#160;int custom_int;<br />
2043&#160;&#160;&#160;&#160;float custom_invcurve;<br />
2044&#160;&#160;&#160;&#160;int custom_passcode;<br />
2045&#160;&#160;&#160;&#160;int custom_password;<br />
2046&#160;&#160;&#160;&#160;float custom_points;<br />
2047&#160;&#160;&#160;&#160;float custom_real;<br />
2048&#160;&#160;&#160;&#160;int custom_string;<br />
5a738aea
MS
2049};</p>
2050<h4 class="members">Members</h4>
2051<dl>
2052<dt>custom_curve </dt>
abacc52b 2053 <dd class="description">Gamma value</dd>
5a738aea 2054<dt>custom_int </dt>
abacc52b 2055 <dd class="description">Integer value</dd>
5a738aea 2056<dt>custom_invcurve </dt>
abacc52b 2057 <dd class="description">Gamma value</dd>
5a738aea 2058<dt>custom_passcode </dt>
abacc52b 2059 <dd class="description">Passcode length</dd>
5a738aea 2060<dt>custom_password </dt>
abacc52b 2061 <dd class="description">Password length</dd>
5a738aea 2062<dt>custom_points </dt>
abacc52b 2063 <dd class="description">Measurement value</dd>
5a738aea 2064<dt>custom_real </dt>
abacc52b 2065 <dd class="description">Real value</dd>
5a738aea 2066<dt>custom_string </dt>
abacc52b 2067 <dd class="description">String length</dd>
5a738aea 2068</dl>
abacc52b
MS
2069<h3 class="union"><span class="info">&#160;CUPS 1.2/macOS 10.5&#160;</span><a id="ppd_cpvalue_u">ppd_cpvalue_u</a></h3>
2070 <p class="description">Custom Parameter Value </p>
2071<p class="code">union ppd_cpvalue_u {<br />
2072&#160;&#160;&#160;&#160;float custom_curve;<br />
2073&#160;&#160;&#160;&#160;int custom_int;<br />
2074&#160;&#160;&#160;&#160;float custom_invcurve;<br />
2075&#160;&#160;&#160;&#160;char *custom_passcode;<br />
2076&#160;&#160;&#160;&#160;char *custom_password;<br />
2077&#160;&#160;&#160;&#160;float custom_points;<br />
2078&#160;&#160;&#160;&#160;float custom_real;<br />
2079&#160;&#160;&#160;&#160;char *custom_string;<br />
5a738aea
MS
2080};</p>
2081<h4 class="members">Members</h4>
2082<dl>
2083<dt>custom_curve </dt>
abacc52b 2084 <dd class="description">Gamma value</dd>
5a738aea 2085<dt>custom_int </dt>
abacc52b 2086 <dd class="description">Integer value</dd>
5a738aea 2087<dt>custom_invcurve </dt>
abacc52b 2088 <dd class="description">Gamma value</dd>
5a738aea 2089<dt>custom_passcode </dt>
abacc52b 2090 <dd class="description">Passcode value</dd>
5a738aea 2091<dt>custom_password </dt>
abacc52b 2092 <dd class="description">Password value</dd>
5a738aea 2093<dt>custom_points </dt>
abacc52b 2094 <dd class="description">Measurement value</dd>
5a738aea 2095<dt>custom_real </dt>
abacc52b 2096 <dd class="description">Real value</dd>
5a738aea 2097<dt>custom_string </dt>
abacc52b 2098 <dd class="description">String value</dd>
5a738aea 2099</dl>
abacc52b
MS
2100 <h2 class="title"><a id="ENUMERATIONS">Constants</a></h2>
2101 <h3 class="enumeration"><a id="ppd_conform_e"><span class="info">&#160;CUPS 1.1.19/macOS 10.3&#160;</span>ppd_conform_e</a></h3>
2102 <p class="description">Conformance Levels </p>
2103 <h4 class="constants">Constants</h4>
2104 <dl>
2105 <dt>PPD_CONFORM_RELAXED </dt>
2106 <dd class="description">Relax whitespace and control char</dd>
2107 <dt>PPD_CONFORM_STRICT </dt>
2108 <dd class="description">Require strict conformance</dd>
5a738aea 2109</dl>
abacc52b
MS
2110 <h3 class="enumeration"><a id="ppd_cs_e">ppd_cs_e</a></h3>
2111 <p class="description">Colorspaces</p>
2112 <h4 class="constants">Constants</h4>
2113 <dl>
2114 <dt>PPD_CS_CMY </dt>
2115 <dd class="description">CMY colorspace</dd>
2116 <dt>PPD_CS_CMYK </dt>
2117 <dd class="description">CMYK colorspace</dd>
2118 <dt>PPD_CS_GRAY </dt>
2119 <dd class="description">Grayscale colorspace</dd>
2120 <dt>PPD_CS_N </dt>
2121 <dd class="description">DeviceN colorspace</dd>
2122 <dt>PPD_CS_RGB </dt>
2123 <dd class="description">RGB colorspace</dd>
2124 <dt>PPD_CS_RGBK </dt>
2125 <dd class="description">RGBK (K = gray) colorspace</dd>
5a738aea 2126</dl>
abacc52b
MS
2127 <h3 class="enumeration"><a id="ppd_section_e">ppd_section_e</a></h3>
2128 <p class="description">Order dependency sections</p>
2129 <h4 class="constants">Constants</h4>
2130 <dl>
2131 <dt>PPD_ORDER_ANY </dt>
2132 <dd class="description">Option code can be anywhere in the file</dd>
2133 <dt>PPD_ORDER_DOCUMENT </dt>
2134 <dd class="description">... must be in the DocumentSetup section</dd>
2135 <dt>PPD_ORDER_EXIT </dt>
2136 <dd class="description">... must be sent prior to the document</dd>
2137 <dt>PPD_ORDER_JCL </dt>
2138 <dd class="description">... must be sent as a JCL command</dd>
2139 <dt>PPD_ORDER_PAGE </dt>
2140 <dd class="description">... must be in the PageSetup section</dd>
2141 <dt>PPD_ORDER_PROLOG </dt>
2142 <dd class="description">... must be in the Prolog section</dd>
5a738aea 2143</dl>
abacc52b
MS
2144 <h3 class="enumeration"><a id="ppd_status_e"><span class="info">&#160;CUPS 1.1.19/macOS 10.3&#160;</span>ppd_status_e</a></h3>
2145 <p class="description">Status Codes </p>
2146 <h4 class="constants">Constants</h4>
2147 <dl>
2148 <dt>PPD_ALLOC_ERROR </dt>
2149 <dd class="description">Memory allocation error</dd>
2150 <dt>PPD_BAD_CUSTOM_PARAM </dt>
2151 <dd class="description">Bad custom parameter</dd>
2152 <dt>PPD_BAD_OPEN_GROUP </dt>
2153 <dd class="description">Bad OpenGroup</dd>
2154 <dt>PPD_BAD_OPEN_UI </dt>
2155 <dd class="description">Bad OpenUI/JCLOpenUI</dd>
2156 <dt>PPD_BAD_ORDER_DEPENDENCY </dt>
2157 <dd class="description">Bad OrderDependency</dd>
2158 <dt>PPD_BAD_UI_CONSTRAINTS </dt>
2159 <dd class="description">Bad UIConstraints</dd>
2160 <dt>PPD_BAD_VALUE </dt>
2161 <dd class="description">Bad value string</dd>
2162 <dt>PPD_FILE_OPEN_ERROR </dt>
2163 <dd class="description">Unable to open PPD file</dd>
2164 <dt>PPD_ILLEGAL_CHARACTER </dt>
2165 <dd class="description">Illegal control character</dd>
2166 <dt>PPD_ILLEGAL_MAIN_KEYWORD </dt>
2167 <dd class="description">Illegal main keyword string</dd>
2168 <dt>PPD_ILLEGAL_OPTION_KEYWORD </dt>
2169 <dd class="description">Illegal option keyword string</dd>
2170 <dt>PPD_ILLEGAL_TRANSLATION </dt>
2171 <dd class="description">Illegal translation string</dd>
2172 <dt>PPD_ILLEGAL_WHITESPACE </dt>
2173 <dd class="description">Illegal whitespace character</dd>
2174 <dt>PPD_INTERNAL_ERROR </dt>
2175 <dd class="description">Internal error</dd>
2176 <dt>PPD_LINE_TOO_LONG </dt>
2177 <dd class="description">Line longer than 255 chars</dd>
2178 <dt>PPD_MISSING_ASTERISK </dt>
2179 <dd class="description">Missing asterisk in column 0</dd>
2180 <dt>PPD_MISSING_CLOSE_GROUP </dt>
2181 <dd class="description">Missing CloseGroup</dd>
2182 <dt>PPD_MISSING_OPTION_KEYWORD </dt>
2183 <dd class="description">Missing option keyword</dd>
2184 <dt>PPD_MISSING_PPDADOBE4 </dt>
2185 <dd class="description">Missing PPD-Adobe-4.x header</dd>
2186 <dt>PPD_MISSING_VALUE </dt>
2187 <dd class="description">Missing value string</dd>
2188 <dt>PPD_NESTED_OPEN_GROUP </dt>
2189 <dd class="description">OpenGroup without a CloseGroup first</dd>
2190 <dt>PPD_NESTED_OPEN_UI </dt>
2191 <dd class="description">OpenUI/JCLOpenUI without a CloseUI/JCLCloseUI first</dd>
2192 <dt>PPD_NULL_FILE </dt>
2193 <dd class="description">NULL PPD file pointer</dd>
2194 <dt>PPD_OK </dt>
2195 <dd class="description">OK</dd>
5a738aea 2196</dl>
abacc52b
MS
2197 <h3 class="enumeration"><a id="ppd_ui_e">ppd_ui_e</a></h3>
2198 <p class="description">UI Types</p>
2199 <h4 class="constants">Constants</h4>
2200 <dl>
2201 <dt>PPD_UI_BOOLEAN </dt>
2202 <dd class="description">True or False option</dd>
2203 <dt>PPD_UI_PICKMANY </dt>
2204 <dd class="description">Pick zero or more from a list</dd>
2205 <dt>PPD_UI_PICKONE </dt>
2206 <dd class="description">Pick one from a list</dd>
5a738aea 2207</dl>
abacc52b
MS
2208 </div>
2209 </body>
ef416fc2 2210</html>