changeset 6457:e280fc2f1d74

8016737: After clicking on "Print UNCOLLATED" button, the print out come in order 'Page 1', 'Page 2', 'Page 1' Reviewed-by: jchen, prr
author jgodinez
date Tue, 09 Jul 2013 13:05:33 -0700
parents b2c2cbad0d1d
children 311956930113
files src/solaris/classes/sun/print/IPPPrintService.java src/solaris/classes/sun/print/UnixPrintServiceLookup.java
diffstat 2 files changed, 14 insertions(+), 1 deletions(-) [+]
line wrap: on
line diff
--- a/src/solaris/classes/sun/print/IPPPrintService.java	Tue Jul 09 14:50:54 2013 +0100
+++ b/src/solaris/classes/sun/print/IPPPrintService.java	Tue Jul 09 13:05:33 2013 -0700
@@ -1029,7 +1029,16 @@
             // now supports collation and that most OS has a way
             // of setting it, it is a safe assumption to just always
             // include SheetCollate as supported attribute.
-            catList.add(SheetCollate.class);
+
+            /*
+               In Linux, we use Postscript for rendering but Linux still
+               has issues in propagating Postscript-embedded setpagedevice
+               setting like collation.  Therefore, we temporarily exclude
+               Linux.
+            */
+            if (!UnixPrintServiceLookup.isLinux()) {
+                catList.add(SheetCollate.class);
+            }
         }
 
         // With the assumption that  Chromaticity is equivalent to
--- a/src/solaris/classes/sun/print/UnixPrintServiceLookup.java	Tue Jul 09 14:50:54 2013 +0100
+++ b/src/solaris/classes/sun/print/UnixPrintServiceLookup.java	Tue Jul 09 13:05:33 2013 -0700
@@ -123,6 +123,10 @@
         return osname.equals("SunOS");
     }
 
+    static boolean isLinux() {
+        return (osname.equals("Linux"));
+    }
+
     static boolean isBSD() {
         return (osname.equals("Linux") ||
                 osname.contains("OS X"));