TCLUG Development Archive
[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index]

Re: [TCLUG-DEVEL:174] AWT



Bob Tanner <tanner@real-time.com> writes:

> Quoting Jon Schewe (jpschewe@eggplant.mtu.net):
> > Create a Panel that draws an image in the background and then just add things
> > to the panel.
> > 
> > Here's one I use frequently, but it uses Swing, MUCH better than AWT.  It's
> > based on AWT, but is lighter weight.
> 
> Thanks, I love code examples!
> 
> I must use AWT, I need to say JDK 1.0 compliant.

You can do something similar with AWT, or you can just include the swing jar
and use JDK1.0.  With AWT you'll need to override the paint method of the
Panel to do a drawImage.  I've done it before, that's what this one is based
off of.  I can't remember what I did with the code examples.


-- 
Jon Schewe 
http://eggplant.mtu.net/~jpschewe
schewe@tcfreenet.org