Yes, this is an extension of my previous colorization question.
I want to create a blank picture object, draw into it, and display it in a canvas. I want to do this to make zooming, scrolling, and saving easier. But, here, my lack of OOP understanding really hits me in the face.
If I add a picture object, which I name MyPic, into the window’s property list (by dragging from the library pane), then try to reference it in the Window’s Open Event, I get a nil object exception. If I try to “new” it or set its width (as in MyPic.width = 2000), I get a “naughty boy, cannot do that” alert. I can create a local picture in the window open event and assign it to the canvas.backdrop but that does now allow scrolling.
I seem to be missing something critical, here. I have been trying to follow the canvas zoom and canvas scroll examples but those are for an existing picture. I am at a loss to deal with a picture that I have created on the fly.
Some hints would really be appreciated.
As a side note, when I try to open those examples in the current Xojo release, many of the properties are highlighted in red. I assume that these represent things that have changed since the example is created. But, I have no idea what to do about them (some are ordinary integers and would not seem to be candidate for update).
Oregon Research Electronics