classpath
[Top][All Lists]
Advanced

[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index]

Re: SWING at OJE


From: Rolf W. Rasmussen
Subject: Re: SWING at OJE
Date: Mon, 5 Feb 2001 10:29:40 +0100
User-agent: Mutt/1.2.5i

On Mon, Feb 05, 2001 at 02:08:20AM -0500, Andrew Selkirk wrote:
> Hi,
> 
> I might be insane, but I've started a clean-room JFC implementation
> over at OJE (Open Java Extensions oje.sourceforge.net).  Swing is
> probably one of the most significant hurdles that needs to be tackled in
> order to realize a free alternative to Sun's Java 2 platform.

I've also be working a bit on a clean-room Swing. I've got some basic 
functionality working: JComponent, JLabel, JButton, and 
javax.swing.border. (and L&F delegates for these components)

I've also been trying to implement the javax.swing.text package. I must 
say, working on Swing has been trying. I've often been cursing at the lack 
of proper documentation and wondering how something like Swing can ever 
become a standard.   

> The current
> status of this codebase is:
>   - the ENTIRE stub base has been generated for javax.swing.  All
>         information was gathered using documentation and java reflection
>         to analyze class structures.  Everything compiles cleanly under
>         jikes (javac is another matter though)

What is the legal status of stubs generated in this way? Is it possible to 
claim to be clean-room, if we extract information using reflection or any 
other automated process that uses the Sun product as a data source?

I've often thought about the amounts of information that can be extracted 
by automated probing of classes using reflection, but I've shyed away from 
it because I didn't want my work to become tainted in any way. Have my 
worries been unfounded? 

>   -  javax.swing.event started
>   -  javax.swing.table started
>   -  I'm studying mounds for documentation for implementing the look
>        and feel subsystem and have started some implementation.
>
> This is definitely not something I can tackle on my own, but I hope by
> starting it I can help bring it another step closer to realization.

I had actually half way given up on the idea of creating an accurate 
reimplementation of Swing. I was discouraged after realizing how poorly 
documented significant portions of Swing was.

Another concern was that Swing reimplements a lot that is better handled at 
using low-level libraries. Consider text components. These should support 
I18N, Bidi, complex scripts, shaping, input methods, etc. These things are 
best handled by a low-level library such as Pango. And don't get me started 
on the evils of JDesktopPane and JInternalFrame.

The worst problem with Swing is that it appears like a work in progress 
where the line between public API and private implementation is muddled. 
Actually, I think Sun is digging themselves a hole, since I can't see how 
Swing can be improved without breaking existing applications.

OK, I'm done ranting...

> All code at OJE is licensed under LGPL.  The source is not readily
> available from the web page yet, but is accessible through anonymous
> cvs under the 'source' module (Checkout out CVS access from the
> project page).  If you want to help out, send me a source forge account
> name and I'll sign you up.

If you'd like, I can give you the code I have (LGPL), and give you a 
helping hand. However, I don't really have much time to spare lately.

-- 
Rolf W. Rasmussen
               Emulating/reimplementing window managers in Java... Yuck!



reply via email to

[Prev in Thread] Current Thread [Next in Thread]