Java: haz que un color específico sea transparente

Is it possible to make one specific color transparant in a JFrame?

I know that it is possible in VB.NET, but I would like to know it whether or not it is possible in Java!

For example: My JFrame has a red backgroundcolor and I want for only that red color to become transparent, so that where that red fue, I see the behind laying form/desktop.

Hope someone can help, because I'm stuck!

preguntado el 04 de julio de 12 a las 08:07

1 Respuestas

Podrías usar

com.sun.awt.AWTUtilities.setWindowShape(Window, Shape)

with a custom Shape implementation that contains only points whose color is different from your specific color.

Respondido 04 Jul 12, 09:07

don't forget to mark this answer as answered when it helped you :) - Kees Sonnema

No es la respuesta que estás buscando? Examinar otras preguntas etiquetadas or haz tu propia pregunta.