From 21bd8378d7c7c5bc986eaee21775c02265432c40 Mon Sep 17 00:00:00 2001 From: jgodinez Date: Wed, 10 Jul 2013 11:49:04 -0700 Subject: [PATCH] 8016737: After clicking on "Print UNCOLLATED" button, the print out come in order 'Page 1', 'Page 2', 'Page 1' Reviewed-by: jchen, prr --- src/solaris/classes/sun/print/IPPPrintService.java | 11 ++++++++++- .../classes/sun/print/UnixPrintServiceLookup.java | 4 ++++ 2 files changed, 14 insertions(+), 1 deletion(-) diff --git a/src/solaris/classes/sun/print/IPPPrintService.java b/src/solaris/classes/sun/print/IPPPrintService.java index 1c441bd19..dea623741 100644 --- a/src/solaris/classes/sun/print/IPPPrintService.java +++ b/src/solaris/classes/sun/print/IPPPrintService.java @@ -1029,7 +1029,16 @@ public class IPPPrintService implements PrintService, SunPrinterJobService { // 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 diff --git a/src/solaris/classes/sun/print/UnixPrintServiceLookup.java b/src/solaris/classes/sun/print/UnixPrintServiceLookup.java index c682634b7..2c2a64062 100644 --- a/src/solaris/classes/sun/print/UnixPrintServiceLookup.java +++ b/src/solaris/classes/sun/print/UnixPrintServiceLookup.java @@ -123,6 +123,10 @@ public class UnixPrintServiceLookup extends PrintServiceLookup return osname.equals("SunOS"); } + static boolean isLinux() { + return (osname.equals("Linux")); + } + static boolean isBSD() { return (osname.equals("Linux") || osname.contains("OS X")); -- GitLab