|
|
1.1 root 1: .\" (c) Copyright 1986 Xerox Corporation
2: .\" All rights reserved.
3: .TH IPFE 1 6/16/86
4: .UC 4
5: .SH NAME
6: IPFE \- Interpress File Editor
7: .SH SYNOPSIS
8: \fBipfe\fR [ \fIoptions\fR ] \fIinfile\fR [ \fIpagerange\fR ] ...
9: [ \fIinfile\fR [ \fIpagerange\fR ] ... ]
10: .sp 1
11: Options: [\fB\-l \fIlogfile\fR ] [\fB\-dDiLqrRsSY ] [\fB\-a
12: \fIalias:actual\fR [\fB\-a \fIalias:actual\fR ] ...] [\fB\-b
13: \fIbinding-offset:unit\fR ] [\fB\-c
14: \fIchapterize-count:unit\fR ] [\fB\-o \fIoutfile\fR ] [\fB\-p
15: \fIlevel:propfile\fR ] [\fB\-S \fIscale-factor\fR ] [\fB\-X
16: \fIX-offset:unit\fR ] [\fB\-Y \fIY-offset:unit\fR ]
17: .SH DESCRIPTION
18: \fBIPFE\fR performs editing functions on Interpress masters. It
19: reads the specified input Interpress files and writes the
20: designated output file(s). By using page ranges and other options,
21: pagebodies in Interpress masters may be concatenated, merged,
22: split into several output files (i.e., chapterized), etc.
23: .PP
24: Concatenation is accomplished by specifying more than one input
25: master with no pageranges.
26: .PP
27: Page selection and merging is accomplished by specifying more
28: than one master with a pagerange specification for at least one
29: of the masters. This accomplishes simple merging, such as pages 1,
30: 2, and 4 of Master1 merged with pages 2, 4, and 5 of Master2.
31: .PP
32: In addition, a page from one master may be overlaid with pages
33: from other masters to create a single output page. The overlay
34: pages may be repositioned by specifying an xOffset and yOffset.
35: In this manner, graphics or images may be created as Interpress
36: "pages" and then merge/overlaid onto a text page of a different
37: master, with an option to reposition the images.
38: See the \fIinfile\fR [ \fIpagerange\fR ] discussion below, following
39: the options specifications, for syntax details.
40: .PP
41: The following options can be used with \fBipfe\fR:
42: .PP
43: .RS
44: (\fINote:\fR Any option with one or more arguments may be
45: specified as a single option, with no space between the
46: switch and the [first] argument, or as two options, with an
47: unquoted space between the switch and the [first] argument. If
48: there is more than one argument, they must be specified together
49: as a single option, separated by an [usually] optional colon. When
50: the colon is required, it is so indicated in the option description.)
51: .RE
52: .TP
53: \fB\-a \fIalias:actual\fR
54: (alias). If the \fB\-s\fR option is specified, replace any SIF
55: references matching the string \fIalias\fR with the string
56: \fIactual\fR before attempting to satisfy the SIF. The colon
57: between \fIalias\fR and \fIactual\fR is required. There may be
58: spaces and colons in \fIalias\fR (if there are spaces, \fIalias\fR
59: itself must be quoted). However, there must be no colons in
60: \fIactual\fR, because IPFE searches from the end of \fIactual\fR
61: to find the colon separating \fIalias\fR and \fIactual\fR.
62: There may be multiple \fB\-a\fR options. However, if there is no
63: \fB\-s\fR option specified, none of the alias options has any
64: effect.
65: If there is a match on any \fIalias\fR, and the corresponding
66: file \fIactual\fR is not found or there is some error, the
67: original SIF reference, \fIalias\fR, is preserved, unless the
68: \fB\-r\fR option is also specified. In the latter case, the SIF
69: reference is removed.
70: .TP
71: \fB\-b \fIoffset:unit\fR
72: (binding offset). Shift the image \fIoffset units\fR in the
73: x-direction, where \fIunit\fR may be none (default centimeters),
74: \fBc\fR (centimeters), \fBi\fR (inches), \fBp\fR (points), or
75: \fBP\fR(Picas). \fIOffset\fR may be a negative value. If the
76: \fB\-L\fR option is also specified, the image shift is in the
77: y-direction.
78: .TP
79: \fB\-c \fIcount:unit\fR
80: (chapterize). If the size of the output file is larger than
81: \fIcount units\fR, split the output file into multiple files.
82: Chapterization occurs only on page boundaries, every time
83: \fIcount units\fR is reached [where \fIunit\fR may be \fBp\fR
84: (pages), \fBk\fR (kilobytes), or \fBm\fR (megabytes)], and
85: there is no look-ahead. Therefore, if a byte specification
86: is used, the size of each output file may actually be larger
87: than \fIcount units\fR. Output file names are generated
88: by appending "1", "2", etc. to the file extension of
89: \fIoutfile\fR. (\fINote\fR that this is in \fIaddition\fR
90: to the possibility of an integer being appended to the output
91: filename if no \fB\-o\fR option is specified.)
92: .TP
93: \fB\-d\fR
94: (duplex). If the \fB\-b\fR option (binding offset) is specified,
95: apply the offset for duplex (two-sided) printing of the output
96: master. That is, for odd-numbered pages, the offset is applied
97: as specified; for even-numbered pages, the negative of the offset
98: is applied. If there is no binding offset specified, the duplex
99: option has no effect.
100: .IP
101: \fIExample:\fR
102: If there is a binding offset of 2P and the duplex option
103: is specified, odd-numbered pages are shifted 2 Picas to the right,
104: even-numbered pages 2 Picas to the left. If the binding offset is
105: -2P and duplex is specified, odd-numbered pages are shifted 2
106: Picas to the left, even-numbered pages 2 Picas to the right.
107: .TP
108: \fB\-D\fR
109: (Debug). If the \fB\-p\fR option is specified, write to the
110: properties file the offset within the input stream of each
111: skeleton-level token, in addition to the properties information
112: detailed in the \fB\-p\fR option. If there is no \fB\-p\fR
113: option specified, the Debug option has no effect.
114: .TP
115: \fB\-i\fR
116: (insert SIF for overlay). Insert (create) a SIF reference for
117: any unresolvable overlays. (See the discussion on overlays in
118: the \fIinfile\fR [ \fIpagerange\fR ] section below, following
119: the options specifications.) \fINote\fR that if an overlay is
120: unresolvable and the overlay specification includes a pageNum
121: greater than 1, no SIF reference will be created, even if the
122: \fB\-i\fR option is specified.
123: .TP
124: \fB\-l \fIlogfile\fR
125: (log). Open the file \fIlogfile\fR and record a transcript of
126: IPFE actions, error reports, etc. The logfile is opened
127: immediately upon encountering the \fB\-l\fR option in the
128: command line. Therefore, to record errors in the command line
129: specification, the \fB\-l\fR option must be the \fIfirst\fR
130: option specified. If no \fIlogfile\fR is specified, the default
131: filename "ipfe.log" is used.
132: .TP
133: \fB\-L\fR
134: (Landscape). Rotate every output page 90 degrees counterclockwise.
135: IPFE automatically applies an x- and y-image shift to preserve
136: the upper left corner of the image. This option is intended for
137: printing text pages in a landscape orientation.
138: .TP
139: \fB\-o \fIoutfile\fR
140: (output). Write the output Interpress master to the file
141: \fIoutfile\fR. If the \fB\-o \fIoutfile\fR option is \fInot\fR
142: specified, the following algorithm determines the output
143: filename (with one exception, noted below): remove the extension
144: from the filespec of the first \fIinfile\fR and append ".ip",
145: as long as \fIinfilename\fR.ip does not already exist. If it
146: \fIdoes\fR exist, then append "\fIn\fR.ip", where
147: \fIn\fR is the lowest integer that will not cause an existing
148: file to be overwritten.
149: .IP
150: \fINote:\fR
151: If the \fB\-p\fR option is specified with no \fB\-o\fR option,
152: then the properties
153: file is written with no Interpress output master. This allows
154: you to get information about the input stream without the
155: overhead of creating the Interpress output master.
156: .TP
157: \fB\-p \fIlevel:propfile\fR
158: (properties). Open the file \fIpropfile\fR and write the
159: following information about the properties of each input
160: master: the skeleton structure and the number of blocks,
161: pages, and sequenceInsertFile (SIF) references. If there
162: is more than one input file, the total number of blocks,
163: pages, and SIF references are also written. \fILevel\fR
164: may be \fI0\fR (default) or \fI1\fR (verbose); if \fI1\fR,
165: each valid pageBody and endpageBody token is indicated and
166: numbered.
167: In addition, the \fB\-D\fR (Debug) option causes the file
168: position of each skeleton-level token to be written.
169: .IP
170: \fINote\fR that the properties are an accounting of the
171: \fIinput\fR stream.
172: If the properties of the \fIoutput\fR stream are desired, it is
173: necessary to execute a second invocation of \fBipfe\fR on
174: the output file(s) with just the \fB\-p\fR option specified.
175: .TP
176: \fB\-q\fR
177: (quiet). Don't write information and error messages to STDERR.
178: .TP
179: \fB\-r\fR
180: (remove SIFS). Remove sequenceInsertFile (SIF) references
181: from the input stream. If the \fB\-s\fR option is also
182: specified, the \fB\-s\fR option takes precedence, and a SIF
183: reference is removed only if it is either unresolvable
184: or there is some error, such as an invalid header.
185: .TP
186: \fB\-R\fR
187: (Rotate). Rotate every output page 90 degrees clockwise. IPFE
188: automatically applies an x- and y-image shift to preserve
189: the center point of the image. This option is intended for
190: printing an image created for a "landscape printer" in portrait
191: orientation.
192: .TP
193: \fB\-s\fR
194: (satisfy SIFS). Satisfy any sequenceInsertFile (SIF) references
195: encountered in the input stream. This entails replacing the SIF
196: reference with the actual tokens in the referenced file.
197: The algorithm used is dependent upon the SIF type as found in the
198: referenced file's header. If the referenced file is not found or
199: there is some error, such as an invalid header, the SIF
200: reference is preserved, unless the \fB\-r\fR (remove SIF
201: references) is also specified. The Interpress filename alias
202: mechanism is supported via the \fB\-a\fR option.
203: .TP
204: \fB\-S \fIscale-factor\fR
205: (Scale). Scale the image by \fIscale-factor\fR, which can have
206: the format 'n/d', where both n and d must be integers, or 'a.b'.
207: .TP
208: \fB\-X \fIX-offset:unit\fR
209: (xImageShift). Shift the image \fIoffset units\fR in the
210: x-direction, where \fIunit\fR may be none (default centimeters),
211: \fBc\fR (centimeters), \fBi\fR (inches), \fBp\fR (points), or
212: \fBP\fR(Picas). \fIOffset\fR may be a negative value. The
213: x-direction is independent of the \fB\-L\fR and \fB\-R\fR
214: options (i.e., the positive x-direction is still to the right
215: as the image is viewed, even if a rotation is applied).
216: .TP
217: \fB\-Y \fIY-offset:unit\fR
218: (yImageShift). Shift the image \fIoffset units\fR in the
219: y-direction, where \fIunit\fR may be none (default centimeters),
220: \fBc\fR (centimeters), \fBi\fR (inches), \fBp\fR (points), or
221: \fBP\fR(Picas). \fIOffset\fR may be a negative value. The
222: y-direction is independent of the \fB\-L\fR and \fB\-R\fR
223: options (i.e., the positive y-direction is still up as the
224: image is viewed, even if a rotation is applied).
225: .TP
226: \fIinfile \fR[ \fIpagerange\fR ]
227: Each \fIinfile\fR may have a \fIpagerange\fR specification for
228: selecting pages from the \fIinfile\fR to merge and/or overlay.
229: The \fIpagerange\fR specification must immediately follow the
230: corresponding \fIinfile\fR specification to which it applies,
231: as a separate option (i.e., it must not be quoted along with
232: \fIinfile\fR. For shell processing, however, the pagerange
233: specification itself may be quoted in order to use the brackets
234: and parentheses required by the syntax).
235: .IP
236: \fINote:\fR In the syntax below, pageNum refers to a count of
237: pageBodies (excluding the preamble) in the Interpress master,
238: and does not necessarily match the printed page numbers on the
239: output pages. See the references below for a definition and
240: discussion of pageBodies.
241: .IP
242: The syntax for the \fIpagerange\fR specification is given in the
243: following psuedo Backus-Naur Form:
244: .RS
245: .IP
246: pageRange ::= [pageSpec,...,endPageSpec]
247: .IP
248: pageSpec ::= pageNum | pageNum-pageNum |
249: .br
250: pageNum[overlaySpec][...]
251: .IP
252: endPageSpec ::= pageNum- | NULL
253: .IP
254: pageNum ::= integer
255: .IP
256: overlaySpec ::= overlayFileName | overlayFileName:pageNum |
257: .br
258: overlayFileName(xOffset,yOffset) |
259: .br
260: overlayFileName:pageNum(xOffset,yOffset)
261: .RE
262: .sp 1
263: .IP
264: The syntax rules are:
265: .RS
266: .IP 1.
267: The \fIpageRange\fR specification must begin with a left bracket
268: and end with a right bracket ("[\fIpageRangeSpec\fR]").
269: .IP 2.
270: Pages are specified by an integer corresponding to a pageBody
271: count, in increasing order, through the master.
272: .IP 3.
273: A minus ("-") indicates a page range.
274: .IP
275: \fIExample:\fR [4-6] includes pages 4 through 6.
276: .IP 4.
277: A comma separates pages and page ranges.
278: .IP
279: \fIExample:\fR [4,6-9] includes pages 4 and 6 through 9.
280: .IP 5.
281: A minus ("-") appearing after the final page specification
282: includes all pages to the end of the master.
283: .IP
284: \fIExample:\fR [4,6,9-] includes pages 4, 6, and 9 through
285: the last page of the master.
286: .IP 6.
287: Immediately following a page specification, a left/right bracket
288: pair may enclose a filename to indicate an overlay
289: ("[\fIoverlayfile\fR]"). The overlay may be an Interpress master
290: or an Interpress fragment. If the overlay is an Interpress master
291: containing more than one page, and no overlay pageNum is
292: specified, IPFE uses page 1 for the overlay. There may be
293: more than one overlay specification for a page specification,
294: each enclosed in a left/right bracket pair and immediately
295: following one another.
296: .IP
297: \fIExample:\fR [4[pic1][pic2]] includes page 4 and overlays
298: it with pic1 and pic2.
299: .IP 7.
300: Immediately following \fIoverlayfile\fR in an overlay
301: specification, a colon followed by an \fIoverlayPageNum\fR
302: selects a page from \fIoverlayfile\fR for the overlay
303: ("[\fIoverlayfile\fR:\fIoverlayPageNum\fR]").
304: .IP
305: If \fIoverlayfile\fR is an Interpress fragment, or
306: \fIoverlayPageNum\fR doesn't exist, the overlay specification
307: is ignored.
308: .IP
309: \fIExample:\fR [4[pic1:2] includes page 4 and overlays it with
310: page 2 of pic1.
311: .IP 8.
312: Within an overlay specification, a left/right parenthesis pair
313: may enclose a \fIpage offset\fR to reposition the overlay page
314: ("[\fIoverlayfile\fR(\fIxOffset,yOffset\fR)]" or
315: "[\fIoverlayfile\fR:\fIoverlayPageNum\fR(\fIxOffset,yOffset\fR)]").
316: .IP
317: The \fIpage offset\fR has the form \fIxOffset,yOffset\fR
318: and each offset has the form \fIvalue unit\fR. The comma between
319: the offsets is required, and there must be no space between
320: \fIvalue\fR and \fIunit\fR. Unit is one of the following: none
321: (default centimeters), c (centimeters), i (inches), p (points),
322: P (Picas). The origin is the bottom left corner of the page.
323: The positive x-direction is to the right, and the positive
324: y-direction is up. X/y-directions may be positive or negative.
325: .IP
326: \fIExample:\fR [4[pic1:2(2P,4P)][pic2(-3P,-1P)]] includes
327: page 4 and overlays it with page 2 of pic1, offset 2 Picas
328: to the right and 4 Picas up, and pic2, offset 3 Picas to the
329: left and 1 Pica down.
330: .RE
331: .sp 1
332: .IP
333: \fIExample\fR of using a \fIpagerange\fR specification:
334: .IP
335: ipfe infile "[1,4-6,9[pic1],10-11,12[pic2:2(2P,4P)][pic3(-4P,-2P)],15-]"
336: .IP
337: which reads:
338: .RS
339: .IP
340: include page 1,
341: .IP
342: skip pages 2-3,
343: .IP
344: include pages 4-6,
345: .IP
346: skip pages 7-8,
347: .IP
348: include page 9 and overlay it with pic1 (with no offset),
349: .IP
350: include pages 10-11,
351: .IP
352: include page 12 and overlay it with page 2 of pic2
353: (offset 2 Picas to the right and 4 Picas up) and
354: pic3 (offset 4 Picas to the left and
355: 2 Picas down),
356: .IP
357: skip pages 13-14,
358: .IP
359: include pages 15 through the end of the master.
360: .SH AUTHOR
361: Mark Rollins, Xerox Corporation, Webster Research Center, October 1985.
362: .SH SEE ALSO
363: Interpress Electronic Printing Standard, Version 3.0, Xerox Corporation,
364: January 1986, \s8XNSS\s10 048601
365: .br
366: Introduction to Interpress, Xerox Corporation, June 1983, \s8XSIG\s10 038404
367: .br
368: The address for obtaining these documents is:
369: .br
370: Xerox Corporation
371: .br
372: Printing Systems Administration Office
373: .br
374: 701 South Aviation Blvd.
375: .br
376: El Segundo, CA 90245
377: .SH BUGS
378: IPFE assumes that SIF's and overlays are either valid Interpress
379: fragments or Interpress masters containing a single BEGIN/END block.
380: If an Interpress master containing nested blocks is attempted to be
381: used as either a SIF or an overlay, the result may be unpredictable.
382: The most likely error would be the erroneous inclusion of one or
383: more extraneous preambles.
This archive runs on limited infrastructure. Preserving old code on modern bandwidth. Automated agents are requested to crawl responsibly.