[OpenJDK 2D-Dev] RFR: 8240342: Custom composite is ignored when printing an opaque image to a page

2020-03-31 Thread Philip Race
bug: https://bugs.openjdk.java.net/browse/JDK-8240342 webrev : http://cr.openjdk.java.net/~prr/8240342/ The code that determines if we could print an image via platform APIs was not checking for custom composites. The fix is in code used on Linux/Solaris and Windows only. The Mac printing path i

Re: [OpenJDK 2D-Dev] RFR: 8241829 Cleanup the code for PrinterJob on windows

2020-03-31 Thread Sergey Bylokhov
Hi, Prasanta. On 3/30/20 7:46 am, Prasanta Sadhukhan wrote: I guess it is better if you directly pass NULL to OpenPrinter, rather than create an unnecessary variable. That was done only for documentation purposes. Also, I think it will be good if we do a ClosePrinter() if FindFirstPrinterC

Re: [OpenJDK 2D-Dev] RFR: 8240342: Custom composite is ignored when printing an opaque image to a page

2020-03-31 Thread Sergey Bylokhov
Hi, Phil. Why the "AlphaComposite.SRC_OVER" is counted as "non-compositing" mode? 1904 if (alpha != 1.0 1905 || (rule != AlphaComposite.SRC 1906 && rule != AlphaComposite.SRC_OVER)) 1907 { 1908 isCompositing = tr

Re: [OpenJDK 2D-Dev] RFR: 8240342: Custom composite is ignored when printing an opaque image to a page

2020-03-31 Thread Philip Race
On 3/31/20, 4:57 PM, Sergey Bylokhov wrote: Hi, Phil. Why the "AlphaComposite.SRC_OVER" is counted as "non-compositing" mode? This is copied from share/classes/sun/print/PeekMetrics.java. It means that the normal drawing path can handle it. 1904 if (alpha != 1.0 1905

Re: [OpenJDK 2D-Dev] RFR: 8240342: Custom composite is ignored when printing an opaque image to a page

2020-03-31 Thread Sergey Bylokhov
On 3/31/20 5:42 pm, Philip Race wrote: On 3/31/20 1:37 pm, Philip Race wrote: The fix is in code used on Linux/Solaris and Windows only. The Mac printing path is quite different and was not affected. So are you misunderstanding my comment ? Yep, reading your comment I assumed that the code ch