Hi all,
I am trying to understand how to use the MOForms builder in the following script in the context of a FAMIXClassGroup
view shape rectangle height: [ :cls | cls numberOfMethods ]; width: [ :cls | cls numberOfAttributes ]; ].
view nodes: self entities forEach: [:each | | builder | view shape rectangle.
builder := MOFormsBuilder new. builder column ; fill. builder row; fill ; row ; fill. builder x: 1 y: 1 add: MORectangleShape new. builder x: 1 y: 1 add: (MOLabelShape new text: [ :e | e name ]). builder x: 1 y: 2 add: (self viewMethodsForClass: each onView: view). view layout: builder asLayout. ]. view edges: self entities from: [ :cls | cls superclass ]. view treeLayout
where the method #viewMethodsForClass:onView: is as follows:
viewMethodsForClass: class onView: view view shape rectangle. ^view node: class forIt: [ view shape rectangle. view nodes: class methods. view gridLayout.]
What I would like to get is, for each class, a composite figure with - a label on top - a composite figure where each subfigure represent a method Ideally the label and the composite should also be centrally aligned.
However, with my script I get figure attached.
Thanks!
Marco