Associating text annotations with shapes?

I would like to write a plugin to export bezier curves and lines segments from an Acorn image. I have some user-defined properties that I would really like to “attach” to each bezier curve or line segment and have them saved in the .acorn file.

Is there a way to attach such otherwise-opaque-to-Acorn, user-defined properties to a shape (layer?) in Acorn? I would prefer explicit attachment vs something implicit. e.g. a ‘comment’ explicitly attached to the shape/layer vs a hidden text layer that is geographically near the annotated shape. Alternatively, are there stable ids on shapes that I could use to externally associate properties?

For example, in the attached image, I would like to associate some user-defined text with the green and yellow line segments, the blue circle, and each of the curves.

Are there techniques for doing this?


There’s no API for anything like this. If I was to add it, I suppose the API for a shape could be something along the lines of:

- (NSString*)uuid;
-(void)setUserObject:(id)obj forKey:(NSString*)key;

The objects stored would have to be generally serializable- things like dictionaries, arrays, numbers, and strings.

Do you need anything beyond that?

I am not very familiar with the plugin system in Acorn so I don’t know if there are other issues, but that’s the API I was thinking / looking for. My use-case is strings.


Cool. I’ll see what I can do in a future release. VoodooPad had something like this, and exposed a “user defined meta” palette where you could put things in there.