Sunday, August 10, 2008

Decorator Update

Thanks to some input from a few users, the AbstractComponentDecorator has been updated to fix a few visual and behavior artifacts.

Get the latest from Sourceforge SVN.

The decorator component allows you to apply arbitrary decorations to a component without affecting its layout or (necessarily) response to events.

This blog has many different examples of usage beyond simple decorations, including drag images and per-component input blocking.

2 comments:

Chiss said...

Great stuff!

How would you compare your decorator to the JXLayer project? I'm not that familiar with it, just skimmed through the project site and both seem to accomplish similar things... Thanks again!

technomage said...

Their goals overlap to a large extent. The decorator does things JXLayer can not, and the converse is probably true.

The primary architectural difference is that JXLayer must be inserted into your layout hierarchy, which may or may not require changes to your layout management.

Functionally, because JXLayer is an actual component, the decoration bounds provided by JXLayer are limited to the component bounds.

See other entries in this blog for the range of applications the decorator has outside simple component decoration (input blocking wait indicator, drop target animation, etc).