This is the mail archive of the
java-discuss@sourceware.cygnus.com
mailing list for the Java project.
Re: AWT
Nathan Meyers <nmeyers@teleport.com> writes:
> Jeff has it right: "heavyweight" means there's a window being used in
> the native system, "lightweight" means the window is entirely virtual
> and exists only in the mind of the X client.
Er, this may be how *you* define heavyweight/lightweight,
and they may be *attributes* of heavyweight/lightweight as
implemented on X, but they are clearly not defining properties
of heavyweight/lightweight when we are talking about Java
- most Java implementation do not use an "X client".
(Note *all* windows are virtual - as far as I know very few X servers
can allocate specific hardware to windows.)
The defining property of heavyweight/lightweight is whether there
is a Peer associated with the component. Period. Whether there
is an X window associated with the Peer is an implementation
issue.
> Say you've got a text field in the middle of your GUI for which you want
> a different mouse cursor than the rest of the GUI: the mouse becomes a
> text cursor when it enters and a default cursor when it leaves. ...
> How does a lightweight toolkit do it? It has to track all mouse movement
> in the application.
Clearly, a pure lightweight approach is inefficient in this case.
(Though how much does it matter these days?) But Swing was restricted
to being Pure Java. If we re-implement Swing, we could use native
X windows where it makes sense.
I don't think we're disagreeing on implementation issues; the main
disagreement is on terminology.
--
--Per Bothner
bothner@pacbell.net per@bothner.com http://home.pacbell.net/bothner/
- Follow-Ups:
- Re: AWT
- From: Nathan Meyers <nmeyers@teleport.com>
- References:
- license question
- From: Paul Matthew Reilly <paul@pajato.com>
- AWT
- From: Lincoln Spiteri <lincoln.spiteri@st.com>
- Re: AWT
- From: "Thomas Reilly" <treilly@allaire.com>
- Re: AWT
- From: Nathan Meyers <nmeyers@teleport.com>
- Re: AWT
- From: Per Bothner <per@bothner.com>
- Re: AWT
- From: Jeff Sturm <jsturm@sigma6.com>
- Re: AWT
- From: Nathan Meyers <nmeyers@teleport.com>