Sure, I'm not yet sold on what I did. I feel like there's something I'm missing but don't know yet what it is.
Could you compare this what we did with description builders in QCMagritte?
QCObject>>magritteDescription
|basicDescription builders|
basicDescription := self basicMagritteDescription.
builders := self magritteDescriptionBuilders.
builders ifNotNil: [^builders buildFrom: basicDescription target:
self].
^basicDescription
QCContainerComponent>>magritteDescription
^magritteDescription ifNil: [
| model builder |
builder := description descriptionBuilder.
builder ifNil: [ ^description].
model := self model.
magritteDescription := builder buildFrom: description target:
model model: self model model.
self setMemento: (model mementoClass model: model description:
magritteDescription).
magritteDescription ]
Stephan
On 26/03/15 14:25, Sean P. DeNigris wrote:_______________________________________________
> Should or could the MADescriptionMorph hierarchy use/inherit-fro MAVisitor?
>
> "Magritte Meta-Described Web Application Development" says "Custom
> Rendering... Sometimes other layouts are more convenient, for example the
> widgets should be laid out from left to right with the labels on top...
> Magritte allows one to define one’s own builder by subclassing a Visitor and
> overriding some of the methods used to place the user interface elements".
>
> With the current implementation, it seems one would have to hack the
> MADescriptionMorph classes themselves for that kind of change, but if a
> visitor was used, they could just supply a custom visitor class, no?
>
>
>
> -----
> Cheers,
> Sean
> --
> View this message in context: http://forum.world.st/Visitors-Underused-tp4815294.html
> Sent from the Magritte, Pier and Related Tools mailing list archive at Nabble.com.
>
> _______________________________________________
> Magritte, Pier and Related Tools ...
> https://www.iam.unibe.ch/mailman/listinfo/smallwiki
Magritte, Pier and Related Tools ...
https://www.iam.unibe.ch/mailman/listinfo/smallwiki
If you reply to this email, your message will be added to the discussion below:http://forum.world.st/Visitors-Underused-tp4815294p4815727.html