]> git.ipfire.org Git - thirdparty/cups.git/blob - doc/help/api-ppdc.html
More man page updates.
[thirdparty/cups.git] / doc / help / api-ppdc.html
1 <!DOCTYPE HTML PUBLIC "-//W3C//DTD HTML 4.01 Transitional//EN" "http://www.w3.org/TR/html4/loose.dtd">
2 <html>
3 <!-- SECTION: Programming -->
4 <head>
5 <title>PPD Compiler API </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.7">
9 <style type="text/css"><!--
10 BODY {
11 font-family: lucida grande, geneva, helvetica, arial, sans-serif;
12 }
13
14 H1, H2, H3, H4, H5, H6, P, TD, TH {
15 font-family: lucida grande, geneva, helvetica, arial, sans-serif;
16 }
17
18 KBD {
19 font-family: monaco, courier, monospace;
20 font-weight: bold;
21 }
22
23 PRE {
24 font-family: monaco, courier, monospace;
25 }
26
27 PRE.command {
28 border: dotted thin #7f7f7f;
29 margin-left: 36pt;
30 padding: 10px;
31 }
32
33 P.compact {
34 margin: 0;
35 }
36
37 P.example {
38 font-style: italic;
39 margin-left: 36pt;
40 }
41
42 PRE.example {
43 background: #eeeeee;
44 border: dotted thin #999999;
45 margin-left: 36pt;
46 padding: 10pt;
47 }
48
49 PRE.command EM, PRE.example EM {
50 font-family: lucida grande, geneva, helvetica, arial, sans-serif;
51 }
52
53 P.command {
54 font-family: monaco, courier, monospace;
55 margin-left: 36pt;
56 }
57
58 P.formula {
59 font-style: italic;
60 margin-left: 36pt;
61 }
62
63 BLOCKQUOTE {
64 background: #eeeeee;
65 border: solid thin #999999;
66 padding: 10pt;
67 }
68
69 A IMG {
70 border: none;
71 }
72
73 A:link:hover IMG {
74 background: #f0f0f0;
75 border-radius: 10px;
76 -moz-border-radius: 10px;
77 }
78
79 A:link, A:visited {
80 font-weight: inherit;
81 text-decoration: none;
82 }
83
84 A:link:hover, A:visited:hover, A:active {
85 text-decoration: underline;
86 }
87
88 SUB, SUP {
89 font-size: 50%;
90 }
91
92 TR.data, TD.data, TR.data TD {
93 margin-top: 10pt;
94 padding: 5pt;
95 border-bottom: solid 1pt #999999;
96 }
97
98 TR.data TH {
99 border-bottom: solid 1pt #999999;
100 padding-top: 10pt;
101 padding-left: 5pt;
102 text-align: left;
103 }
104
105 DIV.table TABLE {
106 border: solid thin #999999;
107 border-collapse: collapse;
108 border-spacing: 0;
109 margin-left: auto;
110 margin-right: auto;
111 }
112
113 DIV.table CAPTION {
114 caption-side: top;
115 font-size: 120%;
116 font-style: italic;
117 font-weight: bold;
118 margin-left: auto;
119 margin-right: auto;
120 }
121
122 DIV.table TABLE TD {
123 border: solid thin #cccccc;
124 padding-top: 5pt;
125 }
126
127 DIV.table TABLE TH {
128 background: #cccccc;
129 border: none;
130 border-bottom: solid thin #999999;
131 }
132
133 DIV.figure TABLE {
134 margin-left: auto;
135 margin-right: auto;
136 }
137
138 DIV.figure CAPTION {
139 caption-side: bottom;
140 font-size: 120%;
141 font-style: italic;
142 font-weight: bold;
143 margin-left: auto;
144 margin-right: auto;
145 }
146
147 TH.label {
148 text-align: right;
149 vertical-align: top;
150 }
151
152 TH.sublabel {
153 text-align: right;
154 font-weight: normal;
155 }
156
157 HR {
158 border: solid thin;
159 }
160
161 SPAN.info {
162 background: black;
163 border: thin solid black;
164 color: white;
165 font-size: 80%;
166 font-style: italic;
167 font-weight: bold;
168 white-space: nowrap;
169 }
170
171 H2 SPAN.info, H3 SPAN.info, H4 SPAN.info {
172 float: right;
173 font-size: 100%;
174 }
175
176 H1.title {
177 }
178
179 H2.title, H3.title {
180 border-bottom: solid 2pt #000000;
181 }
182
183 DIV.indent, TABLE.indent {
184 margin-top: 2em;
185 margin-left: auto;
186 margin-right: auto;
187 width: 90%;
188 }
189
190 TABLE.indent {
191 border-collapse: collapse;
192 }
193
194 TABLE.indent TD, TABLE.indent TH {
195 padding: 0;
196 }
197
198 TABLE.list {
199 border-collapse: collapse;
200 margin-left: auto;
201 margin-right: auto;
202 width: 90%;
203 }
204
205 TABLE.list TH {
206 background: white;
207 border-bottom: solid thin #cccccc;
208 color: #444444;
209 padding-top: 10pt;
210 padding-left: 5pt;
211 text-align: left;
212 vertical-align: bottom;
213 white-space: nowrap;
214 }
215
216 TABLE.list TH A {
217 color: #4444cc;
218 }
219
220 TABLE.list TD {
221 border-bottom: solid thin #eeeeee;
222 padding-top: 5pt;
223 padding-left: 5pt;
224 }
225
226 TABLE.list TR:nth-child(even) {
227 background: #f8f8f8;
228 }
229
230 TABLE.list TR:nth-child(odd) {
231 background: #f4f4f4;
232 }
233
234 DT {
235 margin-left: 36pt;
236 margin-top: 12pt;
237 }
238
239 DD {
240 margin-left: 54pt;
241 }
242
243 DL.category DT {
244 font-weight: bold;
245 }
246
247 P.summary {
248 margin-left: 36pt;
249 font-family: monaco, courier, monospace;
250 }
251
252 DIV.summary TABLE {
253 border: solid thin #999999;
254 border-collapse: collapse;
255 border-spacing: 0;
256 margin: 10px;
257 }
258
259 DIV.summary TABLE TD, DIV.summary TABLE TH {
260 border: solid thin #999999;
261 padding: 5px;
262 text-align: left;
263 vertical-align: top;
264 }
265
266 DIV.summary TABLE THEAD TH {
267 background: #eeeeee;
268 }
269
270 /* API documentation styles... */
271 div.body h1 {
272 margin: 0;
273 }
274 div.body h2 {
275 margin-top: 1.5em;
276 }
277 div.body h3, div.body h4, div.body h5 {
278 margin-bottom: 0.5em;
279 margin-top: 1.5em;
280 }
281 .class, .enumeration, .function, .struct, .typedef, .union {
282 border-bottom: solid thin #999999;
283 margin-bottom: 0;
284 margin-top: 2em;
285 }
286 .description {
287 margin-top: 0.5em;
288 }
289 code, p.code, pre, ul.code li {
290 font-family: monaco, courier, monospace;
291 font-size: 90%;
292 }
293 ul.code, ul.contents, ul.subcontents {
294 list-style-type: none;
295 margin: 0;
296 padding-left: 0;
297 }
298 ul.code li {
299 margin: 0;
300 }
301 ul.contents > li {
302 margin-top: 1em;
303 }
304 ul.contents li ul.code, ul.contents li ul.subcontents {
305 padding-left: 2em;
306 }
307 div.body dl {
308 margin-left: 0;
309 margin-top: 0;
310 }
311 div.body dt {
312 font-style: italic;
313 margin-left: 0;
314 margin-top: 0;
315 }
316 div.body dd {
317 margin-bottom: 0.5em;
318 }
319
320 /* This is just for the HTML files generated with the framedhelp target */
321 div.contents {
322 background: #e8e8e8;
323 border: solid thin black;
324 padding: 10px;
325 }
326 div.contents h1 {
327 font-size: 110%;
328 }
329 div.contents h2 {
330 font-size: 100%;
331 }
332 div.contents ul.contents {
333 font-size: 80%;
334 }
335 div.contents ul.subcontents li {
336 margin-left: 1em;
337 text-indent: -1em;
338 }
339 --></style>
340 </head>
341 <body>
342 <div class='body'>
343 <!--
344 "$Id: api-array.header 8087 2008-10-27 21:37:05Z mike $"
345
346 PPD Compiler API header for CUPS.
347
348 Copyright 2009 by Apple Inc.
349
350 These coded instructions, statements, and computer programs are the
351 property of Apple Inc. and are protected by Federal copyright
352 law. Distribution and use rights are outlined in the file "LICENSE.txt"
353 which should have been included with this file. If this file is
354 file is missing or damaged, see the license at "http://www.cups.org/".
355 -->
356
357 <h1 class='title'>PPD Compiler API</h1>
358
359 <div class='summary'><table summary='General Information'>
360 <thead>
361 <tr>
362 <th>Header</th>
363 <th>cups/ppdc.h</th>
364 </tr>
365 </thead>
366 <tbody>
367 <tr>
368 <th>Library</th>
369 <td>-lcupsppdc</td>
370 </tr>
371 <tr>
372 <th>See Also</th>
373 <td>Programming: <a href='api-overview.html' target='_top'>Introduction to CUPS Programming</a></td>
374 </tr>
375 </tbody>
376 </table></div>
377 <h2 class="title">Contents</h2>
378 <ul class="contents">
379 <li><a href="#OVERVIEW">Overview</a></li>
380 <li><a href="#CLASSES">Classes</a><ul class="code">
381 <li><a href="#ppdcArray" title="// Shared Array">ppdcArray</a></li>
382 <li><a href="#ppdcAttr" title="// Attribute">ppdcAttr</a></li>
383 <li><a href="#ppdcCatalog" title="// Translation catalog">ppdcCatalog</a></li>
384 <li><a href="#ppdcChoice" title="// Option Choice">ppdcChoice</a></li>
385 <li><a href="#ppdcConstraint" title="// Constraint">ppdcConstraint</a></li>
386 <li><a href="#ppdcDriver" title="// Printer Driver Data">ppdcDriver</a></li>
387 <li><a href="#ppdcFile" title="// File">ppdcFile</a></li>
388 <li><a href="#ppdcFilter" title="// Filter Program">ppdcFilter</a></li>
389 <li><a href="#ppdcFont" title="// Shared Font">ppdcFont</a></li>
390 <li><a href="#ppdcGroup" title="// Group of Options">ppdcGroup</a></li>
391 <li><a href="#ppdcInteger" title="// Shared integer">ppdcInteger</a></li>
392 <li><a href="#ppdcMediaSize" title="// Media Size">ppdcMediaSize</a></li>
393 <li><a href="#ppdcMessage" title="// Translation message">ppdcMessage</a></li>
394 <li><a href="#ppdcOption" title="// Option">ppdcOption</a></li>
395 <li><a href="#ppdcProfile" title="// Color Profile">ppdcProfile</a></li>
396 <li><a href="#ppdcShared" title="// Shared Data Value">ppdcShared</a></li>
397 <li><a href="#ppdcSource" title="// Source File">ppdcSource</a></li>
398 <li><a href="#ppdcString" title="// Shared String">ppdcString</a></li>
399 <li><a href="#ppdcVariable" title="// Variable Definition">ppdcVariable</a></li>
400 </ul></li>
401 <li><a href="#TYPES">Data Types</a><ul class="code">
402 <li><a href="#ppdc_cs_t" title="">ppdc_cs_t</a></li>
403 </ul></li>
404 <li><a href="#VARIABLES">Variables</a><ul class="code">
405 <li><a href="#ppdcSource" title="// Printer Driver Data">ppdcSource</a></li>
406 </ul></li>
407 <li><a href="#ENUMERATIONS">Constants</a><ul class="code">
408 <li><a href="#ppdcCondFlags" title="// Condition flags">ppdcCondFlags</a></li>
409 <li><a href="#ppdcDrvType" title="// Driver type">ppdcDrvType</a></li>
410 <li><a href="#ppdcFontStatus" title="// Load status of font">ppdcFontStatus</a></li>
411 <li><a href="#ppdcLineEnding" title="// Line endings">ppdcLineEnding</a></li>
412 <li><a href="#ppdcOptSection" title="// Option section">ppdcOptSection</a></li>
413 <li><a href="#ppdcOptType" title="// Option type">ppdcOptType</a></li>
414 </ul></li>
415 </ul>
416 <!--
417 "$Id: api-array.shtml 7616 2008-05-28 00:34:13Z mike $"
418
419 PPD Compiler API introduction for CUPS.
420
421 Copyright 2009 by Apple Inc.
422
423 These coded instructions, statements, and computer programs are the
424 property of Apple Inc. and are protected by Federal copyright
425 law. Distribution and use rights are outlined in the file "LICENSE.txt"
426 which should have been included with this file. If this file is
427 file is missing or damaged, see the license at "http://www.cups.org/".
428 -->
429
430 <h2 class='title'><a name='OVERVIEW'>Overview</a></h2>
431
432 <p>The PPD Compiler API provides access to CUPS driver information files and
433 methods for generating and importing PPD files.</p>
434 <h2 class="title"><a name="CLASSES">Classes</a></h2>
435 <h3 class="class"><a name="ppdcArray">ppdcArray</a></h3>
436 <p class="description">// Shared Array</p>
437 <p class="code">class ppdcArray : public ppdcShared {<br>
438 &nbsp;&nbsp;public:<br>
439 &nbsp;&nbsp;&nbsp;&nbsp;int count, alloc, current;<br>
440 &nbsp;&nbsp;&nbsp;&nbsp;<a href="#ppdcShared">ppdcShared</a> **data;<br>
441 };</p>
442 <h4 class="members">Members</h4>
443 <dl>
444 <dt>current </dt>
445 <dd class="description">Current element</dd>
446 <dt>data </dt>
447 <dd class="description">Elements</dd>
448 </dl>
449 <h4 class="method"><a name="PPDC_NAME">PPDC_NAME</a></h4>
450 <p class="description"></p>
451 <p class="code">
452 void PPDC_NAME (<br>
453 &nbsp;&nbsp;&nbsp;&nbsp;void add(<a href="#ppdcShared">ppdcShared</a> *d<br>
454 );</p>
455 <h5 class="parameters">Parameters</h5>
456 <dl>
457 <dt>d</dt>
458 </dl>
459 <h4 class="method"><a name="add">add</a></h4>
460 <p class="description"></p>
461 <p class="code">
462 void add (<br>
463 &nbsp;&nbsp;&nbsp;&nbsp;<a href="#ppdcShared">ppdcShared</a> *d<br>
464 );</p>
465 <h5 class="parameters">Parameters</h5>
466 <dl>
467 <dt>d</dt>
468 </dl>
469 <h4 class="method"><a name="first">first</a></h4>
470 <p class="description">Return the first element in the array.</p>
471 <p class="code">
472 <a href="#ppdcShared">ppdcShared</a> *first (void);</p>
473 <h5 class="returnvalue">Return Value</h5>
474 <p class="description"></p>
475 <h4 class="method"><a name="next">next</a></h4>
476 <p class="description">Return the next element in the array.</p>
477 <p class="code">
478 <a href="#ppdcShared">ppdcShared</a> *next (void);</p>
479 <h5 class="returnvalue">Return Value</h5>
480 <p class="description"></p>
481 <h4 class="method"><a name="ppdcArray">ppdcArray</a></h4>
482 <p class="description"></p>
483 <p class="code">
484 void ppdcArray (<br>
485 &nbsp;&nbsp;&nbsp;&nbsp;<a href="#ppdcArray">ppdcArray</a> *a<br>
486 );</p>
487 <h5 class="parameters">Parameters</h5>
488 <dl>
489 <dt>a</dt>
490 </dl>
491 <h4 class="method"><a name="remove">remove</a></h4>
492 <p class="description"></p>
493 <p class="code">
494 void remove (<br>
495 &nbsp;&nbsp;&nbsp;&nbsp;<a href="#ppdcShared">ppdcShared</a> *d<br>
496 );</p>
497 <h5 class="parameters">Parameters</h5>
498 <dl>
499 <dt>d</dt>
500 <dd class="description">Data element</dd>
501 </dl>
502 <h4 class="method"><a name="~ppdcArray">~ppdcArray</a></h4>
503 <p class="description"></p>
504 <p class="code">
505 void ~ppdcArray (void);</p>
506 <h3 class="class"><a name="ppdcAttr">ppdcAttr</a></h3>
507 <p class="description">// Attribute</p>
508 <p class="code">class ppdcAttr : public ppdcShared {<br>
509 &nbsp;&nbsp;public:<br>
510 &nbsp;&nbsp;&nbsp;&nbsp;bool localizable;<br>
511 &nbsp;&nbsp;&nbsp;&nbsp;<a href="#ppdcString">ppdcString</a> *name, *selector, *text, *value;<br>
512 };</p>
513 <h4 class="members">Members</h4>
514 <dl>
515 <dt>localizable </dt>
516 <dd class="description">Should this attribute be localized?</dd>
517 <dt>value </dt>
518 <dd class="description">Value string</dd>
519 </dl>
520 <h4 class="method"><a name="ppdcAttr">ppdcAttr</a></h4>
521 <p class="description"></p>
522 <p class="code">
523 void ppdcAttr (<br>
524 &nbsp;&nbsp;&nbsp;&nbsp;const char *n,<br>
525 &nbsp;&nbsp;&nbsp;&nbsp;const char *s,<br>
526 &nbsp;&nbsp;&nbsp;&nbsp;const char *t,<br>
527 &nbsp;&nbsp;&nbsp;&nbsp;const char *v,<br>
528 &nbsp;&nbsp;&nbsp;&nbsp;bool loc<br>
529 );</p>
530 <h5 class="parameters">Parameters</h5>
531 <dl>
532 <dt>n</dt>
533 <dd class="description">Name</dd>
534 <dt>s</dt>
535 <dd class="description">Spec string</dd>
536 <dt>t</dt>
537 <dd class="description">Human-readable text</dd>
538 <dt>v</dt>
539 <dd class="description">Value</dd>
540 <dt>loc</dt>
541 <dd class="description">Localize this attribute?</dd>
542 </dl>
543 <h4 class="method"><a name="~ppdcAttr">~ppdcAttr</a></h4>
544 <p class="description"></p>
545 <p class="code">
546 void ~ppdcAttr (void);</p>
547 <h3 class="class"><a name="ppdcCatalog">ppdcCatalog</a></h3>
548 <p class="description">// Translation catalog</p>
549 <p class="code">class ppdcCatalog : public ppdcShared {<br>
550 &nbsp;&nbsp;public:<br>
551 &nbsp;&nbsp;&nbsp;&nbsp;<a href="#ppdcString">ppdcString</a> *filename;<br>
552 &nbsp;&nbsp;&nbsp;&nbsp;<a href="#ppdcString">ppdcString</a> *locale;<br>
553 &nbsp;&nbsp;&nbsp;&nbsp;<a href="#ppdcArray">ppdcArray</a> *messages;<br>
554 };</p>
555 <h4 class="members">Members</h4>
556 <dl>
557 <dt>filename </dt>
558 <dd class="description">Name of translation file</dd>
559 <dt>locale </dt>
560 <dd class="description">Name of locale</dd>
561 <dt>messages </dt>
562 <dd class="description">Array of translation messages</dd>
563 </dl>
564 <h4 class="method"><a name="PPDC_NAME">PPDC_NAME</a></h4>
565 <p class="description"></p>
566 <p class="code">
567 void PPDC_NAME (<br>
568 &nbsp;&nbsp;&nbsp;&nbsp;void add_message(const char *id,<br>
569 &nbsp;&nbsp;&nbsp;&nbsp;const char *string = NULL<br>
570 );</p>
571 <h5 class="parameters">Parameters</h5>
572 <dl>
573 <dt>id</dt>
574 <dt>string</dt>
575 </dl>
576 <h4 class="method"><a name="add_message">add_message</a></h4>
577 <p class="description"></p>
578 <p class="code">
579 void add_message (<br>
580 &nbsp;&nbsp;&nbsp;&nbsp;const char *id,<br>
581 &nbsp;&nbsp;&nbsp;&nbsp;const char *string<br>
582 );</p>
583 <h5 class="parameters">Parameters</h5>
584 <dl>
585 <dt>id</dt>
586 <dd class="description">Message ID to add</dd>
587 <dt>string</dt>
588 <dd class="description">Translation string</dd>
589 </dl>
590 <h4 class="method"><a name="find_message">find_message</a></h4>
591 <p class="description"></p>
592 <p class="code">
593 const char *find_message (<br>
594 &nbsp;&nbsp;&nbsp;&nbsp;const char *id<br>
595 );</p>
596 <h5 class="parameters">Parameters</h5>
597 <dl>
598 <dt>id</dt>
599 <dd class="description">Message ID</dd>
600 </dl>
601 <h5 class="returnvalue">Return Value</h5>
602 <p class="description">Message text</p>
603 <h4 class="method"><a name="load_messages">load_messages</a></h4>
604 <p class="description"></p>
605 <p class="code">
606 int load_messages (<br>
607 &nbsp;&nbsp;&nbsp;&nbsp;const char *f<br>
608 );</p>
609 <h5 class="parameters">Parameters</h5>
610 <dl>
611 <dt>f</dt>
612 <dd class="description">Message catalog file</dd>
613 </dl>
614 <h5 class="returnvalue">Return Value</h5>
615 <p class="description">0 on success, -1 on failure</p>
616 <h4 class="method"><a name="ppdcCatalog">ppdcCatalog</a></h4>
617 <p class="description"></p>
618 <p class="code">
619 void ppdcCatalog (<br>
620 &nbsp;&nbsp;&nbsp;&nbsp;const char *l,<br>
621 &nbsp;&nbsp;&nbsp;&nbsp;const char *f<br>
622 );</p>
623 <h5 class="parameters">Parameters</h5>
624 <dl>
625 <dt>l</dt>
626 <dd class="description">Locale</dd>
627 <dt>f</dt>
628 <dd class="description">Message catalog file</dd>
629 </dl>
630 <h4 class="method"><a name="save_messages">save_messages</a></h4>
631 <p class="description"></p>
632 <p class="code">
633 int save_messages (<br>
634 &nbsp;&nbsp;&nbsp;&nbsp;const char *f<br>
635 );</p>
636 <h5 class="parameters">Parameters</h5>
637 <dl>
638 <dt>f</dt>
639 <dd class="description">File to save to</dd>
640 </dl>
641 <h5 class="returnvalue">Return Value</h5>
642 <p class="description">0 on success, -1 on error</p>
643 <h4 class="method"><a name="~ppdcCatalog">~ppdcCatalog</a></h4>
644 <p class="description"></p>
645 <p class="code">
646 void ~ppdcCatalog (void);</p>
647 <h3 class="class"><a name="ppdcChoice">ppdcChoice</a></h3>
648 <p class="description">// Option Choice</p>
649 <p class="code">class ppdcChoice : public ppdcShared {<br>
650 &nbsp;&nbsp;public:<br>
651 &nbsp;&nbsp;&nbsp;&nbsp;<a href="#ppdcString">ppdcString</a> *name, *text, *code;<br>
652 };</p>
653 <h4 class="members">Members</h4>
654 <dl>
655 <dt>code </dt>
656 <dd class="description">PS code of choice</dd>
657 </dl>
658 <h4 class="method"><a name="ppdcChoice">ppdcChoice</a></h4>
659 <p class="description"></p>
660 <p class="code">
661 void ppdcChoice (<br>
662 &nbsp;&nbsp;&nbsp;&nbsp;const char *n,<br>
663 &nbsp;&nbsp;&nbsp;&nbsp;const char *t,<br>
664 &nbsp;&nbsp;&nbsp;&nbsp;const char *c<br>
665 );</p>
666 <h5 class="parameters">Parameters</h5>
667 <dl>
668 <dt>n</dt>
669 <dd class="description">Name of choice</dd>
670 <dt>t</dt>
671 <dd class="description">Text of choice</dd>
672 <dt>c</dt>
673 <dd class="description">Code of choice</dd>
674 </dl>
675 <h4 class="method"><a name="~ppdcChoice">~ppdcChoice</a></h4>
676 <p class="description"></p>
677 <p class="code">
678 void ~ppdcChoice (void);</p>
679 <h3 class="class"><a name="ppdcConstraint">ppdcConstraint</a></h3>
680 <p class="description">// Constraint</p>
681 <p class="code">class ppdcConstraint : public ppdcShared {<br>
682 &nbsp;&nbsp;public:<br>
683 &nbsp;&nbsp;&nbsp;&nbsp;<a href="#ppdcString">ppdcString</a> *option1, *choice1, *option2, *choice2;<br>
684 };</p>
685 <h4 class="members">Members</h4>
686 <dl>
687 <dt>choice2 </dt>
688 <dd class="description">Second choice</dd>
689 </dl>
690 <h4 class="method"><a name="ppdcConstraint">ppdcConstraint</a></h4>
691 <p class="description"></p>
692 <p class="code">
693 void ppdcConstraint (<br>
694 &nbsp;&nbsp;&nbsp;&nbsp;const char *o1,<br>
695 &nbsp;&nbsp;&nbsp;&nbsp;const char *c1,<br>
696 &nbsp;&nbsp;&nbsp;&nbsp;const char *o2,<br>
697 &nbsp;&nbsp;&nbsp;&nbsp;const char *c2<br>
698 );</p>
699 <h5 class="parameters">Parameters</h5>
700 <dl>
701 <dt>o1</dt>
702 <dd class="description">First option</dd>
703 <dt>c1</dt>
704 <dd class="description">First choice</dd>
705 <dt>o2</dt>
706 <dd class="description">Second option</dd>
707 <dt>c2</dt>
708 <dd class="description">Second choice</dd>
709 </dl>
710 <h4 class="method"><a name="~ppdcConstraint">~ppdcConstraint</a></h4>
711 <p class="description"></p>
712 <p class="code">
713 void ~ppdcConstraint (void);</p>
714 <h3 class="class"><a name="ppdcDriver">ppdcDriver</a></h3>
715 <p class="description">// Printer Driver Data</p>
716 <p class="code">class ppdcDriver : public ppdcShared {<br>
717 &nbsp;&nbsp;public:<br>
718 &nbsp;&nbsp;&nbsp;&nbsp;<a href="#ppdcArray">ppdcArray</a> *copyright;<br>
719 &nbsp;&nbsp;&nbsp;&nbsp;<a href="#ppdcString">ppdcString</a> *custom_size_code;<br>
720 &nbsp;&nbsp;&nbsp;&nbsp;<a href="#ppdcString">ppdcString</a> *default_font, *default_size;<br>
721 &nbsp;&nbsp;&nbsp;&nbsp;float left_margin, bottom_margin, right_margin, top_margin, max_width, max_length, min_width, min_length;<br>
722 &nbsp;&nbsp;&nbsp;&nbsp;<a href="#ppdcArray">ppdcArray</a> *attrs, *constraints, *filters, *fonts, *groups, *profiles, *sizes;<br>
723 &nbsp;&nbsp;&nbsp;&nbsp;int model_number, manual_copies, color_device, throughput;<br>
724 &nbsp;&nbsp;&nbsp;&nbsp;<a href="#ppdcDrvType">ppdcDrvType</a> type;<br>
725 &nbsp;&nbsp;&nbsp;&nbsp;int variable_paper_size;<br>
726 &nbsp;&nbsp;&nbsp;&nbsp;<a href="#ppdcString">ppdcString</a> *manufacturer, *model_name, *file_name, *pc_file_name, *version;<br>
727 };</p>
728 <h4 class="members">Members</h4>
729 <dl>
730 <dt>copyright </dt>
731 <dd class="description">Copyright strings</dd>
732 <dt>custom_size_code </dt>
733 <dd class="description">Custom page size code, if any</dd>
734 <dt>default_size </dt>
735 <dd class="description">Default size option</dd>
736 <dt>min_length </dt>
737 <dd class="description">Minimum length (points)</dd>
738 <dt>sizes </dt>
739 <dd class="description">Fixed sizes</dd>
740 <dt>throughput </dt>
741 <dd class="description">Throughput in pages per minute</dd>
742 <dt>type </dt>
743 <dd class="description">Driver type</dd>
744 <dt>variable_paper_size </dt>
745 <dd class="description">Support variable sizes?</dd>
746 <dt>version </dt>
747 <dd class="description">Version number</dd>
748 </dl>
749 <h4 class="method"><a name="PPDC_NAME">PPDC_NAME</a></h4>
750 <p class="description"></p>
751 <p class="code">
752 void PPDC_NAME (<br>
753 &nbsp;&nbsp;&nbsp;&nbsp;void add_attr(<a href="#ppdcAttr">ppdcAttr</a> *a<br>
754 );</p>
755 <h5 class="parameters">Parameters</h5>
756 <dl>
757 <dt>a</dt>
758 </dl>
759 <h4 class="method"><a name="add_constraint">add_constraint</a></h4>
760 <p class="description"></p>
761 <p class="code">
762 void add_constraint (<br>
763 &nbsp;&nbsp;&nbsp;&nbsp;<a href="#ppdcConstraint">ppdcConstraint</a> *c<br>
764 );</p>
765 <h5 class="parameters">Parameters</h5>
766 <dl>
767 <dt>c</dt>
768 </dl>
769 <h4 class="method"><a name="add_copyright">add_copyright</a></h4>
770 <p class="description"></p>
771 <p class="code">
772 void add_copyright (<br>
773 &nbsp;&nbsp;&nbsp;&nbsp;const char *c<br>
774 );</p>
775 <h5 class="parameters">Parameters</h5>
776 <dl>
777 <dt>c</dt>
778 </dl>
779 <h4 class="method"><a name="add_filter">add_filter</a></h4>
780 <p class="description"></p>
781 <p class="code">
782 void add_filter (<br>
783 &nbsp;&nbsp;&nbsp;&nbsp;<a href="#ppdcFilter">ppdcFilter</a> *f<br>
784 );</p>
785 <h5 class="parameters">Parameters</h5>
786 <dl>
787 <dt>f</dt>
788 </dl>
789 <h4 class="method"><a name="add_font">add_font</a></h4>
790 <p class="description"></p>
791 <p class="code">
792 void add_font (<br>
793 &nbsp;&nbsp;&nbsp;&nbsp;<a href="#ppdcFont">ppdcFont</a> *f<br>
794 );</p>
795 <h5 class="parameters">Parameters</h5>
796 <dl>
797 <dt>f</dt>
798 </dl>
799 <h4 class="method"><a name="add_group">add_group</a></h4>
800 <p class="description"></p>
801 <p class="code">
802 void add_group (<br>
803 &nbsp;&nbsp;&nbsp;&nbsp;<a href="#ppdcGroup">ppdcGroup</a> *g<br>
804 );</p>
805 <h5 class="parameters">Parameters</h5>
806 <dl>
807 <dt>g</dt>
808 </dl>
809 <h4 class="method"><a name="add_profile">add_profile</a></h4>
810 <p class="description"></p>
811 <p class="code">
812 void add_profile (<br>
813 &nbsp;&nbsp;&nbsp;&nbsp;<a href="#ppdcProfile">ppdcProfile</a> *p<br>
814 );</p>
815 <h5 class="parameters">Parameters</h5>
816 <dl>
817 <dt>p</dt>
818 </dl>
819 <h4 class="method"><a name="add_size">add_size</a></h4>
820 <p class="description"></p>
821 <p class="code">
822 void add_size (<br>
823 &nbsp;&nbsp;&nbsp;&nbsp;<a href="#ppdcMediaSize">ppdcMediaSize</a> *m<br>
824 );</p>
825 <h5 class="parameters">Parameters</h5>
826 <dl>
827 <dt>m</dt>
828 </dl>
829 <h4 class="method"><a name="find_attr">find_attr</a></h4>
830 <p class="description"></p>
831 <p class="code">
832 <a href="#ppdcAttr">ppdcAttr</a> *find_attr (<br>
833 &nbsp;&nbsp;&nbsp;&nbsp;const char *k,<br>
834 &nbsp;&nbsp;&nbsp;&nbsp;const char *s<br>
835 );</p>
836 <h5 class="parameters">Parameters</h5>
837 <dl>
838 <dt>k</dt>
839 <dd class="description">Keyword string</dd>
840 <dt>s</dt>
841 <dd class="description">Spec string</dd>
842 </dl>
843 <h5 class="returnvalue">Return Value</h5>
844 <p class="description">Attribute or NULL</p>
845 <h4 class="method"><a name="find_group">find_group</a></h4>
846 <p class="description"></p>
847 <p class="code">
848 <a href="#ppdcGroup">ppdcGroup</a> *find_group (<br>
849 &nbsp;&nbsp;&nbsp;&nbsp;const char *n<br>
850 );</p>
851 <h5 class="parameters">Parameters</h5>
852 <dl>
853 <dt>n</dt>
854 <dd class="description">Group name</dd>
855 </dl>
856 <h5 class="returnvalue">Return Value</h5>
857 <p class="description">Matching group or NULL</p>
858 <h4 class="method"><a name="find_option">find_option</a></h4>
859 <p class="description"></p>
860 <p class="code">
861 <a href="#ppdcOption">ppdcOption</a> *find_option (<br>
862 &nbsp;&nbsp;&nbsp;&nbsp;const char *n<br>
863 );</p>
864 <h5 class="parameters">Parameters</h5>
865 <dl>
866 <dt>n</dt>
867 <dd class="description">Option name</dd>
868 </dl>
869 <h5 class="returnvalue">Return Value</h5>
870 <p class="description">Matching option or NULL</p>
871 <h4 class="method"><a name="find_option_group">find_option_group</a></h4>
872 <p class="description"></p>
873 <p class="code">
874 <a href="#ppdcOption">ppdcOption</a> *find_option_group (<br>
875 &nbsp;&nbsp;&nbsp;&nbsp;const char *n,<br>
876 &nbsp;&nbsp;&nbsp;&nbsp;<a href="#ppdcGroup">ppdcGroup</a> **mg<br>
877 );</p>
878 <h5 class="parameters">Parameters</h5>
879 <dl>
880 <dt>n</dt>
881 <dd class="description">Option name</dd>
882 <dt>mg</dt>
883 <dd class="description">Matching group or NULL</dd>
884 </dl>
885 <h5 class="returnvalue">Return Value</h5>
886 <p class="description">Matching option or NULL</p>
887 <h4 class="method"><a name="ppdcDriver">ppdcDriver</a></h4>
888 <p class="description"></p>
889 <p class="code">
890 void ppdcDriver (<br>
891 &nbsp;&nbsp;&nbsp;&nbsp;<a href="#ppdcDriver">ppdcDriver</a> *d<br>
892 );</p>
893 <h5 class="parameters">Parameters</h5>
894 <dl>
895 <dt>d</dt>
896 <dd class="description">Printer driver template</dd>
897 </dl>
898 <h4 class="method"><a name="set_custom_size_code">set_custom_size_code</a></h4>
899 <p class="description"></p>
900 <p class="code">
901 void set_custom_size_code (<br>
902 &nbsp;&nbsp;&nbsp;&nbsp;const char *c<br>
903 );</p>
904 <h5 class="parameters">Parameters</h5>
905 <dl>
906 <dt>c</dt>
907 <dd class="description">CustomPageSize code</dd>
908 </dl>
909 <h4 class="method"><a name="set_default_font">set_default_font</a></h4>
910 <p class="description"></p>
911 <p class="code">
912 void set_default_font (<br>
913 &nbsp;&nbsp;&nbsp;&nbsp;<a href="#ppdcFont">ppdcFont</a> *f<br>
914 );</p>
915 <h5 class="parameters">Parameters</h5>
916 <dl>
917 <dt>f</dt>
918 <dd class="description">Font</dd>
919 </dl>
920 <h4 class="method"><a name="set_default_size">set_default_size</a></h4>
921 <p class="description"></p>
922 <p class="code">
923 void set_default_size (<br>
924 &nbsp;&nbsp;&nbsp;&nbsp;<a href="#ppdcMediaSize">ppdcMediaSize</a> *m<br>
925 );</p>
926 <h5 class="parameters">Parameters</h5>
927 <dl>
928 <dt>m</dt>
929 <dd class="description">Media size</dd>
930 </dl>
931 <h4 class="method"><a name="set_file_name">set_file_name</a></h4>
932 <p class="description"></p>
933 <p class="code">
934 void set_file_name (<br>
935 &nbsp;&nbsp;&nbsp;&nbsp;const char *f<br>
936 );</p>
937 <h5 class="parameters">Parameters</h5>
938 <dl>
939 <dt>f</dt>
940 <dd class="description">Filename</dd>
941 </dl>
942 <h4 class="method"><a name="set_manufacturer">set_manufacturer</a></h4>
943 <p class="description"></p>
944 <p class="code">
945 void set_manufacturer (<br>
946 &nbsp;&nbsp;&nbsp;&nbsp;const char *m<br>
947 );</p>
948 <h5 class="parameters">Parameters</h5>
949 <dl>
950 <dt>m</dt>
951 <dd class="description">Model name</dd>
952 </dl>
953 <h4 class="method"><a name="set_model_name">set_model_name</a></h4>
954 <p class="description"></p>
955 <p class="code">
956 void set_model_name (<br>
957 &nbsp;&nbsp;&nbsp;&nbsp;const char *m<br>
958 );</p>
959 <h5 class="parameters">Parameters</h5>
960 <dl>
961 <dt>m</dt>
962 <dd class="description">Model name</dd>
963 </dl>
964 <h4 class="method"><a name="set_pc_file_name">set_pc_file_name</a></h4>
965 <p class="description"></p>
966 <p class="code">
967 void set_pc_file_name (<br>
968 &nbsp;&nbsp;&nbsp;&nbsp;const char *f<br>
969 );</p>
970 <h5 class="parameters">Parameters</h5>
971 <dl>
972 <dt>f</dt>
973 <dd class="description">Filename</dd>
974 </dl>
975 <h4 class="method"><a name="set_version">set_version</a></h4>
976 <p class="description"></p>
977 <p class="code">
978 void set_version (<br>
979 &nbsp;&nbsp;&nbsp;&nbsp;const char *v<br>
980 );</p>
981 <h5 class="parameters">Parameters</h5>
982 <dl>
983 <dt>v</dt>
984 <dd class="description">Version</dd>
985 </dl>
986 <h4 class="method"><a name="write_ppd_file">write_ppd_file</a></h4>
987 <p class="description"></p>
988 <p class="code">
989 int write_ppd_file (<br>
990 &nbsp;&nbsp;&nbsp;&nbsp;cups_file_t *fp,<br>
991 &nbsp;&nbsp;&nbsp;&nbsp;<a href="#ppdcCatalog">ppdcCatalog</a> *catalog,<br>
992 &nbsp;&nbsp;&nbsp;&nbsp;<a href="#ppdcArray">ppdcArray</a> *locales,<br>
993 &nbsp;&nbsp;&nbsp;&nbsp;<a href="#ppdcSource">ppdcSource</a> *src,<br>
994 &nbsp;&nbsp;&nbsp;&nbsp;<a href="#ppdcLineEnding">ppdcLineEnding</a> le<br>
995 );</p>
996 <h5 class="parameters">Parameters</h5>
997 <dl>
998 <dt>fp</dt>
999 <dd class="description">PPD file</dd>
1000 <dt>catalog</dt>
1001 <dd class="description">Message catalog</dd>
1002 <dt>locales</dt>
1003 <dd class="description">Additional languages to add</dd>
1004 <dt>src</dt>
1005 <dd class="description">Driver source</dd>
1006 <dt>le</dt>
1007 <dd class="description">Line endings to use</dd>
1008 </dl>
1009 <h5 class="returnvalue">Return Value</h5>
1010 <p class="description">0 on success, -1 on failure</p>
1011 <h4 class="method"><a name="~ppdcDriver">~ppdcDriver</a></h4>
1012 <p class="description"></p>
1013 <p class="code">
1014 void ~ppdcDriver (void);</p>
1015 <h3 class="class"><a name="ppdcFile">ppdcFile</a></h3>
1016 <p class="description">// File</p>
1017 <p class="code">class ppdcFile {<br>
1018 &nbsp;&nbsp;public:<br>
1019 &nbsp;&nbsp;&nbsp;&nbsp;bool close_on_delete;<br>
1020 &nbsp;&nbsp;&nbsp;&nbsp;const char *filename;<br>
1021 &nbsp;&nbsp;&nbsp;&nbsp;cups_file_t *fp;<br>
1022 &nbsp;&nbsp;&nbsp;&nbsp;int line;<br>
1023 };</p>
1024 <h4 class="members">Members</h4>
1025 <dl>
1026 <dt>close_on_delete </dt>
1027 <dd class="description">Close file on delete?</dd>
1028 <dt>filename </dt>
1029 <dd class="description">Filename</dd>
1030 <dt>fp </dt>
1031 <dd class="description">File pointer</dd>
1032 <dt>line </dt>
1033 <dd class="description">Line in file</dd>
1034 </dl>
1035 <h4 class="method"><a name="get">get</a></h4>
1036 <p class="description">Get a character from a file.</p>
1037 <p class="code">
1038 int get (void);</p>
1039 <h5 class="returnvalue">Return Value</h5>
1040 <p class="description"></p>
1041 <h4 class="method"><a name="peek">peek</a></h4>
1042 <p class="description"></p>
1043 <p class="code">
1044 int peek (void);</p>
1045 <h5 class="returnvalue">Return Value</h5>
1046 <p class="description">Next character in file</p>
1047 <h4 class="method"><a name="ppdcFile">ppdcFile</a></h4>
1048 <p class="description"></p>
1049 <p class="code">
1050 void ppdcFile (<br>
1051 &nbsp;&nbsp;&nbsp;&nbsp;const char *f,<br>
1052 &nbsp;&nbsp;&nbsp;&nbsp;cups_file_t *ffp<br>
1053 );</p>
1054 <h5 class="parameters">Parameters</h5>
1055 <dl>
1056 <dt>f</dt>
1057 <dd class="description">File to open</dd>
1058 <dt>ffp</dt>
1059 <dd class="description">File pointer to use</dd>
1060 </dl>
1061 <h4 class="method"><a name="~ppdcFile">~ppdcFile</a></h4>
1062 <p class="description"></p>
1063 <p class="code">
1064 void ~ppdcFile (void);</p>
1065 <h3 class="class"><a name="ppdcFilter">ppdcFilter</a></h3>
1066 <p class="description">// Filter Program</p>
1067 <p class="code">class ppdcFilter : public ppdcShared {<br>
1068 &nbsp;&nbsp;public:<br>
1069 &nbsp;&nbsp;&nbsp;&nbsp;int cost;<br>
1070 &nbsp;&nbsp;&nbsp;&nbsp;<a href="#ppdcString">ppdcString</a> *mime_type, *program;<br>
1071 };</p>
1072 <h4 class="members">Members</h4>
1073 <dl>
1074 <dt>cost </dt>
1075 <dd class="description">Relative cost of filter</dd>
1076 <dt>program </dt>
1077 <dd class="description">Filter program</dd>
1078 </dl>
1079 <h4 class="method"><a name="ppdcFilter">ppdcFilter</a></h4>
1080 <p class="description"></p>
1081 <p class="code">
1082 void ppdcFilter (<br>
1083 &nbsp;&nbsp;&nbsp;&nbsp;const char *t,<br>
1084 &nbsp;&nbsp;&nbsp;&nbsp;const char *p,<br>
1085 &nbsp;&nbsp;&nbsp;&nbsp;int c<br>
1086 );</p>
1087 <h5 class="parameters">Parameters</h5>
1088 <dl>
1089 <dt>t</dt>
1090 <dd class="description">MIME type</dd>
1091 <dt>p</dt>
1092 <dd class="description">Filter program</dd>
1093 <dt>c</dt>
1094 <dd class="description">Relative cost</dd>
1095 </dl>
1096 <h4 class="method"><a name="~ppdcFilter">~ppdcFilter</a></h4>
1097 <p class="description"></p>
1098 <p class="code">
1099 void ~ppdcFilter (void);</p>
1100 <h3 class="class"><a name="ppdcFont">ppdcFont</a></h3>
1101 <p class="description">// Shared Font</p>
1102 <p class="code">class ppdcFont : public ppdcShared {<br>
1103 &nbsp;&nbsp;public:<br>
1104 &nbsp;&nbsp;&nbsp;&nbsp;<a href="#ppdcString">ppdcString</a> *name, *encoding, *version, *charset;<br>
1105 &nbsp;&nbsp;&nbsp;&nbsp;<a href="#ppdcFontStatus">ppdcFontStatus</a> status;<br>
1106 };</p>
1107 <h4 class="members">Members</h4>
1108 <dl>
1109 <dt>charset </dt>
1110 <dd class="description">Font charset</dd>
1111 <dt>status </dt>
1112 <dd class="description">Font status (ROM or Disk)</dd>
1113 </dl>
1114 <h4 class="method"><a name="ppdcFont">ppdcFont</a></h4>
1115 <p class="description"></p>
1116 <p class="code">
1117 void ppdcFont (<br>
1118 &nbsp;&nbsp;&nbsp;&nbsp;const char *n,<br>
1119 &nbsp;&nbsp;&nbsp;&nbsp;const char *e,<br>
1120 &nbsp;&nbsp;&nbsp;&nbsp;const char *v,<br>
1121 &nbsp;&nbsp;&nbsp;&nbsp;const char *c,<br>
1122 &nbsp;&nbsp;&nbsp;&nbsp;<a href="#ppdcFontStatus">ppdcFontStatus</a> s<br>
1123 );</p>
1124 <h5 class="parameters">Parameters</h5>
1125 <dl>
1126 <dt>n</dt>
1127 <dd class="description">Name of font</dd>
1128 <dt>e</dt>
1129 <dd class="description">Font encoding</dd>
1130 <dt>v</dt>
1131 <dd class="description">Font version</dd>
1132 <dt>c</dt>
1133 <dd class="description">Font charset</dd>
1134 <dt>s</dt>
1135 <dd class="description">Font status</dd>
1136 </dl>
1137 <h4 class="method"><a name="~ppdcFont">~ppdcFont</a></h4>
1138 <p class="description"></p>
1139 <p class="code">
1140 void ~ppdcFont (void);</p>
1141 <h3 class="class"><a name="ppdcGroup">ppdcGroup</a></h3>
1142 <p class="description">// Group of Options</p>
1143 <p class="code">class ppdcGroup : public ppdcShared {<br>
1144 &nbsp;&nbsp;public:<br>
1145 &nbsp;&nbsp;&nbsp;&nbsp;<a href="#ppdcArray">ppdcArray</a> *options;<br>
1146 &nbsp;&nbsp;&nbsp;&nbsp;<a href="#ppdcString">ppdcString</a> *name, *text;<br>
1147 };</p>
1148 <h4 class="members">Members</h4>
1149 <dl>
1150 <dt>options </dt>
1151 <dd class="description">Options</dd>
1152 <dt>text </dt>
1153 <dd class="description">Human-readable text of option</dd>
1154 </dl>
1155 <h4 class="method"><a name="PPDC_NAME">PPDC_NAME</a></h4>
1156 <p class="description"></p>
1157 <p class="code">
1158 void PPDC_NAME (<br>
1159 &nbsp;&nbsp;&nbsp;&nbsp;void add_option(<a href="#ppdcOption">ppdcOption</a> *o<br>
1160 );</p>
1161 <h5 class="parameters">Parameters</h5>
1162 <dl>
1163 <dt>o</dt>
1164 </dl>
1165 <h4 class="method"><a name="find_option">find_option</a></h4>
1166 <p class="description">Find an option in a group.</p>
1167 <p class="code">
1168 <a href="#ppdcOption">ppdcOption</a> *find_option (<br>
1169 &nbsp;&nbsp;&nbsp;&nbsp;const char *n<br>
1170 );</p>
1171 <h5 class="parameters">Parameters</h5>
1172 <dl>
1173 <dt>n</dt>
1174 <dd class="description">Name of option</dd>
1175 </dl>
1176 <h5 class="returnvalue">Return Value</h5>
1177 <p class="description"></p>
1178 <h4 class="method"><a name="ppdcGroup">ppdcGroup</a></h4>
1179 <p class="description"></p>
1180 <p class="code">
1181 void ppdcGroup (<br>
1182 &nbsp;&nbsp;&nbsp;&nbsp;<a href="#ppdcGroup">ppdcGroup</a> *g<br>
1183 );</p>
1184 <h5 class="parameters">Parameters</h5>
1185 <dl>
1186 <dt>g</dt>
1187 <dd class="description">Group template</dd>
1188 </dl>
1189 <h4 class="method"><a name="~ppdcGroup">~ppdcGroup</a></h4>
1190 <p class="description"></p>
1191 <p class="code">
1192 void ~ppdcGroup (void);</p>
1193 <h3 class="class"><a name="ppdcInteger">ppdcInteger</a></h3>
1194 <p class="description">// Shared integer</p>
1195 <p class="code">class ppdcInteger : public ppdcShared {<br>
1196 &nbsp;&nbsp;public:<br>
1197 &nbsp;&nbsp;&nbsp;&nbsp;int *value;<br>
1198 };</p>
1199 <h4 class="members">Members</h4>
1200 <dl>
1201 <dt>value </dt>
1202 <dd class="description">Integer value</dd>
1203 </dl>
1204 <h4 class="method"><a name="ppdcInteger">ppdcInteger</a></h4>
1205 <p class="description">Integer value</p>
1206 <p class="code">
1207 void ppdcInteger (<br>
1208 &nbsp;&nbsp;&nbsp;&nbsp;int *v<br>
1209 );</p>
1210 <h5 class="parameters">Parameters</h5>
1211 <dl>
1212 <dt>v</dt>
1213 </dl>
1214 <h3 class="class"><a name="ppdcMediaSize">ppdcMediaSize</a></h3>
1215 <p class="description">// Media Size</p>
1216 <p class="code">class ppdcMediaSize : public ppdcShared {<br>
1217 &nbsp;&nbsp;public:<br>
1218 &nbsp;&nbsp;&nbsp;&nbsp;<a href="#ppdcString">ppdcString</a> *size_code, *region_code;<br>
1219 &nbsp;&nbsp;&nbsp;&nbsp;<a href="#ppdcString">ppdcString</a> *name, *text;<br>
1220 &nbsp;&nbsp;&nbsp;&nbsp;float width, length, left, bottom, right, top;<br>
1221 };</p>
1222 <h4 class="members">Members</h4>
1223 <dl>
1224 <dt>region_code </dt>
1225 <dd class="description">PageRegion code, if any</dd>
1226 <dt>text </dt>
1227 <dd class="description">Human-readable text</dd>
1228 <dt>top </dt>
1229 <dd class="description">Top limit in points</dd>
1230 </dl>
1231 <h4 class="method"><a name="ppdcMediaSize">ppdcMediaSize</a></h4>
1232 <p class="description"></p>
1233 <p class="code">
1234 void ppdcMediaSize (<br>
1235 &nbsp;&nbsp;&nbsp;&nbsp;const char *n,<br>
1236 &nbsp;&nbsp;&nbsp;&nbsp;const char *t,<br>
1237 &nbsp;&nbsp;&nbsp;&nbsp;float w,<br>
1238 &nbsp;&nbsp;&nbsp;&nbsp;float l,<br>
1239 &nbsp;&nbsp;&nbsp;&nbsp;float lm,<br>
1240 &nbsp;&nbsp;&nbsp;&nbsp;float bm,<br>
1241 &nbsp;&nbsp;&nbsp;&nbsp;float rm,<br>
1242 &nbsp;&nbsp;&nbsp;&nbsp;float tm,<br>
1243 &nbsp;&nbsp;&nbsp;&nbsp;const char *sc,<br>
1244 &nbsp;&nbsp;&nbsp;&nbsp;const char *rc<br>
1245 );</p>
1246 <h5 class="parameters">Parameters</h5>
1247 <dl>
1248 <dt>n</dt>
1249 <dd class="description">Name of media size</dd>
1250 <dt>t</dt>
1251 <dd class="description">Text of media size</dd>
1252 <dt>w</dt>
1253 <dd class="description">Width in points</dd>
1254 <dt>l</dt>
1255 <dd class="description">Length in points</dd>
1256 <dt>lm</dt>
1257 <dd class="description">Left margin in points</dd>
1258 <dt>bm</dt>
1259 <dd class="description">Bottom margin in points</dd>
1260 <dt>rm</dt>
1261 <dd class="description">Right margin in points</dd>
1262 <dt>tm</dt>
1263 <dd class="description">Top margin in points</dd>
1264 <dt>sc</dt>
1265 <dd class="description">PageSize code, if any</dd>
1266 <dt>rc</dt>
1267 <dd class="description">PageRegion code, if any</dd>
1268 </dl>
1269 <h4 class="method"><a name="~ppdcMediaSize">~ppdcMediaSize</a></h4>
1270 <p class="description"></p>
1271 <p class="code">
1272 void ~ppdcMediaSize (void);</p>
1273 <h3 class="class"><a name="ppdcMessage">ppdcMessage</a></h3>
1274 <p class="description">// Translation message</p>
1275 <p class="code">class ppdcMessage : public ppdcShared {<br>
1276 &nbsp;&nbsp;public:<br>
1277 &nbsp;&nbsp;&nbsp;&nbsp;<a href="#ppdcString">ppdcString</a> *id, *string;<br>
1278 };</p>
1279 <h4 class="members">Members</h4>
1280 <dl>
1281 <dt>string </dt>
1282 <dd class="description">Translation string</dd>
1283 </dl>
1284 <h4 class="method"><a name="ppdcMessage">ppdcMessage</a></h4>
1285 <p class="description"></p>
1286 <p class="code">
1287 void ppdcMessage (<br>
1288 &nbsp;&nbsp;&nbsp;&nbsp;const char *i,<br>
1289 &nbsp;&nbsp;&nbsp;&nbsp;const char *s<br>
1290 );</p>
1291 <h5 class="parameters">Parameters</h5>
1292 <dl>
1293 <dt>i</dt>
1294 <dd class="description">ID</dd>
1295 <dt>s</dt>
1296 <dd class="description">Text</dd>
1297 </dl>
1298 <h4 class="method"><a name="~ppdcMessage">~ppdcMessage</a></h4>
1299 <p class="description"></p>
1300 <p class="code">
1301 void ~ppdcMessage (void);</p>
1302 <h3 class="class"><a name="ppdcOption">ppdcOption</a></h3>
1303 <p class="description">// Option</p>
1304 <p class="code">class ppdcOption : public ppdcShared {<br>
1305 &nbsp;&nbsp;public:<br>
1306 &nbsp;&nbsp;&nbsp;&nbsp;<a href="#ppdcArray">ppdcArray</a> *choices;<br>
1307 &nbsp;&nbsp;&nbsp;&nbsp;<a href="#ppdcString">ppdcString</a> *defchoice;<br>
1308 &nbsp;&nbsp;&nbsp;&nbsp;float order;<br>
1309 &nbsp;&nbsp;&nbsp;&nbsp;<a href="#ppdcOptSection">ppdcOptSection</a> section;<br>
1310 &nbsp;&nbsp;&nbsp;&nbsp;<a href="#ppdcString">ppdcString</a> *name, *text;<br>
1311 &nbsp;&nbsp;&nbsp;&nbsp;<a href="#ppdcOptType">ppdcOptType</a> type;<br>
1312 };</p>
1313 <h4 class="members">Members</h4>
1314 <dl>
1315 <dt>choices </dt>
1316 <dd class="description">Choices</dd>
1317 <dt>defchoice </dt>
1318 <dd class="description">Default choice</dd>
1319 <dt>order </dt>
1320 <dd class="description">Order number</dd>
1321 <dt>section </dt>
1322 <dd class="description">Section for option code</dd>
1323 <dt>text </dt>
1324 <dd class="description">Human-readable text of option</dd>
1325 <dt>type </dt>
1326 <dd class="description">Type of option</dd>
1327 </dl>
1328 <h4 class="method"><a name="PPDC_NAME">PPDC_NAME</a></h4>
1329 <p class="description"></p>
1330 <p class="code">
1331 void PPDC_NAME (<br>
1332 &nbsp;&nbsp;&nbsp;&nbsp;void add_choice(<a href="#ppdcChoice">ppdcChoice</a> *c<br>
1333 );</p>
1334 <h5 class="parameters">Parameters</h5>
1335 <dl>
1336 <dt>c</dt>
1337 </dl>
1338 <h4 class="method"><a name="find_choice">find_choice</a></h4>
1339 <p class="description"></p>
1340 <p class="code">
1341 <a href="#ppdcChoice">ppdcChoice</a> *find_choice (<br>
1342 &nbsp;&nbsp;&nbsp;&nbsp;const char *n<br>
1343 );</p>
1344 <h5 class="parameters">Parameters</h5>
1345 <dl>
1346 <dt>n</dt>
1347 <dd class="description">Name of choice</dd>
1348 </dl>
1349 <h5 class="returnvalue">Return Value</h5>
1350 <p class="description">Choice or NULL</p>
1351 <h4 class="method"><a name="ppdcOption">ppdcOption</a></h4>
1352 <p class="description"></p>
1353 <p class="code">
1354 void ppdcOption (<br>
1355 &nbsp;&nbsp;&nbsp;&nbsp;<a href="#ppdcOption">ppdcOption</a> *o<br>
1356 );</p>
1357 <h5 class="parameters">Parameters</h5>
1358 <dl>
1359 <dt>o</dt>
1360 <dd class="description">Template option</dd>
1361 </dl>
1362 <h4 class="method"><a name="set_defchoice">set_defchoice</a></h4>
1363 <p class="description"></p>
1364 <p class="code">
1365 void set_defchoice (<br>
1366 &nbsp;&nbsp;&nbsp;&nbsp;<a href="#ppdcChoice">ppdcChoice</a> *c<br>
1367 );</p>
1368 <h5 class="parameters">Parameters</h5>
1369 <dl>
1370 <dt>c</dt>
1371 <dd class="description">Choice</dd>
1372 </dl>
1373 <h4 class="method"><a name="~ppdcOption">~ppdcOption</a></h4>
1374 <p class="description"></p>
1375 <p class="code">
1376 void ~ppdcOption (void);</p>
1377 <h3 class="class"><a name="ppdcProfile">ppdcProfile</a></h3>
1378 <p class="description">// Color Profile</p>
1379 <p class="code">class ppdcProfile : public ppdcShared {<br>
1380 &nbsp;&nbsp;public:<br>
1381 &nbsp;&nbsp;&nbsp;&nbsp;<a href="#ppdcString">ppdcString</a> *resolution, *media_type;<br>
1382 &nbsp;&nbsp;&nbsp;&nbsp;float density, gamma, profile[9];<br>
1383 };</p>
1384 <h4 class="members">Members</h4>
1385 <dl>
1386 <dt>media_type </dt>
1387 <dd class="description">Media type name</dd>
1388 <dt>profile[9] </dt>
1389 <dd class="description">Color profile matrix</dd>
1390 </dl>
1391 <h4 class="method"><a name="ppdcProfile">ppdcProfile</a></h4>
1392 <p class="description"></p>
1393 <p class="code">
1394 void ppdcProfile (<br>
1395 &nbsp;&nbsp;&nbsp;&nbsp;const char *r,<br>
1396 &nbsp;&nbsp;&nbsp;&nbsp;const char *m,<br>
1397 &nbsp;&nbsp;&nbsp;&nbsp;float d,<br>
1398 &nbsp;&nbsp;&nbsp;&nbsp;float g,<br>
1399 &nbsp;&nbsp;&nbsp;&nbsp;const float *p<br>
1400 );</p>
1401 <h5 class="parameters">Parameters</h5>
1402 <dl>
1403 <dt>r</dt>
1404 <dd class="description">Resolution name</dd>
1405 <dt>m</dt>
1406 <dd class="description">Media type name</dd>
1407 <dt>d</dt>
1408 <dd class="description">Density</dd>
1409 <dt>g</dt>
1410 <dd class="description">Gamma</dd>
1411 <dt>p</dt>
1412 <dd class="description">3x3 transform matrix</dd>
1413 </dl>
1414 <h4 class="method"><a name="~ppdcProfile">~ppdcProfile</a></h4>
1415 <p class="description"></p>
1416 <p class="code">
1417 void ~ppdcProfile (void);</p>
1418 <h3 class="class"><a name="ppdcShared">ppdcShared</a></h3>
1419 <p class="description">// Shared Data Value</p>
1420 <p class="code">class ppdcShared {<br>
1421 &nbsp;&nbsp;private:<br>
1422 &nbsp;&nbsp;&nbsp;&nbsp;int use;<br>
1423 };</p>
1424 <h4 class="members">Members</h4>
1425 <dl>
1426 <dt>use </dt>
1427 <dd class="description">Use count (delete when 0)</dd>
1428 </dl>
1429 <h4 class="method"><a name="class_name">class_name</a></h4>
1430 <p class="description"></p>
1431 <p class="code">
1432 virtual const char *class_name (void);</p>
1433 <h5 class="returnvalue">Return Value</h5>
1434 <p class="description"></p>
1435 <h4 class="method"><a name="ppdcShared">ppdcShared</a></h4>
1436 <p class="description"></p>
1437 <p class="code">
1438 void ppdcShared (void);</p>
1439 <h4 class="method"><a name="release">release</a></h4>
1440 <p class="description"></p>
1441 <p class="code">
1442 void release (void);</p>
1443 <h4 class="method"><a name="retain">retain</a></h4>
1444 <p class="description"></p>
1445 <p class="code">
1446 void retain (void);</p>
1447 <h4 class="method"><a name="~ppdcShared">~ppdcShared</a></h4>
1448 <p class="description"></p>
1449 <p class="code">
1450 void ~ppdcShared (void);</p>
1451 <h3 class="class"><a name="ppdcSource">ppdcSource</a></h3>
1452 <p class="description">// Source File</p>
1453 <p class="code">class ppdcSource : public ppdcShared {<br>
1454 &nbsp;&nbsp;public:<br>
1455 &nbsp;&nbsp;&nbsp;&nbsp;int cond_state, *cond_current, cond_stack[101];<br>
1456 &nbsp;&nbsp;&nbsp;&nbsp;static const char *driver_types[];<br>
1457 &nbsp;&nbsp;&nbsp;&nbsp;<a href="#ppdcString">ppdcString</a> *filename;<br>
1458 &nbsp;&nbsp;&nbsp;&nbsp;static <a href="#ppdcArray">ppdcArray</a> *includes;<br>
1459 &nbsp;&nbsp;&nbsp;&nbsp;<a href="#ppdcArray">ppdcArray</a> *base_fonts, *drivers, *po_files, *sizes, *vars;<br>
1460 };</p>
1461 <h4 class="members">Members</h4>
1462 <dl>
1463 <dt>cond_stack[101] </dt>
1464 <dd class="description">#if state stack</dd>
1465 <dt>driver_types[] </dt>
1466 <dd class="description">Driver types</dd>
1467 <dt>filename </dt>
1468 <dd class="description">Filename</dd>
1469 <dt>includes </dt>
1470 <dd class="description">Include directories</dd>
1471 <dt>vars </dt>
1472 <dd class="description">Defined variables</dd>
1473 </dl>
1474 <h4 class="method"><a name="PPDC_NAME">PPDC_NAME</a></h4>
1475 <p class="description"></p>
1476 <p class="code">
1477 void PPDC_NAME (<br>
1478 &nbsp;&nbsp;&nbsp;&nbsp;static void add_include(const char *d<br>
1479 );</p>
1480 <h5 class="parameters">Parameters</h5>
1481 <dl>
1482 <dt>d</dt>
1483 </dl>
1484 <h4 class="method"><a name="add_include">add_include</a></h4>
1485 <p class="description"></p>
1486 <p class="code">
1487 void add_include (<br>
1488 &nbsp;&nbsp;&nbsp;&nbsp;const char *d<br>
1489 );</p>
1490 <h5 class="parameters">Parameters</h5>
1491 <dl>
1492 <dt>d</dt>
1493 <dd class="description">Include directory</dd>
1494 </dl>
1495 <h4 class="method"><a name="find_driver">find_driver</a></h4>
1496 <p class="description"></p>
1497 <p class="code">
1498 <a href="#ppdcDriver">ppdcDriver</a> *find_driver (<br>
1499 &nbsp;&nbsp;&nbsp;&nbsp;const char *f<br>
1500 );</p>
1501 <h5 class="parameters">Parameters</h5>
1502 <dl>
1503 <dt>f</dt>
1504 <dd class="description">Driver file name</dd>
1505 </dl>
1506 <h5 class="returnvalue">Return Value</h5>
1507 <p class="description">Driver</p>
1508 <h4 class="method"><a name="find_include">find_include</a></h4>
1509 <p class="description"></p>
1510 <p class="code">
1511 char *find_include (<br>
1512 &nbsp;&nbsp;&nbsp;&nbsp;const char *f,<br>
1513 &nbsp;&nbsp;&nbsp;&nbsp;const char *base,<br>
1514 &nbsp;&nbsp;&nbsp;&nbsp;char *n,<br>
1515 &nbsp;&nbsp;&nbsp;&nbsp;int nlen<br>
1516 );</p>
1517 <h5 class="parameters">Parameters</h5>
1518 <dl>
1519 <dt>f</dt>
1520 <dd class="description">Include filename</dd>
1521 <dt>base</dt>
1522 <dd class="description">Current directory</dd>
1523 <dt>n</dt>
1524 <dd class="description">Path buffer</dd>
1525 <dt>nlen</dt>
1526 <dd class="description">Path buffer length</dd>
1527 </dl>
1528 <h5 class="returnvalue">Return Value</h5>
1529 <p class="description">Found path or NULL</p>
1530 <h4 class="method"><a name="find_po">find_po</a></h4>
1531 <p class="description"></p>
1532 <p class="code">
1533 <a href="#ppdcCatalog">ppdcCatalog</a> *find_po (<br>
1534 &nbsp;&nbsp;&nbsp;&nbsp;const char *l<br>
1535 );</p>
1536 <h5 class="parameters">Parameters</h5>
1537 <dl>
1538 <dt>l</dt>
1539 <dd class="description">Locale name</dd>
1540 </dl>
1541 <h5 class="returnvalue">Return Value</h5>
1542 <p class="description">Message catalog or NULL</p>
1543 <h4 class="method"><a name="find_size">find_size</a></h4>
1544 <p class="description"></p>
1545 <p class="code">
1546 <a href="#ppdcMediaSize">ppdcMediaSize</a> *find_size (<br>
1547 &nbsp;&nbsp;&nbsp;&nbsp;const char *s<br>
1548 );</p>
1549 <h5 class="parameters">Parameters</h5>
1550 <dl>
1551 <dt>s</dt>
1552 <dd class="description">Size name</dd>
1553 </dl>
1554 <h5 class="returnvalue">Return Value</h5>
1555 <p class="description">Size</p>
1556 <h4 class="method"><a name="find_variable">find_variable</a></h4>
1557 <p class="description"></p>
1558 <p class="code">
1559 <a href="#ppdcVariable">ppdcVariable</a> *find_variable (<br>
1560 &nbsp;&nbsp;&nbsp;&nbsp;const char *n<br>
1561 );</p>
1562 <h5 class="parameters">Parameters</h5>
1563 <dl>
1564 <dt>n</dt>
1565 <dd class="description">Variable name</dd>
1566 </dl>
1567 <h5 class="returnvalue">Return Value</h5>
1568 <p class="description">Variable</p>
1569 <h4 class="method"><a name="get_attr">get_attr</a></h4>
1570 <p class="description"></p>
1571 <p class="code">
1572 <a href="#ppdcAttr">ppdcAttr</a> *get_attr (<br>
1573 &nbsp;&nbsp;&nbsp;&nbsp;<a href="#ppdcFile">ppdcFile</a> *fp,<br>
1574 &nbsp;&nbsp;&nbsp;&nbsp;bool loc<br>
1575 );</p>
1576 <h5 class="parameters">Parameters</h5>
1577 <dl>
1578 <dt>fp</dt>
1579 <dd class="description">File to read</dd>
1580 <dt>loc</dt>
1581 <dd class="description">Localize this attribute?</dd>
1582 </dl>
1583 <h5 class="returnvalue">Return Value</h5>
1584 <p class="description">Attribute</p>
1585 <h4 class="method"><a name="get_boolean">get_boolean</a></h4>
1586 <p class="description"></p>
1587 <p class="code">
1588 int get_boolean (<br>
1589 &nbsp;&nbsp;&nbsp;&nbsp;<a href="#ppdcFile">ppdcFile</a> *fp<br>
1590 );</p>
1591 <h5 class="parameters">Parameters</h5>
1592 <dl>
1593 <dt>fp</dt>
1594 <dd class="description">File to read</dd>
1595 </dl>
1596 <h5 class="returnvalue">Return Value</h5>
1597 <p class="description">Boolean value</p>
1598 <h4 class="method"><a name="get_choice">get_choice</a></h4>
1599 <p class="description"></p>
1600 <p class="code">
1601 <a href="#ppdcChoice">ppdcChoice</a> *get_choice (<br>
1602 &nbsp;&nbsp;&nbsp;&nbsp;<a href="#ppdcFile">ppdcFile</a> *fp<br>
1603 );</p>
1604 <h5 class="parameters">Parameters</h5>
1605 <dl>
1606 <dt>fp</dt>
1607 <dd class="description">File to read</dd>
1608 </dl>
1609 <h5 class="returnvalue">Return Value</h5>
1610 <p class="description">Choice data</p>
1611 <h4 class="method"><a name="get_color_model">get_color_model</a></h4>
1612 <p class="description"></p>
1613 <p class="code">
1614 <a href="#ppdcChoice">ppdcChoice</a> *get_color_model (<br>
1615 &nbsp;&nbsp;&nbsp;&nbsp;<a href="#ppdcFile">ppdcFile</a> *fp<br>
1616 );</p>
1617 <h5 class="parameters">Parameters</h5>
1618 <dl>
1619 <dt>fp</dt>
1620 <dd class="description">File to read</dd>
1621 </dl>
1622 <h5 class="returnvalue">Return Value</h5>
1623 <p class="description">Choice data</p>
1624 <h4 class="method"><a name="get_color_order">get_color_order</a></h4>
1625 <p class="description"></p>
1626 <p class="code">
1627 int get_color_order (<br>
1628 &nbsp;&nbsp;&nbsp;&nbsp;const char *co<br>
1629 );</p>
1630 <h5 class="parameters">Parameters</h5>
1631 <dl>
1632 <dt>co</dt>
1633 <dd class="description">Color order string</dd>
1634 </dl>
1635 <h5 class="returnvalue">Return Value</h5>
1636 <p class="description">Color order value</p>
1637 <h4 class="method"><a name="get_color_profile">get_color_profile</a></h4>
1638 <p class="description"></p>
1639 <p class="code">
1640 <a href="#ppdcProfile">ppdcProfile</a> *get_color_profile (<br>
1641 &nbsp;&nbsp;&nbsp;&nbsp;<a href="#ppdcFile">ppdcFile</a> *fp<br>
1642 );</p>
1643 <h5 class="parameters">Parameters</h5>
1644 <dl>
1645 <dt>fp</dt>
1646 <dd class="description">File to read</dd>
1647 </dl>
1648 <h5 class="returnvalue">Return Value</h5>
1649 <p class="description">Color profile</p>
1650 <h4 class="method"><a name="get_color_space">get_color_space</a></h4>
1651 <p class="description"></p>
1652 <p class="code">
1653 int get_color_space (<br>
1654 &nbsp;&nbsp;&nbsp;&nbsp;const char *cs<br>
1655 );</p>
1656 <h5 class="parameters">Parameters</h5>
1657 <dl>
1658 <dt>cs</dt>
1659 <dd class="description">Colorspace string</dd>
1660 </dl>
1661 <h5 class="returnvalue">Return Value</h5>
1662 <p class="description">Colorspace value</p>
1663 <h4 class="method"><a name="get_constraint">get_constraint</a></h4>
1664 <p class="description"></p>
1665 <p class="code">
1666 <a href="#ppdcConstraint">ppdcConstraint</a> *get_constraint (<br>
1667 &nbsp;&nbsp;&nbsp;&nbsp;<a href="#ppdcFile">ppdcFile</a> *fp<br>
1668 );</p>
1669 <h5 class="parameters">Parameters</h5>
1670 <dl>
1671 <dt>fp</dt>
1672 <dd class="description">File to read</dd>
1673 </dl>
1674 <h5 class="returnvalue">Return Value</h5>
1675 <p class="description">Constraint</p>
1676 <h4 class="method"><a name="get_custom_size">get_custom_size</a></h4>
1677 <p class="description"></p>
1678 <p class="code">
1679 <a href="#ppdcMediaSize">ppdcMediaSize</a> *get_custom_size (<br>
1680 &nbsp;&nbsp;&nbsp;&nbsp;<a href="#ppdcFile">ppdcFile</a> *fp<br>
1681 );</p>
1682 <h5 class="parameters">Parameters</h5>
1683 <dl>
1684 <dt>fp</dt>
1685 <dd class="description">File to read</dd>
1686 </dl>
1687 <h5 class="returnvalue">Return Value</h5>
1688 <p class="description">Media size</p>
1689 <h4 class="method"><a name="get_duplex">get_duplex</a></h4>
1690 <p class="description"></p>
1691 <p class="code">
1692 void get_duplex (<br>
1693 &nbsp;&nbsp;&nbsp;&nbsp;<a href="#ppdcFile">ppdcFile</a> *fp,<br>
1694 &nbsp;&nbsp;&nbsp;&nbsp;<a href="#ppdcDriver">ppdcDriver</a> *d<br>
1695 );</p>
1696 <h5 class="parameters">Parameters</h5>
1697 <dl>
1698 <dt>fp</dt>
1699 <dd class="description">File to read from</dd>
1700 <dt>d</dt>
1701 <dd class="description">Current driver</dd>
1702 </dl>
1703 <h4 class="method"><a name="get_filter">get_filter</a></h4>
1704 <p class="description"></p>
1705 <p class="code">
1706 <a href="#ppdcFilter">ppdcFilter</a> *get_filter (<br>
1707 &nbsp;&nbsp;&nbsp;&nbsp;<a href="#ppdcFile">ppdcFile</a> *fp<br>
1708 );</p>
1709 <h5 class="parameters">Parameters</h5>
1710 <dl>
1711 <dt>fp</dt>
1712 <dd class="description">File to read</dd>
1713 </dl>
1714 <h5 class="returnvalue">Return Value</h5>
1715 <p class="description">Filter</p>
1716 <h4 class="method"><a name="get_float">get_float</a></h4>
1717 <p class="description"></p>
1718 <p class="code">
1719 float get_float (<br>
1720 &nbsp;&nbsp;&nbsp;&nbsp;<a href="#ppdcFile">ppdcFile</a> *fp<br>
1721 );</p>
1722 <h5 class="parameters">Parameters</h5>
1723 <dl>
1724 <dt>fp</dt>
1725 <dd class="description">File to read</dd>
1726 </dl>
1727 <h5 class="returnvalue">Return Value</h5>
1728 <p class="description">Number</p>
1729 <h4 class="method"><a name="get_font">get_font</a></h4>
1730 <p class="description"></p>
1731 <p class="code">
1732 <a href="#ppdcFont">ppdcFont</a> *get_font (<br>
1733 &nbsp;&nbsp;&nbsp;&nbsp;<a href="#ppdcFile">ppdcFile</a> *fp<br>
1734 );</p>
1735 <h5 class="parameters">Parameters</h5>
1736 <dl>
1737 <dt>fp</dt>
1738 <dd class="description">File to read</dd>
1739 </dl>
1740 <h5 class="returnvalue">Return Value</h5>
1741 <p class="description">Font data</p>
1742 <h4 class="method"><a name="get_generic">get_generic</a></h4>
1743 <p class="description"></p>
1744 <p class="code">
1745 <a href="#ppdcChoice">ppdcChoice</a> *get_generic (<br>
1746 &nbsp;&nbsp;&nbsp;&nbsp;<a href="#ppdcFile">ppdcFile</a> *fp,<br>
1747 &nbsp;&nbsp;&nbsp;&nbsp;const char *keyword,<br>
1748 &nbsp;&nbsp;&nbsp;&nbsp;const char *tattr,<br>
1749 &nbsp;&nbsp;&nbsp;&nbsp;const char *nattr<br>
1750 );</p>
1751 <h5 class="parameters">Parameters</h5>
1752 <dl>
1753 <dt>fp</dt>
1754 <dd class="description">File to read</dd>
1755 <dt>keyword</dt>
1756 <dd class="description">Keyword name</dd>
1757 <dt>tattr</dt>
1758 <dd class="description">Text attribute</dd>
1759 <dt>nattr</dt>
1760 <dd class="description">Numeric attribute</dd>
1761 </dl>
1762 <h5 class="returnvalue">Return Value</h5>
1763 <p class="description">Choice data</p>
1764 <h4 class="method"><a name="get_group">get_group</a></h4>
1765 <p class="description"></p>
1766 <p class="code">
1767 <a href="#ppdcGroup">ppdcGroup</a> *get_group (<br>
1768 &nbsp;&nbsp;&nbsp;&nbsp;<a href="#ppdcFile">ppdcFile</a> *fp,<br>
1769 &nbsp;&nbsp;&nbsp;&nbsp;<a href="#ppdcDriver">ppdcDriver</a> *d<br>
1770 );</p>
1771 <h5 class="parameters">Parameters</h5>
1772 <dl>
1773 <dt>fp</dt>
1774 <dd class="description">File to read</dd>
1775 <dt>d</dt>
1776 <dd class="description">Printer driver</dd>
1777 </dl>
1778 <h5 class="returnvalue">Return Value</h5>
1779 <p class="description">Group</p>
1780 <h4 class="method"><a name="get_installable">get_installable</a></h4>
1781 <p class="description"></p>
1782 <p class="code">
1783 <a href="#ppdcOption">ppdcOption</a> *get_installable (<br>
1784 &nbsp;&nbsp;&nbsp;&nbsp;<a href="#ppdcFile">ppdcFile</a> *fp<br>
1785 );</p>
1786 <h5 class="parameters">Parameters</h5>
1787 <dl>
1788 <dt>fp</dt>
1789 <dd class="description">File to read</dd>
1790 </dl>
1791 <h5 class="returnvalue">Return Value</h5>
1792 <p class="description">Option</p>
1793 <h4 class="method"><a name="get_integer">get_integer</a></h4>
1794 <p class="description"></p>
1795 <p class="code">
1796 int get_integer (<br>
1797 &nbsp;&nbsp;&nbsp;&nbsp;<a href="#ppdcFile">ppdcFile</a> *fp<br>
1798 );</p>
1799 <h5 class="parameters">Parameters</h5>
1800 <dl>
1801 <dt>fp</dt>
1802 <dd class="description">File to read</dd>
1803 </dl>
1804 <h5 class="returnvalue">Return Value</h5>
1805 <p class="description">Integer value</p>
1806 <h4 class="method"><a name="get_measurement">get_measurement</a></h4>
1807 <p class="description"></p>
1808 <p class="code">
1809 float get_measurement (<br>
1810 &nbsp;&nbsp;&nbsp;&nbsp;<a href="#ppdcFile">ppdcFile</a> *fp<br>
1811 );</p>
1812 <h5 class="parameters">Parameters</h5>
1813 <dl>
1814 <dt>fp</dt>
1815 <dd class="description">File to read</dd>
1816 </dl>
1817 <h5 class="returnvalue">Return Value</h5>
1818 <p class="description">Measurement value in points</p>
1819 <h4 class="method"><a name="get_option">get_option</a></h4>
1820 <p class="description"></p>
1821 <p class="code">
1822 <a href="#ppdcOption">ppdcOption</a> *get_option (<br>
1823 &nbsp;&nbsp;&nbsp;&nbsp;<a href="#ppdcFile">ppdcFile</a> *fp,<br>
1824 &nbsp;&nbsp;&nbsp;&nbsp;<a href="#ppdcDriver">ppdcDriver</a> *d,<br>
1825 &nbsp;&nbsp;&nbsp;&nbsp;<a href="#ppdcGroup">ppdcGroup</a> *g<br>
1826 );</p>
1827 <h5 class="parameters">Parameters</h5>
1828 <dl>
1829 <dt>fp</dt>
1830 <dd class="description">File to read</dd>
1831 <dt>d</dt>
1832 <dd class="description">Printer driver</dd>
1833 <dt>g</dt>
1834 <dd class="description">Current group</dd>
1835 </dl>
1836 <h5 class="returnvalue">Return Value</h5>
1837 <p class="description">Option</p>
1838 <h4 class="method"><a name="get_po">get_po</a></h4>
1839 <p class="description"></p>
1840 <p class="code">
1841 <a href="#ppdcCatalog">ppdcCatalog</a> *get_po (<br>
1842 &nbsp;&nbsp;&nbsp;&nbsp;<a href="#ppdcFile">ppdcFile</a> *fp<br>
1843 );</p>
1844 <h5 class="parameters">Parameters</h5>
1845 <dl>
1846 <dt>fp</dt>
1847 <dd class="description">File to read</dd>
1848 </dl>
1849 <h5 class="returnvalue">Return Value</h5>
1850 <p class="description">Message catalog</p>
1851 <h4 class="method"><a name="get_resolution">get_resolution</a></h4>
1852 <p class="description"></p>
1853 <p class="code">
1854 <a href="#ppdcChoice">ppdcChoice</a> *get_resolution (<br>
1855 &nbsp;&nbsp;&nbsp;&nbsp;<a href="#ppdcFile">ppdcFile</a> *fp<br>
1856 );</p>
1857 <h5 class="parameters">Parameters</h5>
1858 <dl>
1859 <dt>fp</dt>
1860 <dd class="description">File to read</dd>
1861 </dl>
1862 <h5 class="returnvalue">Return Value</h5>
1863 <p class="description">Choice data</p>
1864 <h4 class="method"><a name="get_simple_profile">get_simple_profile</a></h4>
1865 <p class="description"></p>
1866 <p class="code">
1867 <a href="#ppdcProfile">ppdcProfile</a> *get_simple_profile (<br>
1868 &nbsp;&nbsp;&nbsp;&nbsp;<a href="#ppdcFile">ppdcFile</a> *fp<br>
1869 );</p>
1870 <h5 class="parameters">Parameters</h5>
1871 <dl>
1872 <dt>fp</dt>
1873 <dd class="description">File to read</dd>
1874 </dl>
1875 <h5 class="returnvalue">Return Value</h5>
1876 <p class="description">Color profile</p>
1877 <h4 class="method"><a name="get_size">get_size</a></h4>
1878 <p class="description"></p>
1879 <p class="code">
1880 <a href="#ppdcMediaSize">ppdcMediaSize</a> *get_size (<br>
1881 &nbsp;&nbsp;&nbsp;&nbsp;<a href="#ppdcFile">ppdcFile</a> *fp<br>
1882 );</p>
1883 <h5 class="parameters">Parameters</h5>
1884 <dl>
1885 <dt>fp</dt>
1886 <dd class="description">File to read</dd>
1887 </dl>
1888 <h5 class="returnvalue">Return Value</h5>
1889 <p class="description">Media size</p>
1890 <h4 class="method"><a name="get_token">get_token</a></h4>
1891 <p class="description"></p>
1892 <p class="code">
1893 char *get_token (<br>
1894 &nbsp;&nbsp;&nbsp;&nbsp;<a href="#ppdcFile">ppdcFile</a> *fp,<br>
1895 &nbsp;&nbsp;&nbsp;&nbsp;char *buffer,<br>
1896 &nbsp;&nbsp;&nbsp;&nbsp;int buflen<br>
1897 );</p>
1898 <h5 class="parameters">Parameters</h5>
1899 <dl>
1900 <dt>fp</dt>
1901 <dd class="description">File to read</dd>
1902 <dt>buffer</dt>
1903 <dd class="description">Buffer</dd>
1904 <dt>buflen</dt>
1905 <dd class="description">Length of buffer</dd>
1906 </dl>
1907 <h5 class="returnvalue">Return Value</h5>
1908 <p class="description">Token string or NULL</p>
1909 <h4 class="method"><a name="get_variable">get_variable</a></h4>
1910 <p class="description"></p>
1911 <p class="code">
1912 <a href="#ppdcVariable">ppdcVariable</a> *get_variable (<br>
1913 &nbsp;&nbsp;&nbsp;&nbsp;<a href="#ppdcFile">ppdcFile</a> *fp<br>
1914 );</p>
1915 <h5 class="parameters">Parameters</h5>
1916 <dl>
1917 <dt>fp</dt>
1918 <dd class="description">File to read</dd>
1919 </dl>
1920 <h5 class="returnvalue">Return Value</h5>
1921 <p class="description">Variable</p>
1922 <h4 class="method"><a name="import_ppd">import_ppd</a></h4>
1923 <p class="description"></p>
1924 <p class="code">
1925 int import_ppd (<br>
1926 &nbsp;&nbsp;&nbsp;&nbsp;const char *f<br>
1927 );</p>
1928 <h5 class="parameters">Parameters</h5>
1929 <dl>
1930 <dt>f</dt>
1931 <dd class="description">Filename</dd>
1932 </dl>
1933 <h5 class="returnvalue">Return Value</h5>
1934 <p class="description">1 on success, 0 on failure</p>
1935 <h4 class="method"><a name="ppdcSource">ppdcSource</a></h4>
1936 <p class="description"></p>
1937 <p class="code">
1938 void ppdcSource (<br>
1939 &nbsp;&nbsp;&nbsp;&nbsp;const char *f,<br>
1940 &nbsp;&nbsp;&nbsp;&nbsp;cups_file_t *ffp<br>
1941 );</p>
1942 <h5 class="parameters">Parameters</h5>
1943 <dl>
1944 <dt>f</dt>
1945 <dd class="description">File to read</dd>
1946 <dt>ffp</dt>
1947 <dd class="description">File pointer to use</dd>
1948 </dl>
1949 <h4 class="method"><a name="quotef">quotef</a></h4>
1950 <p class="description"></p>
1951 <p class="code">
1952 int quotef (<br>
1953 &nbsp;&nbsp;&nbsp;&nbsp;cups_file_t *fp,<br>
1954 &nbsp;&nbsp;&nbsp;&nbsp;const char *format,<br>
1955 &nbsp;&nbsp;&nbsp;&nbsp;...<br>
1956 );</p>
1957 <h5 class="parameters">Parameters</h5>
1958 <dl>
1959 <dt>fp</dt>
1960 <dd class="description">File to write to</dd>
1961 <dt>format</dt>
1962 <dd class="description">Printf-style format string</dd>
1963 <dt>...</dt>
1964 <dd class="description">Additional args as needed</dd>
1965 </dl>
1966 <h5 class="returnvalue">Return Value</h5>
1967 <p class="description">Number bytes on success, -1 on failure</p>
1968 <h4 class="method"><a name="read_file">read_file</a></h4>
1969 <p class="description"></p>
1970 <p class="code">
1971 void read_file (<br>
1972 &nbsp;&nbsp;&nbsp;&nbsp;const char *f,<br>
1973 &nbsp;&nbsp;&nbsp;&nbsp;cups_file_t *ffp<br>
1974 );</p>
1975 <h5 class="parameters">Parameters</h5>
1976 <dl>
1977 <dt>f</dt>
1978 <dd class="description">File to read</dd>
1979 <dt>ffp</dt>
1980 <dd class="description">File pointer to use</dd>
1981 </dl>
1982 <h4 class="method"><a name="scan_file">scan_file</a></h4>
1983 <p class="description"></p>
1984 <p class="code">
1985 void scan_file (<br>
1986 &nbsp;&nbsp;&nbsp;&nbsp;<a href="#ppdcFile">ppdcFile</a> *fp,<br>
1987 &nbsp;&nbsp;&nbsp;&nbsp;<a href="#ppdcDriver">ppdcDriver</a> *td,<br>
1988 &nbsp;&nbsp;&nbsp;&nbsp;bool inc<br>
1989 );</p>
1990 <h5 class="parameters">Parameters</h5>
1991 <dl>
1992 <dt>fp</dt>
1993 <dd class="description">File to read</dd>
1994 <dt>td</dt>
1995 <dd class="description">Driver template</dd>
1996 <dt>inc</dt>
1997 <dd class="description">Including?</dd>
1998 </dl>
1999 <h4 class="method"><a name="set_variable">set_variable</a></h4>
2000 <p class="description"></p>
2001 <p class="code">
2002 <a href="#ppdcVariable">ppdcVariable</a> *set_variable (<br>
2003 &nbsp;&nbsp;&nbsp;&nbsp;const char *name,<br>
2004 &nbsp;&nbsp;&nbsp;&nbsp;const char *value<br>
2005 );</p>
2006 <h5 class="parameters">Parameters</h5>
2007 <dl>
2008 <dt>name</dt>
2009 <dd class="description">Name</dd>
2010 <dt>value</dt>
2011 <dd class="description">Value</dd>
2012 </dl>
2013 <h5 class="returnvalue">Return Value</h5>
2014 <p class="description">Variable</p>
2015 <h4 class="method"><a name="write_file">write_file</a></h4>
2016 <p class="description"></p>
2017 <p class="code">
2018 int write_file (<br>
2019 &nbsp;&nbsp;&nbsp;&nbsp;const char *f<br>
2020 );</p>
2021 <h5 class="parameters">Parameters</h5>
2022 <dl>
2023 <dt>f</dt>
2024 <dd class="description">File to write</dd>
2025 </dl>
2026 <h5 class="returnvalue">Return Value</h5>
2027 <p class="description">0 on success, -1 on error</p>
2028 <h4 class="method"><a name="~ppdcSource">~ppdcSource</a></h4>
2029 <p class="description"></p>
2030 <p class="code">
2031 void ~ppdcSource (void);</p>
2032 <h3 class="class"><a name="ppdcString">ppdcString</a></h3>
2033 <p class="description">// Shared String</p>
2034 <p class="code">class ppdcString : public ppdcShared {<br>
2035 &nbsp;&nbsp;public:<br>
2036 &nbsp;&nbsp;&nbsp;&nbsp;char *value;<br>
2037 };</p>
2038 <h4 class="members">Members</h4>
2039 <dl>
2040 <dt>value </dt>
2041 <dd class="description">String value</dd>
2042 </dl>
2043 <h4 class="method"><a name="ppdcString">ppdcString</a></h4>
2044 <p class="description"></p>
2045 <p class="code">
2046 void ppdcString (<br>
2047 &nbsp;&nbsp;&nbsp;&nbsp;const char *v<br>
2048 );</p>
2049 <h5 class="parameters">Parameters</h5>
2050 <dl>
2051 <dt>v</dt>
2052 <dd class="description">String</dd>
2053 </dl>
2054 <h4 class="method"><a name="~ppdcString">~ppdcString</a></h4>
2055 <p class="description"></p>
2056 <p class="code">
2057 void ~ppdcString (void);</p>
2058 <h3 class="class"><a name="ppdcVariable">ppdcVariable</a></h3>
2059 <p class="description">// Variable Definition</p>
2060 <p class="code">class ppdcVariable : public ppdcShared {<br>
2061 &nbsp;&nbsp;public:<br>
2062 &nbsp;&nbsp;&nbsp;&nbsp;<a href="#ppdcString">ppdcString</a> *name, *value;<br>
2063 };</p>
2064 <h4 class="members">Members</h4>
2065 <dl>
2066 <dt>value </dt>
2067 <dd class="description">Value of variable</dd>
2068 </dl>
2069 <h4 class="method"><a name="PPDC_NAME">PPDC_NAME</a></h4>
2070 <p class="description"></p>
2071 <p class="code">
2072 void PPDC_NAME (<br>
2073 &nbsp;&nbsp;&nbsp;&nbsp;void set_value(const char *v<br>
2074 );</p>
2075 <h5 class="parameters">Parameters</h5>
2076 <dl>
2077 <dt>v</dt>
2078 </dl>
2079 <h4 class="method"><a name="ppdcVariable">ppdcVariable</a></h4>
2080 <p class="description"></p>
2081 <p class="code">
2082 void ppdcVariable (<br>
2083 &nbsp;&nbsp;&nbsp;&nbsp;const char *n,<br>
2084 &nbsp;&nbsp;&nbsp;&nbsp;const char *v<br>
2085 );</p>
2086 <h5 class="parameters">Parameters</h5>
2087 <dl>
2088 <dt>n</dt>
2089 <dd class="description">Name of variable</dd>
2090 <dt>v</dt>
2091 <dd class="description">Value of variable</dd>
2092 </dl>
2093 <h4 class="method"><a name="set_value">set_value</a></h4>
2094 <p class="description"></p>
2095 <p class="code">
2096 void set_value (<br>
2097 &nbsp;&nbsp;&nbsp;&nbsp;const char *v<br>
2098 );</p>
2099 <h5 class="parameters">Parameters</h5>
2100 <dl>
2101 <dt>v</dt>
2102 </dl>
2103 <h4 class="method"><a name="~ppdcVariable">~ppdcVariable</a></h4>
2104 <p class="description"></p>
2105 <p class="code">
2106 void ~ppdcVariable (void);</p>
2107 <h2 class="title"><a name="TYPES">Data Types</a></h2>
2108 <h3 class="typedef"><a name="ppdc_cs_t">ppdc_cs_t</a></h3>
2109 <p class="description"></p>
2110 <p class="code">
2111 typedef enum ppdc_cs_t;
2112 </p>
2113 <h2 class="title"><a name="VARIABLES">Variables</a></h2>
2114 <h3 class="variable"><a name="ppdcSource">ppdcSource</a></h3>
2115 <p class="description">// Printer Driver Data</p>
2116 <p class="code">class ppdcSource;</p>
2117 <h2 class="title"><a name="ENUMERATIONS">Constants</a></h2>
2118 <h3 class="enumeration"><a name="ppdcCondFlags">ppdcCondFlags</a></h3>
2119 <p class="description">// Condition flags</p>
2120 <h4 class="constants">Constants</h4>
2121 <dl>
2122 <dt>PPDC_COND_NORMAL </dt>
2123 <dd class="description">Normal state</dd>
2124 <dt>PPDC_COND_SATISFIED </dt>
2125 <dd class="description">At least one condition satisfied</dd>
2126 <dt>PPDC_COND_SKIP </dt>
2127 <dd class="description">Skip state</dd>
2128 </dl>
2129 <h3 class="enumeration"><a name="ppdcDrvType">ppdcDrvType</a></h3>
2130 <p class="description">// Driver type</p>
2131 <h4 class="constants">Constants</h4>
2132 <dl>
2133 <dt>PPDC_DRIVER_CUSTOM </dt>
2134 <dd class="description">Custom driver</dd>
2135 <dt>PPDC_DRIVER_EPSON </dt>
2136 <dd class="description">rastertoepson driver</dd>
2137 <dt>PPDC_DRIVER_ESCP </dt>
2138 <dd class="description">rastertoescpx driver</dd>
2139 <dt>PPDC_DRIVER_HP </dt>
2140 <dd class="description">rastertohp driver</dd>
2141 <dt>PPDC_DRIVER_LABEL </dt>
2142 <dd class="description">rastertolabel/rastertodymo driver</dd>
2143 <dt>PPDC_DRIVER_MAX </dt>
2144 <dd class="description">Number of driver types defined</dd>
2145 <dt>PPDC_DRIVER_PCL </dt>
2146 <dd class="description">rastertopclx driver</dd>
2147 <dt>PPDC_DRIVER_PS </dt>
2148 <dd class="description">PostScript driver</dd>
2149 </dl>
2150 <h3 class="enumeration"><a name="ppdcFontStatus">ppdcFontStatus</a></h3>
2151 <p class="description">// Load status of font</p>
2152 <h4 class="constants">Constants</h4>
2153 <dl>
2154 <dt>PPDC_FONT_DISK </dt>
2155 <dd class="description">Font is on disk</dd>
2156 <dt>PPDC_FONT_ROM </dt>
2157 <dd class="description">Font is in ROM</dd>
2158 </dl>
2159 <h3 class="enumeration"><a name="ppdcLineEnding">ppdcLineEnding</a></h3>
2160 <p class="description">// Line endings</p>
2161 <h4 class="constants">Constants</h4>
2162 <dl>
2163 <dt>PPDC_CRLF </dt>
2164 <dd class="description">CR + LF</dd>
2165 <dt>PPDC_CRONLY </dt>
2166 <dd class="description">CR only</dd>
2167 <dt>PPDC_LFONLY </dt>
2168 <dd class="description">LF only</dd>
2169 </dl>
2170 <h3 class="enumeration"><a name="ppdcOptSection">ppdcOptSection</a></h3>
2171 <p class="description">// Option section</p>
2172 <h4 class="constants">Constants</h4>
2173 <dl>
2174 <dt>PPDC_SECTION_ANY </dt>
2175 <dd class="description">AnySetup</dd>
2176 <dt>PPDC_SECTION_DOCUMENT </dt>
2177 <dd class="description">DocumentSetup</dd>
2178 <dt>PPDC_SECTION_EXIT </dt>
2179 <dd class="description">ExitServer</dd>
2180 <dt>PPDC_SECTION_JCL </dt>
2181 <dd class="description">JCLSetup</dd>
2182 <dt>PPDC_SECTION_PAGE </dt>
2183 <dd class="description">PageSetup</dd>
2184 <dt>PPDC_SECTION_PROLOG </dt>
2185 <dd class="description">Prolog</dd>
2186 </dl>
2187 <h3 class="enumeration"><a name="ppdcOptType">ppdcOptType</a></h3>
2188 <p class="description">// Option type</p>
2189 <h4 class="constants">Constants</h4>
2190 <dl>
2191 <dt>PPDC_BOOLEAN </dt>
2192 <dd class="description">True/false option</dd>
2193 <dt>PPDC_PICKMANY </dt>
2194 <dd class="description">Multiple choices from list</dd>
2195 <dt>PPDC_PICKONE </dt>
2196 <dd class="description">Single choice from list</dd>
2197 </dl>
2198 </div>
2199 </body>
2200 </html>