On 09 May 2016, at 1:53 , Peter Uhn��k <i.uhnak@gmail.com> wrote:


(Which is a neat storage format for, say, a UIBuilder)

When you don't touch it, you don't care about it.
 
The focus seems to have changed over time to directly using what was initially the intermediate object model the builder generated when parsing the spec.

I guess because it's written by hand��� I mean the array looks like bad attempt at STON.

In any case, we can always introduce a proper DSL for layout later (or even better, have a UI builder!). Right now it's written with the spec layout.

Peter

Uhuh, in my mind, it seemed to get off to a kind of shaky start, and never improved.
Rather than take the opportunity to design a more generic object model for widgets with a clear strategy in mind for mapping to a literal syntax, it seemed to me to have started by copy-pasting the entire API used by Morphic widgets, adding Spec in front of some of the class names, and call it a day. 
Slap some {}'s around where appropriate, and you have a literal syntax!

The good news is, no-one in their right mind would willingly use the literal format as is, so changing it probably wouldn't cause too much of an uproar, 
the bad new is, all the hard work involved in creating a sensical format, still remains.

It's also rather hard to make a good object model that you then later graft a literal format on top of...
For instance, with the use of blocks for everything, and the weird mix of symbols and method calls:

row newColumn: [ :col | col add: #topToolbar height: self toolbarHeight ] 

I'd have no idea how to represent as a literal in an intuitive way.

Cheers,
Henry