[squeak-dev] Re: Pragmas (Re: The Inbox: Morphic-phite.429.mcz)

Hannes Hirzel hannes.hirzel at gmail.com
Mon Apr 26 23:24:24 UTC 2010

On 4/26/10, Bert Freudenberg <bert at freudenbergs.de> wrote:
> On 27.04.2010, at 00:47, Hannes Hirzel wrote:
>> And: to me the code for the menu definitions looks ugly. A kind of
>> assembler like, lisp-s expression thing with a lot of implied
>> assumptions.
> You mean this?
> MenuEntrySpec newFrom: (Dictionary newFromPairs: #(
> 		contents 'Well... hello?'
> 		help 'Displays the Hello World'
> 		location ('Help')
> 		target MenuMorph selector inform: arguments ('Hello World!')
> 		position first))

Actually I would not call this s-expression. It is regular Smalltalk
code because it uses keyword messages.

> Yes, looks a lot like s-expressions. No, I don't like it either. Glad we
> agree on that. But weren't you arguing *for* this? I'm getting confused.
> Balázs proposed this:

> <createDockingBarMenuWithPriority: 50>
> <fillDockingBarMenu: #extras priority: 20>
> - Bert -

Basically I need to get used to the idea that we do menus in an
orthogonal plane.

Are other programming languages doing this for menus as well? Java
which I have been using in the last years surely not.

However as a whole - not too bad. I'm fine if you go ahead and commit
the pragma based solution to the trunk.


More information about the Squeak-dev mailing list