Is there anything that might help in order to create a form like UI in spec? Any descriptive way? slot based? magritte? Norbert
2014-03-31 17:51 GMT+01:00 Norbert Hartl <norbert@hartl.name>:
Is there anything that might help in order to create a form like UI in spec? Any descriptive way? slot based? magritte?
I just naïvely tried to do: familyEditor ^ MorphicGenericAdapter morph: ProductFamily new asMagritteMorph but that throws MNU: MAContainerMorph>>layoutFrame: Cheers, Sergi
2014-03-31 22:36 GMT+01:00 Benjamin <benjamin.vanryseghem.pharo@gmail.com>:
On 31 Mar 2014, at 23:34, Sergi Reyner <sergi.reyner@gmail.com> wrote:
Yes, MNU MAContainerMorph>>asSpecAdapter
#asSpecAdapter is implemented on Morph oO
But MAContainerMorph does not inherit from Morph :) Object -> Model -> MADescriptionModel -> MAContainerMorph Cheers, Sergi
2014-03-31 22:40 GMT+01:00 Sergi Reyner <sergi.reyner@gmail.com>:
2014-03-31 22:36 GMT+01:00 Benjamin <benjamin.vanryseghem.pharo@gmail.com> :
On 31 Mar 2014, at 23:34, Sergi Reyner <sergi.reyner@gmail.com> wrote:
Yes, MNU MAContainerMorph>>asSpecAdapter
#asSpecAdapter is implemented on Morph oO
Maybe ProductFamily new asMagritteMorph morph asSpecAdapter But I can't try right now, real life is kicking in :S
On 31 Mar 2014, at 23:46, Sergi Reyner <sergi.reyner@gmail.com> wrote:
2014-03-31 22:40 GMT+01:00 Sergi Reyner <sergi.reyner@gmail.com>: 2014-03-31 22:36 GMT+01:00 Benjamin <benjamin.vanryseghem.pharo@gmail.com>:
On 31 Mar 2014, at 23:34, Sergi Reyner <sergi.reyner@gmail.com> wrote:
Yes, MNU MAContainerMorph>>asSpecAdapter
#asSpecAdapter is implemented on Morph oO
Maybe ProductFamily new asMagritteMorph morph asSpecAdapter
But I can't try right now, real life is kicking in :S
Keep me in touch then :) Ben
On 31 Mar 2014, at 18:40, Sergi Reyner <sergi.reyner@gmail.com> wrote:
2014-03-31 22:36 GMT+01:00 Benjamin <benjamin.vanryseghem.pharo@gmail.com>: On 31 Mar 2014, at 23:34, Sergi Reyner <sergi.reyner@gmail.com> wrote:
Yes, MNU MAContainerMorph>>asSpecAdapter
#asSpecAdapter is implemented on Morph oO
But MAContainerMorph does not inherit from Morph :)
Object -> Model -> MADescriptionModel -> MAContainerMorph
no matter, this: ProductFamily new asMagritteMorph morph asSpecAdapter should produce the right result (no image opened now, so it can be slightly different) :)
Cheers, Sergi
2014-03-31 22:48 GMT+01:00 Esteban Lorenzano <estebanlm@gmail.com>:
On 31 Mar 2014, at 18:40, Sergi Reyner <sergi.reyner@gmail.com> wrote:
2014-03-31 22:36 GMT+01:00 Benjamin <benjamin.vanryseghem.pharo@gmail.com> :
On 31 Mar 2014, at 23:34, Sergi Reyner <sergi.reyner@gmail.com> wrote:
Yes, MNU MAContainerMorph>>asSpecAdapter
#asSpecAdapter is implemented on Morph oO
But MAContainerMorph does not inherit from Morph :)
Object -> Model -> MADescriptionModel -> MAContainerMorph
no matter, this:
ProductFamily new asMagritteMorph morph asSpecAdapter
should produce the right result (no image opened now, so it can be slightly different) :)
Indeed it does. It looks slightly ugly though: defaultSpec <spec: #default> ^ SpecLayout composed newColumn: [ :column | column add: #familyList; add: #familyEditor ]; yourself initializeWidgets familyList := self newList. familyEditor := ProductFamily new asMagritteMorph morph asSpecAdapter. produces the attached result. Can it be easily fixed?
Are you on Windows? Because I experienced some strange (though similar) issues on Windows (gods know why :S) Ben On 31 Mar 2014, at 23:59, Sergi Reyner <sergi.reyner@gmail.com> wrote:
2014-03-31 22:48 GMT+01:00 Esteban Lorenzano <estebanlm@gmail.com>:
On 31 Mar 2014, at 18:40, Sergi Reyner <sergi.reyner@gmail.com> wrote:
2014-03-31 22:36 GMT+01:00 Benjamin <benjamin.vanryseghem.pharo@gmail.com>: On 31 Mar 2014, at 23:34, Sergi Reyner <sergi.reyner@gmail.com> wrote:
Yes, MNU MAContainerMorph>>asSpecAdapter
#asSpecAdapter is implemented on Morph oO
But MAContainerMorph does not inherit from Morph :)
Object -> Model -> MADescriptionModel -> MAContainerMorph
no matter, this:
ProductFamily new asMagritteMorph morph asSpecAdapter
should produce the right result (no image opened now, so it can be slightly different) :)
Indeed it does. It looks slightly ugly though:
defaultSpec <spec: #default> ^ SpecLayout composed newColumn: [ :column | column add: #familyList; add: #familyEditor ]; yourself
initializeWidgets familyList := self newList. familyEditor := ProductFamily new asMagritteMorph morph asSpecAdapter.
produces the attached result.
Can it be easily fixed?
<PharoScreenshot.png>
Sergi Reyner wrote
But MAContainerMorph does not inherit from Morph :)
Yes, I always thought that was a mistake because it is confusing, and leads to wrong expectations like in this case. I meant to rename all like MAMorphicContainer, but haven't gotten around to it ----- Cheers, Sean -- View this message in context: http://forum.world.st/Spec-and-forms-tp4751908p4752011.html Sent from the Pharo Smalltalk Developers mailing list archive at Nabble.com.
participants (5)
-
Benjamin -
Esteban Lorenzano -
Norbert Hartl -
Sean P. DeNigris -
Sergi Reyner