JWindow区域不透明度 [英] JWindow region opacity
本文介绍了JWindow区域不透明度的处理方法,对大家解决问题具有一定的参考价值,需要的朋友们下面随着小编来一起学习吧!
问题描述
我想实现截图工具中的屏幕截图功能.我已经可以选择一个矩形并进行截图了,但是我将此矩形设为完全不透明.
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.
我想知道在Swing或AWT中是否可以使用这样的功能:
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!
推荐答案
请参见如何创建半透明和成形的Windows:如何实现逐像素半透明.
这篇关于JWindow区域不透明度的文章就介绍到这了,希望我们推荐的答案对大家有所帮助,也希望大家多多支持IT屋!
查看全文