[gs-commits] rev 11827 - trunk/gs/base

ken at ghostscript.com ken at ghostscript.com
Wed Oct 20 14:45:48 UTC 2010


Author: ken
Date: 2010-10-20 14:45:48 +0000 (Wed, 20 Oct 2010)
New Revision: 11827

Modified:
   trunk/gs/base/gdevpdfb.h
   trunk/gs/base/gdevpdfp.c
   trunk/gs/base/gdevpdfx.h
Log:
Add a new switch to ps2write, working title 'ProduceDSC'. This will be used to control
whether the output of ps2write is DSC-compliant or not.

No differences expected.


Modified: trunk/gs/base/gdevpdfb.h
===================================================================
--- trunk/gs/base/gdevpdfb.h	2010-10-20 10:59:23 UTC (rev 11826)
+++ trunk/gs/base/gdevpdfb.h	2010-10-20 14:45:48 UTC (rev 11827)
@@ -125,6 +125,7 @@
  0 /*false*/,			/* ResourcesBeforeUsage */
  1 /*true*/,			/* HavePDFWidths */
  0 /*false*/,			/* HaveStrokeColor */
+ 0 /*true*/,			/* ProduceDSC */
  1 /*true*/,			/* HaveTransparency */
  0 /*false*/,			/* PatternImagemask */
  0 /*false*/,			/* PDFX */

Modified: trunk/gs/base/gdevpdfp.c
===================================================================
--- trunk/gs/base/gdevpdfp.c	2010-10-20 10:59:23 UTC (rev 11826)
+++ trunk/gs/base/gdevpdfp.c	2010-10-20 14:45:48 UTC (rev 11827)
@@ -84,6 +84,7 @@
 
 	/* Target viewer capabilities (Ghostscript-specific)  */
  /* pi("ForOPDFRead", gs_param_type_bool, ForOPDFRead),			    pdfwrite-only */
+    pi("ProduceDSC", gs_param_type_bool, ProduceDSC),
     pi("PatternImagemask", gs_param_type_bool, PatternImagemask),
     pi("MaxClipPathSize", gs_param_type_int, MaxClipPathSize),
     pi("MaxShadingBitmapSize", gs_param_type_int, MaxShadingBitmapSize),
@@ -398,6 +399,11 @@
     }
     if (ecode < 0)
 	goto fail;
+
+    if (pdev->is_ps2write && (code = param_read_bool(plist, "ProduceDSC", &pdev->ProduceDSC)) < 0) {
+	param_signal_error(plist, param_name, code);
+    }
+
     /* PDFA and PDFX are stored in the page device dictionary and therefore
      * set on every setpagedevice. However, if we have encountered a file which
      * can't be made this way, and the PDFACompatibilityPolicy is 1, we want to

Modified: trunk/gs/base/gdevpdfx.h
===================================================================
--- trunk/gs/base/gdevpdfx.h	2010-10-20 10:59:23 UTC (rev 11826)
+++ trunk/gs/base/gdevpdfx.h	2010-10-20 14:45:48 UTC (rev 11827)
@@ -436,6 +436,7 @@
     bool ResourcesBeforeUsage; /* PS2WRITE only. */
     bool HavePDFWidths;        /* PS2WRITE only. */
     bool HaveStrokeColor;      /* PS2WRITE only. */
+    bool ProduceDSC;	       /* PS2WRITE only. */
     bool HaveTransparency;
     bool PatternImagemask; /* The target viewer|printer handles imagemask 
 			      with pattern color. */



More information about the gs-commits mailing list