Skip to main content

Using LookAndFeelAddons to manage non-SwingX addons

2 replies [Last post]
kschaefe
Offline
Joined: 2006-06-08

I am using LookAndFeelAddons to manage custom components with UI delegates for non-SwingX components. It works extremely well. Thank you. Having a well-written and reusable manager is great (especially when I didn't have to write it).

I would like to be able to distribute, just the portions of SwingX that I need with my project. I do not understand the licence enough to know if I am able to package, just some of the classes in a seperate jar for download. Can anyone clue me in on this?

I have, to test the feasibility of doing so, created an addons.jar that I am currently testing with. This jar is ~14K and contains only the LookAndFeelAddons code. I have discovered that I am required to include org.jdesktop.swingx.plaf.resources.swingx.properties in the jar to prevent errors from the call to LookAndFeelAddons.addDefaultResourceBundle in the LookAndFeelAddons static initializer.

Just in case anyone is wondering here are the files that I included in my custom addons.jar. This seems to be the complete set necessary to utilize LookAndFeelAddons outside of SwingX.
org/jdesktop/swingx/util/OS.class
org/jdesktop/swingx/plaf/motif/MotifLookAndFeelAddons.class
org/jdesktop/swingx/plaf/windows/WindowsClassicLookAndFeelAddons.class
org/jdesktop/swingx/plaf/basic/BasicLookAndFeelAddons.class
org/jdesktop/swingx/plaf/resources/swingx.properties
org/jdesktop/swingx/plaf/windows/WindowsLookAndFeelAddons.class
org/jdesktop/swingx/plaf/macosx/MacOSXLookAndFeelAddons.class
org/jdesktop/swingx/plaf/AbstractComponentAddon.class
org/jdesktop/swingx/plaf/metal/MetalLookAndFeelAddons.class
org/jdesktop/swingx/plaf/LookAndFeelAddons$1.class
org/jdesktop/swingx/plaf/LookAndFeelAddons$UpdateAddon.class
org/jdesktop/swingx/plaf/LookAndFeelAddons.class
org/jdesktop/swingx/plaf/ComponentAddon.class

Reply viewing options

Select your preferred way to display the comments and click "Save settings" to activate your changes.
rbair
Offline
Joined: 2003-07-08

> I am using LookAndFeelAddons to manage custom
> components with UI delegates for non-SwingX
> components. It works extremely well. Thank you.
> Having a well-written and reusable manager is great
> (especially when I didn't have to write it).

Cool!

> I would like to be able to distribute, just the
> portions of SwingX that I need with my project. I do
> not understand the licence enough to know if I am
> able to package, just some of the classes in a
> seperate jar for download. Can anyone clue me in on
> this?

That should be fine. The way the license works, if you create a derivitive work, then you have to release that derivitive under the LGPL (or maybe some other compatible license like GPL, but I'm not sure). However, any code that "links" into this code doesn't have to be LGPL'd.

As always, I'm not a lawyer, but that is my understanding.

> Just in case anyone is wondering here are the files
> that I included in my custom addons.jar. This seems
> to be the complete set necessary to utilize
> LookAndFeelAddons outside of SwingX.
> org/jdesktop/swingx/util/OS.class
> org/jdesktop/swingx/plaf/motif/MotifLookAndFeelAddons.
> class
> org/jdesktop/swingx/plaf/windows/WindowsClassicLookAnd
> FeelAddons.class
> org/jdesktop/swingx/plaf/basic/BasicLookAndFeelAddons.
> class
> org/jdesktop/swingx/plaf/resources/swingx.properties
> org/jdesktop/swingx/plaf/windows/WindowsLookAndFeelAdd
> ons.class
> org/jdesktop/swingx/plaf/macosx/MacOSXLookAndFeelAddon
> s.class
> org/jdesktop/swingx/plaf/AbstractComponentAddon.class
> org/jdesktop/swingx/plaf/metal/MetalLookAndFeelAddons.
> class
> org/jdesktop/swingx/plaf/LookAndFeelAddons$1.class
> org/jdesktop/swingx/plaf/LookAndFeelAddons$UpdateAddon
> .class
> org/jdesktop/swingx/plaf/LookAndFeelAddons.class
> org/jdesktop/swingx/plaf/ComponentAddon.class

If you'd like to submit a patch to the swingx build.xml file, I can apply it. It would be nice to have an ant target that spits this addons.jar out automatically. We could even add it to the continuous builds and weekly builds.

Thanks
Richard

kschaefe
Offline
Joined: 2006-06-08

> If you'd like to submit a patch to the swingx
> build.xml file, I can apply it. It would be nice to
> have an ant target that spits this addons.jar out
> automatically. We could even add it to the continuous
> builds and weekly builds.
The patch is in. Thanks for your help.

Karl