Hi Prasanta,

Changes are working fine.

Thanks,
Jay

-----Original Message-----
From: Prasanta Sadhukhan 
Sent: Friday, September 16, 2016 3:52 PM
To: Philip Race; 2d-dev
Subject: [OpenJDK 2D-Dev] [9] RFR JDK-8165947: One more page printed before the 
test page with OpenJDK.

Hi All,

Please review a fix for a tck failure in jdk9 whereby "banner page" 
(cover page) is printed by default when print() is called directly without any 
print dialog being shown.

Bug: https://bugs.openjdk.java.net/browse/JDK-8165947
webrev: http://cr.openjdk.java.net/~psadhukhan/8165947/webrev.00/

Issue was in RasterPrinterJob, "noJobSheet" variable was set to false which 
when passed to PSPrinterJob#printExecCmd(), it results in adding "-o 
job-sheets=standard" to lpr command and therefore, Banner page was getting 
printed by default.
Proposed fix is to check for defaultAttributeValue for JobSheets attribute so 
that we can find what is the default value reported by underlying platform and 
set "noJobSheet" value to default jobsheet native value (like CUPS report 
job-sheet=none so that no banner page is to be printed by default even though 
it supports jobsheet)

I tested "6575247:Banner checkbox in PrinterJob print dialog doesn't work" 
testcase in windows, solaris, linux and it works as expected.

JCK test api/javax_swing/interactive/PrintTest.html#PrintTest via command 
"/jdk-9/bin/java -showversion 
-Dswing.defaultlaf=com.sun.java.swing.plaf.motif.MotifLookAndFeel -cp
/root/jck/JCK-runtime-9/classes: 
-Djava.security.policy=/root/jck/JCK-runtime-9/lib/jck.policy
javasoft.sqe.tests.api.java.awt.interactive.PrintTest
-platform.hasPrinter true -TestCaseID ALL"
also works ie no banner page is printed by default.

Regards
Prasanta

Reply via email to