Date: Thu, 24 May 2001 09:34:49 -0700
To: "Dr. Jeffrey Race" <jrace@attglobal.net>
From: <removed at sender's request>
Subject: Re: IBM Redbook problem

This is a free Windows command-line program. It removes one specific 
backward-compatibility problem between Acrobat 4 Distiller and Acrobat 3 
Reader. The symptom of this problem is the message "Could not find the 
ColorSpace named 'Cs9'" or Cs6, etc.

The program will either leave your PDF file unchanged, or will do minimal 
changes to remove this specific problem. If it helps you, great. If your 
PDF file has any other problem or uses any other Acrobat 4 (PDF 1.3) 
feature, it won't help that.

Disclaimer: This program is not sponsored by my employer. It was written 
from the language description in the PDF Reference Manual, and contains no 
Adobe source code, libraries, or other technology. It is 500 lines of C 
that I wrote it one weekend to solve a specific problem I had.
--------------------


Usage: fixpdf4 <input PDF file name> [<output PDF file name>]
	Default output for foo.pdf is foo3.pdf

/***

This converts foo.pdf from PDF-1.3 to PDF-1.2, removing the "Cs6" problem

   Could not find the ColorSpace named 'Cs6'.

input:
   PDF file with gratuitous iccbased color profile

output:
   PDF file without gratuitous iccbased color profile

	1. find each "[ /ICCBased xxx yyy R ]",
	2. find object xxx yyy obj<< /N 3 /Alternate /DeviceRGB ...
	3. If N==1, replace "[ /ICCBased xxx yyy R ]" with "/DeviceGray"
	   If N==3, replace "[ /ICCBased xxx yyy R ]" with "/DeviceRGB"
	   If N==4, replace "[ /ICCBased xxx yyy R ]" with "/DeviceCMYK"
	4. Use enough blanks to exactly preserve length, thus no need to update 
xref table
***/


