JDK-7043845 : Robot should be able take screenshots with translucent windows
  • Type: Bug
  • Component: client-libs
  • Sub-Component: java.awt
  • Affected Version: 6,7,8,9
  • Priority: P2
  • Status: Closed
  • Resolution: Cannot Reproduce
  • OS: generic,linux,solaris
  • CPU: generic,x86
  • Submitted: 2011-05-11
  • Updated: 2016-04-28
  • Resolved: 2015-10-05
Related Reports
Duplicate :  
Duplicate :  
Duplicate :  
Duplicate :  
Relates :  
Relates :  
Relates :  
Relates :  
Relates :  
Relates :  
Relates :  
Relates :  
With 7043455 the fix for 6903034 has been backed out because otherwise the Robot is unstable.

We should find a better solution for taking screenshots with transparent windows.
The JCK view of the problem is described in #7029560

Cannot reproduce anymore. Tested on Ubunu 14.04, OEL 7.1, Solaris 10

P2 as a TCK-RED

RULE javax/swing/JComponent/6683775/bug6683775.java Exception java.lang.RuntimeException: Transparent frame is not transparent! RULE java/awt/Frame/ShapeNotSetSometimes/ShapeNotSetSometimes.java Exception java.lang.RuntimeException: Test failed. The shape has not been applied.

RULE java/awt/Window/TranslucentJAppletTest/TranslucentJAppletTest.java Exception java.lang.RuntimeException: Test FAILED: frame pixel at (0, 0) is not transparent

Swing_JInternalFrame/Manual/InternalFrameLAFDemo also refers to that ticket, according to comment (http://aurora.ru.oracle.com/functional/faces/RunDetails.xhtml?names=316342.ManualSubmit-1)

You have approval to defer the following issues. Please update. Cheers, B.

jdk8: SQE ok to defer!

This Robot functionality just not implemented, and it is still unclear how it can be resolved.

EVALUATION With a fix suggested with 6903034, when taking a screenshot only once, this usually works great. However, the second call to getPixelColor() or getScreenCapture() will produce gray rectangles where window images are expected. It looks like we either incorrectly use the overlay composite window, or should perform the task some other way. This needs to be investigated.