I am trying to store persistent data for a paintable canvas. Specifically a background image, but possibly the entire graphics object. Or perhaps I’m coming at it the wrong way…
I’m making an app that shows where various pieces of equipment are located on a map. What I’ve got so far is that the repaint method will check for a locally disk cached version of the image, and redownload it if necessary. Once it’s got the background image, it will go through a list of tags that define the locations of the various pieces of equipment and place markers on the map for each one.
Where it’s not quite working how I like is in the update rate. Clicking buttons to pan and zoom works fine (modifying parameters used to scale and translate the graphics object) but dragging the image to pan is a little laggy. I’d like to skip the disk operation (retrieving the cached image data) and possibly the equipment rendering operation. I don’t see any way to create a custom property with an arbitrary datatype; is this something I can do via scripting? In other words, is there any memory-based storage I can use for arbitrary data that is persistent between repaint events?