Re: [OpenJDK 2D-Dev] [9] RFR JDK-8165947: One more page printed before the test page with OpenJDK.

2016-09-26 Thread Jayathirth D V
Hi Prasanta,   Changes are working fine.   Thanks, Jay   From: Prasanta Sadhukhan Sent: Friday, September 23, 2016 10:54 PM To: Philip Race Cc: 2d-dev Subject: Re: [OpenJDK 2D-Dev] [9] RFR JDK-8165947: One more page printed before the test page with OpenJDK.   Yes, sorry. Done http

Re: [OpenJDK 2D-Dev] [9] RFR JDK-8165947: One more page printed before the test page with OpenJDK.

2016-09-23 Thread Prasanta Sadhukhan
Yes, sorry. Done http://cr.openjdk.java.net/~psadhukhan/8165947/webrev.03/ Regards Prasanta On 9/23/2016 10:44 PM, Philip Race wrote: 77 throw new RuntimeException("Banner page is printed"); that message needs to be conditionalized too. -phil On 9/23/16, 10:01 AM, Prasanta

Re: [OpenJDK 2D-Dev] [9] RFR JDK-8165947: One more page printed before the test page with OpenJDK.

2016-09-23 Thread Philip Race
77 throw new RuntimeException("Banner page is printed"); that message needs to be conditionalized too. -phil On 9/23/16, 10:01 AM, Prasanta Sadhukhan wrote: Updated the testcase: http://cr.openjdk.java.net/~psadhukhan/8165947/webrev.02/ Regards Prasanta On 9/23/2016 9:47

Re: [OpenJDK 2D-Dev] [9] RFR JDK-8165947: One more page printed before the test page with OpenJDK.

2016-09-23 Thread Prasanta Sadhukhan
Updated the testcase: http://cr.openjdk.java.net/~psadhukhan/8165947/webrev.02/ Regards Prasanta On 9/23/2016 9:47 PM, Philip Race wrote: The JDK changes are fine but I don't think the test is. It assumes that the system default is no banner page. You need to update the test to check what the

Re: [OpenJDK 2D-Dev] [9] RFR JDK-8165947: One more page printed before the test page with OpenJDK.

2016-09-23 Thread Philip Race
The JDK changes are fine but I don't think the test is. It assumes that the system default is no banner page. You need to update the test to check what the system default is (banner or no banner) and have the tester "expect" whatever that happens to be. -phil On 9/23/16, 8:30 AM, Prasanta

Re: [OpenJDK 2D-Dev] [9] RFR JDK-8165947: One more page printed before the test page with OpenJDK.

2016-09-23 Thread Prasanta Sadhukhan
Hi Phil, Please find the modified webrev: http://cr.openjdk.java.net/~psadhukhan/8165947/webrev.01/ Regards Prasanta On 9/22/2016 11:10 PM, Prasanta Sadhukhan wrote: On 9/22/2016 11:09 PM, Philip Race wrote: OK I see now. The comment should be updated to remove mention of the dialog and

Re: [OpenJDK 2D-Dev] [9] RFR JDK-8165947: One more page printed before the test page with OpenJDK.

2016-09-22 Thread Prasanta Sadhukhan
On 9/22/2016 11:09 PM, Philip Race wrote: OK I see now. The comment should be updated to remove mention of the dialog and explain that instead. But in that case do you still need the "else" in setAttributes? Yes, right. we do not need the else in setAttributes. will update that and comment

Re: [OpenJDK 2D-Dev] [9] RFR JDK-8165947: One more page printed before the test page with OpenJDK.

2016-09-22 Thread Philip Race
OK I see now. The comment should be updated to remove mention of the dialog and explain that instead. But in that case do you still need the "else" in setAttributes? -phil. On 9/22/16, 10:32 AM, Prasanta Sadhukhan wrote: On 9/22/2016 10:59 PM, Philip Race wrote: Your comment refers only

Re: [OpenJDK 2D-Dev] [9] RFR JDK-8165947: One more page printed before the test page with OpenJDK.

2016-09-22 Thread Prasanta Sadhukhan
On 9/22/2016 10:59 PM, Philip Race wrote: Your comment refers only (and explicitly) to the print dialog :- 1484 * printing Banner page through print dialog via setAttributes(). So if we get into that code afterwards why do we need this new code ? The new code is needed because if we

Re: [OpenJDK 2D-Dev] [9] RFR JDK-8165947: One more page printed before the test page with OpenJDK.

2016-09-22 Thread Philip Race
Your comment refers only (and explicitly) to the print dialog :- 1484 * printing Banner page through print dialog via setAttributes(). So if we get into that code afterwards why do we need this new code ? I do see that call to setAttributes() but I am assuming it does not get in

Re: [OpenJDK 2D-Dev] [9] RFR JDK-8165947: One more page printed before the test page with OpenJDK.

2016-09-22 Thread Prasanta Sadhukhan
That's why I call the new code before setAttributes() so that user's selection is not overridden. I put a comment regarding that in the fix. Regards Prasanta On 9/22/2016 10:38 PM, Philip Race wrote: What happens if the application does not display a dialog but instead the application code

Re: [OpenJDK 2D-Dev] [9] RFR JDK-8165947: One more page printed before the test page with OpenJDK.

2016-09-22 Thread Philip Race
What happens if the application does not display a dialog but instead the application code explicitly does this: aset.add(JobSheets.STANDARD); print(aset) ? It appears to me you will over-ride that. -phil. On 9/22/16, 9:54 AM, Prasanta Sadhukhan wrote: Hi Phil, My new code takes care of

Re: [OpenJDK 2D-Dev] [9] RFR JDK-8165947: One more page printed before the test page with OpenJDK.

2016-09-22 Thread Prasanta Sadhukhan
Hi Phil, My new code takes care of the problem when attribute is not set by the user who directly calls PrinterJob.print(). If no print dialog is shown, then print(attr) seems to be called with Null attribute and since noJobSheet was false, it used to print the banner page. I now checked only

Re: [OpenJDK 2D-Dev] [9] RFR JDK-8165947: One more page printed before the test page with OpenJDK.

2016-09-22 Thread Philip Race
This looks wrong to me. Shouldn't the logic look like the one you have earlier in the file ? ie this : 1271 JobSheets jobSheets = (JobSheets)attributes.get(JobSheets.class); 1272 if (jobSheets != null) { 1273 noJobSheet = jobSheets == JobSheets.NONE; 1274 }

Re: [OpenJDK 2D-Dev] [9] RFR JDK-8165947: One more page printed before the test page with OpenJDK.

2016-09-19 Thread Jayathirth D V
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