Hmmm... you may have some difficulty with this. In Eterm, for example,
(not Java, I know, but it's a good example of this) the application
basically just queries the root window of the display for its
background, gets a clip region of the background based on the
application's geometry and such, and sets its own background to be that
clip region, creating the illusion of transparency.

Probably the easiest way to do it from Java would be via JNI, but you
can't do that with applets usually. You might be able to get it to work
with a signed applet, but I'm not sure how you'd deal with delivering
the native library (and then you have the headache of porting the native
code to whatever platforms you want to support). 

Before giving up on it, though, you might want to look at the Toolkit
class and see if it has any methods that can get the root window
background (I've never checked).

--Jeff



"Roll, Greg" wrote:
> 
> Hi All,
> 
> Anyone know if there a way to set an applets background color to be
> transparent?
> 
> Greg E. Roll
> 
> BT Office Products Intl.
> Interface/Conversions Team
> phone - (817) 323-1300 ext. 2921
> e-mail  - [EMAIL PROTECTED]
> 
>   ------------------------------------------------------------------------
>                      Name: Tech Tools.gif
>    Tech Tools.gif    Type: GIF Image (image/gif)
>                  Encoding: base64

-- 
Jeff Galyan
http://www.anamorphic.com
http://www.sun.com
jeffrey dot galyan at sun dot com
talisman at anamorphic dot com
Sun Certified Java(TM) Programmer
======================================================================
Linus Torvalds on Microsoft and software development:
"... if it's a hobby for me and a job for you, why are you doing such a
shoddy job of it?"

The views expressed herein do not necessarily reflect those of my
employer.

Sun Microsystems, Inc., has no connection to my involvement with the
Mozilla Organization.


----------------------------------------------------------------------
To UNSUBSCRIBE, email to [EMAIL PROTECTED]
with a subject of "unsubscribe". Trouble? Contact [EMAIL PROTECTED]

Reply via email to