On 24.09.2008, at 21:03, Stéphane Ducasse wrote:
Hi
I'm reading innocuousName allKnownNames allSubmorphNamesDo:
and friends
It seems to me that Morph submorph elements could be given names from the user interface and this would define automatically instance variables or something like that with the given name.
And this has even been used to find morphs to send messages to. Because, besides "findA:" and "submorphThat:", there is even: submorphNamed: in CodeHolder, there is this wonderful piece of code: buttonWithSelector: aSelector "If receiver has a control button with the given action selector answer it, else answer nil. morphic only at this point" | aWindow aPane | ((aWindow := self containingWindow) isSystemWindow) ifFalse: [^nil]. (aPane := aWindow submorphNamed: 'buttonPane') ifNil: [^nil]. ^aPane submorphThat: [:m | (m isKindOf: PluggableButtonMorph) and: [m actionSelector == aSelector]] ifNone: [^nil] ;-) Marcus -- Marcus Denker -- denker@iam.unibe.ch http://www.iam.unibe.ch/~denker