On Sep 27, 2009, at 11:43 AM, nullPointer wrote: > > > > Stéphane Ducasse-2 wrote: >> >> In VisualWorks you use the builder and it generates a class for you >> a bit in the same way then you code the missing code. >> >> You said: >> >>> Of course, but I don´t know do it of another way. Literal array is >>> very >>> complicated for me. >>> Xml serialization and Moose serialization don´t be possible. The >>> code >>> generated is HUGE >> >> and in VW all the interface is generated using the UIBuilder. >> so I'm wondering why this is working
I mean not working for you. >> > > I´m not sure of understand good that... > The only class than works in UIBuilder for create the UI > (#specMorph) is > CLViewDesigner class. > That class create the #specMorph and #specEvents methods, in a > child of > CLView class. All examples in CLFramework be CLView kinds. In the > #specEvents is returned a Dictionary where exists a relation between > morph, > type of event and handler of that event. All that is more more > readable than > VW mechanism, where not is easy understand it. > > > > Stéphane Ducasse-2 wrote: >> >> I do not know exactly the VW framework details but we can cerytainly >> interpret the following literal array. >> >> [.....] >> > > I understand is possible create a interpreter for that code, with > #perform: > message. But the difficult seems GeneratE that code, not reader. Ah You walk throw your structure and the visitor generate the associate information. May be you can tag the method to indicate if they should be saved. > > Not is equal a result like that...? > > |CanvasMorph btnAction1 ...... | > > "CanvasMorph" > CanvasMorph := Morph new. > CanvasMorph color: Color red; > borderWidth: 5; > etc.... > > "btnAction1" > btnAction1 := CLButton new. > btnAction1 text: 'Accept'; > position: 1...@10; > roundedCorners: true. > > [...............] > > CanvasMorph addAllMorphs: #( btnAction1 btnAction2 [etc....] ) I do not know. Because with the literal array approach we can interpret it after the way we want. > Is a dummy example, but the result code is more cleaned, and readable. > And seems equal of hard.Another environments ( equal or much more > competents > than VW ) using that mechanism. No this is not equivalent because with an array you could build a renderer for another toolkit, web, .... > My knowledge of Smalltalk and programming in general is very limited > and > poor. I want listen another ways of do.I want learn. But i have > understand > it before :D Cool _______________________________________________ Pharo-project mailing list [email protected] http://lists.gforge.inria.fr/cgi-bin/mailman/listinfo/pharo-project
