> This is a large concern in general in that we don't want to force all the components to manage their
> resources in a common directory like this. As an alternative, would it be possible to have each
> component include their own resources in a "well-known" location (configurable in the build
> somehow) instead, and have the build copy all the images to a staging directory for generation
> into a sprite image? So for example, use the following structure in svn:
>
> sparkle/component/slider/src/org/icefaces/component/slider
> sparkle/component/slider/resources/org.icefaces.component.slider
I don't understand this point very well. Maybe I didn't explain myself clearly in the first place. It is not the case that all source files (images, css) for all components, for all skins, are inside the same directory without any order or structure. The old structure was preserved: one subdirectory for each skin, and, inside this directory, each component has its own directory. All what was done was to move all these skin subdirectories inside the '/src' directory so that ant had a single starting point to check for changes under that directory, recursively.
Having sprite source files scattered in different locations would be more difficult for both, ant and smartsprites, to locate them, check for changes, etc.
I wonder if this clarifies the concern or if a different structure is preferred.
> We would also like the ability to somehow specify a specific set of components to include in a
> sprite image, as well as the current / default behavior of all the components under the build dir.
> The idea is to be able to support 3rd party component development using the same build system, etc.
This is possible to do with smartsprites, but it would be very tricky to try to apply the "smarter" build task (i.e. rebuild only when there are changes) to it since there would be just too many possible combinations of components. We could provide this as a separate utility task that takes the names of the components to include as parameters, and then, following directory conventions, locates all the necessary resources to build the sprites.
> Also, I don't see how you are distinguishing between image resources that should be x-axis
> repeated, y-axis , or neither. Is this automatically determined from the CSS?
The CSS file under the '/base' subdirectory defines these three different sprite images (sprite, sprite-x, and sprite-y). Then, all other CSS files in the component subdirectories reference these sprite images by their id's in order to include images in them.
> We would like 'ant clean' to remove the cache.properties file also to ensure that clean is clean in all cases.
Alright, no problem.
Some reference material in the original sprite JIRA:
http://jira.icefaces.org/browse/ICE-1896