[REBOL] Re: help? dynamic images
From: greggirwin:mindspring at: 28-Oct-2001 23:18
<< The thing is, in your case it seems that the name of the face is known.
Nope, it isn't. I created a style and in that style I defined an engage
function. The engage function passes you the face that got the event, so I
just pass that on to my function that removes the faces.
<< Your comment about "multiple related faces" seems intriguing... and more
along the lines of what I seek. Can you say more? >>
Sure. Let's use a generic paint program example where the only tool in the
toolbox is a line tool. When you draw a line I'd take the two end-points and
create a line object using a small box face for each end-point. I create
those two faces and append them to the parent face, storing references to
them in my line object, which is put into a block of line objects. When you
delete an end-point, I scan through my block of line objects to find the
line object it belongs to. Once I know which line object I'm after, I can
remove the object from the block of lines and all the faces (two in this
case) it references.