You are on page 1of 1

%! % PostScript program for distilling and combining an entire folder or % directory of PostScript files.

% When embedding font subsets, it is highly recommended you use this technique % to distill multiple PS files so only one font subset is used for each font. /PathName (Macintosh HD:Test:*.ps) def /RunDir { { /mysave save def file dup = flush RunFile clear cleardictstack mysave restore } 255 string filenameforall } def PathName RunDir % % % % % % % % % % % % % % x % % % INSTRUCTIONS 1. Place all PostScript files to be distilled and concatenated in a single directory. For example, here are example names of PS files that might be used to distill a book: ac001.ps bt001.ps ch001.ps ch002.ps ch003.ps in001.ps Cover Table of Contents Chapter 1 Chapter 2 Chapter 3 Index % Edit this to point to the folder % containing the PS files.

% Uses PathName variable on the operand stack % Performs a save before running the PS % % % % Shows name of PS file being run Calls built in Distiller procedure Cleans up after PS file Restores save level

2. Make a copy of this file and give it the name you want to have as the prefi for the resulting file. For example, you could name this file MyBook.txt. IMPORTANT: Don't use the .ps suffix if this file is in the same folder as the

% rest of your .ps files. The RunDir command will execute all files that end i n % .ps and this file will be distilled twice! % % 3. Redefine the variable "PathName" above to point to the folder/directory whi ch % contains your PS files. % % Macintosh pathname syntax: /PathName (Macintosh HD:Folder:*.ps) def % Windows pathname syntax: /PathName (c:/mydir/*.ps) def % UNIX pathname syntax: /PathName (.\\/mydir\\/*.ps) def % % Note: The syntax for Windows may look strange, but double escaping the % backslash character is required when using filenameforall. % % 4. Distill the file on the machine running Acrobat Distiller.

You might also like