Hi!
After having discussed yesterday with Yuriy, I gave a try at having multiple selection in Roassal. If you update Roassal, you can try:
-=-=-=-=-=-=-=-=-=-=-=-= b := RTMondrian new. b nodes: Collection withAllSubclasses. b layout flow. b normalizer normalizeSize: #numberOfMethods.
b build.
"Adding a label" labelShape := RTLabel new text: 'Nothing selected'. label := labelShape element. b view add: label. TRConstraint move: label below: b view elements.
"Changing the label according to the selection" b view elements @ (RTSelectable new selectionCallback: [ :es | label trachelShape text: es size asString, ' selected elements']).
b view -=-=-=-=-=-=-=-=-=-=-=-=
Try clicking on the square and the white background.
Wouldn’t it be nice to connect this with GTInspector?
Cheers, Alexandre
This is cool!
It would be also interesting to add marquee selection support and synchronized movement. But those are probably more advanced problems.
Peter
On Tue, Mar 3, 2015 at 3:35 PM, Alexandre Bergel alexandre.bergel@me.com wrote:
Hi!
After having discussed yesterday with Yuriy, I gave a try at having multiple selection in Roassal. If you update Roassal, you can try:
-=-=-=-=-=-=-=-=-=-=-=-= b := RTMondrian new. b nodes: Collection withAllSubclasses. b layout flow. b normalizer normalizeSize: #numberOfMethods.
b build.
"Adding a label" labelShape := RTLabel new text: 'Nothing selected'. label := labelShape element. b view add: label. TRConstraint move: label below: b view elements.
"Changing the label according to the selection" b view elements @ (RTSelectable new selectionCallback: [ :es | label trachelShape text: es size asString, ' selected elements']).
b view
Try clicking on the square and the white background.
Wouldn’t it be nice to connect this with GTInspector?
Cheers, Alexandre -- _,.;:~^~:;._,.;:~^~:;._,.;:~^~:;._,.;:~^~:;._,.;: Alexandre Bergel http://www.bergel.eu ^~:;._,.;:~^~:;._,.;:~^~:;._,.;:~^~:;._,.;:~^~:;.
Moose-dev mailing list Moose-dev@iam.unibe.ch https://www.iam.unibe.ch/mailman/listinfo/moose-dev