问题
I want to implement a screenshot functionality like in snipping tool. I can already select a rectangle and make a screenshot, but I this rectangle to be full opacity.
I wonder if there is a function in Swing or AWT which I can use like this:
window.setOpacityAt(Rectangle r, 0.5f);
I hope you got my problem!
回答1:
See How to Create Translucent and Shaped Windows: How to Implement Per-Pixel Translucency.

来源:https://stackoverflow.com/questions/16373327/jwindow-region-opacity