Jehiah Czebotar wrote: > I'm looking for the "right" way to implement layers in my floatcanvas > app that i can turn on/off easily without keeping a list of elements > that i clear from the cavnas.
I've recently added a "Group" object type, which is pretty much like a layer. You can add a bunch of objects to a group, then that group can be added and removed, shown and hidden, etc. http://morticia.cs.dal.ca/doxydocs/FloatCanvas/FloatCanvas/html/df/d44/classfloatcanvas_1_1_float_canvas_1_1_group.html That's a very long URL to the Doxygen docs -- if it doesn't work, go to: http://morticia.cs.dal.ca/doxydocs/FloatCanvas/FloatCanvas/html and navigate from there. > My only requirement is that when layers are turned on i still have an > easy way to save all of them to disk (currently i am using > Canvas._Buffer.SaveFile)? First -- there is a FloatCanvas.SaveAsImage() method (which is pretty much the one-liner above, but I'd use it to protect you from future changes) Now I'm not entirely what you're question is. If they are on, of course they'd show up when you save the buffer. Or do you want a way to to have them saved to an image, but not show up on screen -- that should be possible, but may take a bit of hacking. -Chris -- Christopher Barker, Ph.D. Oceanographer Emergency Response Division NOAA/NOS/OR&R (206) 526-6959 voice 7600 Sand Point Way NE (206) 526-6329 fax Seattle, WA 98115 (206) 526-6317 main reception [EMAIL PROTECTED] _______________________________________________ FloatCanvas mailing list [email protected] http://mail.mithis.com/cgi-bin/mailman/listinfo/floatcanvas
