~ubuntu-branches/ubuntu/gutsy/foo2zjs/gutsy

« back to all changes in this revision

Viewing changes to xqxdecode.1in

  • Committer: Bazaar Package Importer
  • Author(s): Till Kamppeter
  • Date: 2007-01-11 11:30:36 UTC
  • mfrom: (1.1.7 upstream)
  • Revision ID: james.westby@ubuntu.com-20070111113036-arqlfwx30o1kqm9h
Tags: 20061224-0ubuntu1
* New upstream release
* No repacking for DFSG needed any more, as foo2oak is removed upstream
* Created additional package (foo2zjs-ppds) with the PPD files

Show diffs side-by-side

added added

removed removed

Lines of Context:
 
1
.TH xqxdecode 1 "${MODpage}" "xqxdecode ${MODver}"
 
2
'\"==========================================================================
 
3
'\"     STRINGS and MACROS
 
4
'\"==========================================================================
 
5
'\"
 
6
'\"     Define strings for special characters that nroff doesn't have
 
7
'\"
 
8
'\"     N.B. using .if cua to test for special characters did not work.
 
9
'\"
 
10
.if !'\*[.T]'ps' .ds ua up
 
11
.if  '\*[.T]'ps' .ds ua \(ua
 
12
.if !'\*[.T]'ps' .ds da down
 
13
.if  '\*[.T]'ps' .ds da \(da
 
14
.if !'\*[.T]'ps' .ds <- left
 
15
.if  '\*[.T]'ps' .ds <- \(<-
 
16
.if !'\*[.T]'ps' .ds -> right
 
17
.if  '\*[.T]'ps' .ds -> \(->
 
18
'\"
 
19
'\"     bx - box a Courier string for making keycaps
 
20
'\"
 
21
'\"     N.B. this mess is to make the line drawing come out only
 
22
'\"     if we are really generating postscript
 
23
'\"
 
24
.de bx
 
25
.ie !'\*[.T]'ps' \{\
 
26
.       RB [ \\$1 ]\\$2
 
27
.\}
 
28
.el \{\
 
29
.       ie !r ps4html \{\
 
30
'\" \(br\|\s-1\f(CB\\$1\fP\s+1\|\(br\l'|0\(rn'\l'|0\(ul'
 
31
.               ft CW
 
32
.               nr par*bxw \w'\\$1'+.4m 
 
33
\Z'\v'.25m'\D'l 0 -1m'\D'l \\n[par*bxw]u 0'\D'l 0 1m'\D'l -\\n[par*bxw]u 0''\
 
34
\Z'\h'.2m'\s-1\\$1\s+1'\
 
35
\h'\\n[par*bxw]u'\\$2
 
36
.               ft P
 
37
.       \}
 
38
.       el \{\
 
39
.               RB [ \\$1 ]\\$2
 
40
.       \}
 
41
.\}
 
42
..
 
43
'\"
 
44
'\" strings to set current color (null with old groff)
 
45
'\"
 
46
.if mred .ds red \m[red]
 
47
.if mgreen .ds green \m[green]
 
48
.if mblue .ds blue \m[blue]
 
49
.if mblack .ds black \m[black]
 
50
.if mblack .ds mP \mP
 
51
'\"
 
52
'\" fix for grotty + xterm. We call for orange, grotty outputs yellow,
 
53
'\" but xterm displays yellow as orange.  The cycle is complete.
 
54
'\"
 
55
.if n .defcolor orange rgb #ffff00
 
56
'\"
 
57
'\" color <color> - set the current color (ignores request with old groff)
 
58
'\"
 
59
.de color
 
60
.if mred \m[\\$1]\c
 
61
..
 
62
'\"
 
63
'\" colorword <color> <word> - colorize a word (ignored by old groff)
 
64
'\"
 
65
.de colorword
 
66
.ie m\\$1 \m[\\$1]\\$2\mP\c
 
67
.el \\$2\c
 
68
..
 
69
'\"
 
70
'\" colbox <fg> <bg> <word> - colorize a word in a filled box
 
71
'\"
 
72
.de colbox
 
73
.ie mred \M[\\$2]\
 
74
\v'+.167v'\
 
75
\D'P 0 -0.9v  \w'\\$3'u 0  0 +0.9v   -\w'\\$3'u 0'\
 
76
\v'-.167v'\
 
77
\m[\\$1]\\$3\mP\MP
 
78
.el \\$3\c
 
79
..
 
80
'\"
 
81
'\"     Macros for doing pdfmarks
 
82
'\"
 
83
.de specialps
 
84
\\k_\X'ps: \\$*'\h'|\\n_u'\c
 
85
..
 
86
'\"
 
87
'\" pdfmark PDFMARKCODE
 
88
'\"
 
89
.ds pdfmarks
 
90
.if d pdfmarks \{\
 
91
.de pdfmark
 
92
.       specialps exec [\\$1 pdfmark
 
93
..
 
94
'\"
 
95
'\" pdfdest LINKNAME
 
96
'\"
 
97
.de pdfdest
 
98
.pdfmark "/Dest /\\$1 /View [/XYZ -5 PL null] /DEST"
 
99
..
 
100
'\"
 
101
'\" pdfbookmark COUNT LINKNAME STRING
 
102
'\"
 
103
.de pdfbookmark
 
104
.   pdfmark "/View [/XYZ 44 730 1.0] /Count \\$1 /Dest /\\$2 /Title (\\$3) /OUT"
 
105
..
 
106
'\"
 
107
'\"     Define the SH and SS macros to save pdfmark information
 
108
'\"     in "arrays" of numbers and strings.
 
109
'\"
 
110
.if !r rr_n \{\
 
111
.nr rr_n 0 1
 
112
.am SH
 
113
.       nr rr_levels!\\n+[rr_n] 2
 
114
.       ds rr_labels!\\n[rr_n] \\$*
 
115
.       pdfdest Link\\n[rr_n]
 
116
..
 
117
.am SS
 
118
.       nr rr_levels!\\n+[rr_n] 3
 
119
.       ds rr_labels!\\n[rr_n] \\$*
 
120
.       pdfdest Link\\n[rr_n]
 
121
..
 
122
.\}
 
123
'\"
 
124
'\"     Called at the end of the document to generate the pdfmark outline
 
125
'\"
 
126
.de pdf_outline
 
127
.nr rr_levels!\\n+[rr_n] 1
 
128
.nr rr_i 0 1
 
129
.while \\n+[rr_i]<\\n[rr_n] \{\
 
130
.   nr rr_ip1 \\n[rr_i]+1
 
131
.   nr rr_count 0
 
132
.   if \\n[rr_levels!\\n[rr_ip1]]>\\n[rr_levels!\\n[rr_i]] \{\
 
133
.       nr rr_j \\n[rr_i] 1
 
134
.       while \\n+[rr_j]<\\n[rr_n] \{\
 
135
.           if \\n[rr_levels!\\n[rr_j]]<=\\n[rr_levels!\\n[rr_i]] \{\
 
136
.               break
 
137
.           \}
 
138
.           if \\n[rr_levels!\\n[rr_j]]==(\\n[rr_levels!\\n[rr_i]]+1) \{\
 
139
.               nr rr_count \\n[rr_count]+1
 
140
.           \}
 
141
.       \}
 
142
.   \}
 
143
.   ds hhh \\*[rr_labels!\\n[rr_i]]
 
144
.   pdfbookmark \\n[rr_count] Link\\n[rr_i] "\\*[hhh]"
 
145
.\}
 
146
..
 
147
'\"
 
148
'\" Some postscript to make pdfmarks harmless on old interpreters...
 
149
'\"
 
150
.specialps "def /pdfmark where {pop} {userdict /pdfmark /cleartomark load put} ifelse"
 
151
'\"
 
152
'\" Force display of Bookmarks in Acrobat when document is viewed.
 
153
'\"
 
154
.pdfmark "[/PageMode /UseOutlines /Page 1 /View [/XYZ null null null] /DOCVIEW"
 
155
'\"
 
156
'\" Output the document info in pdfmarks
 
157
'\"
 
158
.pdfmark "\
 
159
        /Title (\*[an-title](\*[an-section])) \
 
160
        /Subject (zjsdecode Manual Page) \
 
161
        /Author (Rick Richardson) \
 
162
        /Keywords (printing, ZjStream) \
 
163
        /Creator (groff \n(.x.\n(.y.\n(.Y -man) \
 
164
        /CreationDate (\*[an-extra1]) \
 
165
        /ModDate (\*[an-extra1]) \
 
166
        /DOCINFO"
 
167
\}
 
168
'\"
 
169
'\" The manual page name is only 1st level mark
 
170
'\"
 
171
.nr rr_levels!\n+[rr_n] 1
 
172
.ds rr_labels!\n[rr_n] \*[an-title](\*[an-section])
 
173
.pdfdest Link\n[rr_n]
 
174
'\"==========================================================================
 
175
'\"     MANUAL PAGE SOURCE
 
176
'\"==========================================================================
 
177
.SH NAME
 
178
xqxdecode \- Decode a XQX stream into human readable form.
 
179
.SH SYNOPSIS
 
180
.B xqxdecode
 
181
.RI [ options "] <" zjs-file
 
182
.SH DESCRIPTION
 
183
.B xqxdecode
 
184
decodes a XQX stream into human readable form.
 
185
.P
 
186
An XQX stream is the printer langauge used by some HP LaserJet
 
187
printers, such as the HP LaserJet M1005 (MFP).
 
188
 
 
189
.SH COMMAND LINE OPTIONS
 
190
These are the options that can appear on the command line.
 
191
.TP
 
192
.BI \-d\0 basename
 
193
Basename of .pbm file for saving decompressed planes.
 
194
.TP
 
195
.BI \-h
 
196
Print hex file offsets.
 
197
.TP
 
198
.BI \-o
 
199
Print file offsets.
 
200
.TP
 
201
.BI \-D\0 level
 
202
Set Debug level [0].
 
203
 
 
204
.SH EXAMPLES
 
205
Decode an XQX stream file created by foo2xqx.
 
206
 
 
207
.nf
 
208
.ft CW
 
209
$ xqxdecode -h < testpage.xm
 
210
     0: \\033%-12345X@PJL JOB
 
211
    12: @PJL SET JAMRECOVERY=OFF
 
212
    2b: @PJL SET DENSITY=3
 
213
    3e: @PJL SET ECONOMODE=OFF
 
214
    55: @PJL SET RET=MEDIUM
 
215
    69: @PJL INFO STATUS
 
216
    7a: @PJL USTATUS DEVICE = ON
 
217
    93: @PJL USTATUS JOB = ON
 
218
    a9: @PJL USTATUS PAGE = ON
 
219
    c0: @PJL USTATUS TIMED = 30
 
220
   10c: @PJL SET JOBATTR="JobAttr4=20061118160242"
 
221
   10c: XQX_MAGIC, 0x5851582c (,XQX)
 
222
   110: XQX_START_DOC(1), 7 items
 
223
   118:         XQX_0x80000000, 84 (0x54)
 
224
   124:         XQX_0x10000005, 1 (0x1)
 
225
   130:         XQX_0x10000001, 0 (0x0)
 
226
   13c:         XQXI_DMDUPLEX, 0 (0x0)
 
227
   148:         XQX_0x10000000, 0 (0x0)
 
228
   154:         XQX_0x10000003, 1 (0x1)
 
229
   160:         XQXI_END, 3735928559 (0xdeadbeef)
 
230
   16c: XQX_START_PAGE(3), 15 items [Page 1]
 
231
   174:         XQX_0x80000000, 180 (0xb4)
 
232
   180:         XQX_0x20000005, 1 (0x1)
 
233
   18c:         XQXI_DMDEFAULTSOURCE, 7 (0x7)
 
234
   198:         XQXI_DMMEDIATYPE, 1 (0x1)
 
235
   1a4:         XQX_0x20000007, 1 (0x1)
 
236
   1b0:         XQXI_RESOLUTION_X, 600 (0x258)
 
237
   1bc:         XQXI_RESOLUTION_Y, 600 (0x258)
 
238
   1c8:         XQXI_RASTER_X, 9856 (0x2680)
 
239
   1d4:         XQXI_RASTER_Y, 6432 (0x1920)
 
240
   1e0:         XQXI_VIDEO_BPP, 2 (0x2)
 
241
   1ec:         XQXI_VIDEO_X, 4923 (0x133b)
 
242
   1f8:         XQXI_VIDEO_Y, 6432 (0x1920)
 
243
   204:         XQXI_ECONOMODE, 0 (0x0)
 
244
   210:         XQX_0x20000001, 1 (0x1)
 
245
   21c:         XQXI_END, 3735928559 (0xdeadbeef)
 
246
   228: XQX_START_PLANE(5), 4 items
 
247
   230:         XQX_0x80000000, 64 (0x40)
 
248
   23c:         XQX_0x40000000, 0 (0x0)
 
249
   248:         XQXI_BIH(0x40000002)
 
250
                DL = 0, D = 0, P = 1, - = 0, XY = 9856 x 6432
 
251
                L0 = 128, MX = 16, MY = 0
 
252
                Order   = 3  ILEAVE SMID
 
253
                Options = 92  LRLTWO TPDON TPBON DPON
 
254
                51 stripes, 0 layers, 1 planes
 
255
 
 
256
   264:         XQXI_END, 3735928559 (0xdeadbeef)
 
257
   270: XQX_JBIG(7), 110 items
 
258
   2e6: XQX_END_PLANE(6), 0 items
 
259
   2ee: XQX_END_PAGE(4), 0 items
 
260
   2f6: XQX_END_DOC(2), 0 items
 
261
Total size: 110 bytes
 
262
     0: \\033%-12345X@PJL EOJ
 
263
    12: \\033%-12345X
 
264
 
 
265
.ft P
 
266
.fi
 
267
 
 
268
.SH FILES
 
269
.BR /usr/bin/xqxdecode
 
270
.SH SEE ALSO
 
271
.BR foo2xqx-wrapper (1),
 
272
.BR foo2xqx (1)
 
273
.SH "AUTHOR"
 
274
Rick Richardson <rick.richardson@comcast.net>
 
275
.br
 
276
${URLXQX}/
 
277
'/"
 
278
'/"
 
279
'/"
 
280
.em pdf_outline