"Nesting and composed shape”. Not really a new topic isn’t it?
I have worked on a way to indicate where in a composed shape inner elements can be inserted.
-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-= | v | v := RTView new. v @ RTDraggableView.
shape := RTMultiCompositeShape new. shape add: RTLabel new. shape add: (RTBox new size: 20; color: (Color blue alpha: 0.3)).
es := shape elementsOn: RTShape withAllSubclasses. v addAll: es.
es do: [ :e | methodElements := RTBox new elementsOn: e model methods. RTGridLayout on: methodElements. RTNest new on: e inShape: #second nest: methodElements layout: #vertical. v addAll: methodElements. ].
RTFlowLayout on: es. es @ RTDraggable. v open -=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=
The call of RTNest, indicated in bold, is the new thing. The #vertical says we what to have the two shapes added to RTMultiCompositeShape have to use a vertical layout.
Here is the result:
Any comment?
Cheers, Alexandre