-
Notifications
You must be signed in to change notification settings - Fork 598
Add a templating component #3
Description
Moved from Google Code issue #20.
A templating component should be added that allows someone to completely define the look of a graph (not its data). This would probably take the form of a loadable bundle, which contains a property list describing the graph, and any media that is needed (eg background images). A user should be able to generate such a bundle with a single call to the CPTGraph class, and generate a new graph from such a bundle with an initializer of CPTGraph (factory method).
The CPTTheme class partially addresses this, although at the moment all stylizing is done in code. This class should be extended to support persisting themes to property list files and bundles.
CPTTheme needs to be able to handle property lists. This need not be so complex. The properties could literally be the properties on the layer classes themselves. The only tricky bit will be how to convert, say, a property list string, into a CPTColor. Perhaps just a simple list/set of keys can be stored that delineate properties for which a conversion should be performed.