Lively - Squeak for Javascript?

Dan Ingalls gave a really interesting presentation about his work on Lively. You can see the video here.
I have been following Lively for a while - as a side point, running it in Safari makes a heck of a difference to performance (not sure whether that also applies to Safari on a PC). You definitely don't want to judge the product based on Firefox.

Anyway, what really struck me about the video was the way Dan could execute javascript in the environment. Anyone who as played with Squeak will be immediately struck by the similarities. In fact, when you dig down into the code, the whole object model looks amazingly similar. I am going to have to find the time to play with this!


Getting a handle on objects from the Flaps

one of the things I really like about the Squeak environment is the flaps. Being able to pull tools straight into your project really fits the environment I want to create. However, I couldn't work out how to get programmatic control of the objects. Thanks to the Squeak beginners list, I now know the answer.

There are three ways to solve the problem:
1. Halo the object and choose inspect. You can then send messages to the object via the bottom pane of the inspector window. That's good, but it wasn't quite what I wanted because it didn't let me use the workspace to build up some code (although I could have done the coding in the inspector window, that wasn't really how I wanted to work)

2. Assign self to a global variable. This occurred to me as I was doing something else. The basic problem was how to get a reference to the object into the workspace I was using. The object must exist in the current project, but I didn't know where to start looking for it. So, if I did something like this Temp1 := self. in the inspector, then the object had just been assigned to a global and I should be able to reference it from anywhere - works nicely. However, I then started worrying about my Smalltalk dictionary getting filled up with rubbish. I am a minimalist at heart, and don't like 'stuff'. After some digging around I found that remove: object won't work in a dictionary, but removeKey: #symbol does. So that's useful to know too.

3. Finally, the way suggested in the list was to turn on the feature in the workspace (click on the menu item in the window bar) which supports "textual reference to dropped morph" or something like that - don't have the image in front of me. This means that when you drop the morph on the workspace, the morph's 'name' e.g. textbox3012 is written into the workspace. This reference can then be used as the object handle. This is a great solution except for the fact that if the morph name has a space in it, then the reference won't work. I must find out a bit more about this at some time.


E Toys - pointless distraction or pure genius

The problem with Squeak is that it looks like a rather poorly designed system for kids. This impression is reinforced by the E-Toys system which - on the face of it - looks like a very simple colouring book.

However, as I begin to understand the system a bit more it is gradually dawning on me that E-Toys is actually a very interesting prototyping/programming tool.

Have a look at this while I go and do some experiments ;-)

Which version of Smalltalk?

I started playing with Smalltalk years ago, and although I was always intrigued by the system, I never seemed to have the time to really get to grips with it.

I realised that a big part of the problem was that I hadn't found a good guide book to help me along the way. Well, the Squeak by Example book is excellent, and that means that Squeak is now my version of choice. However, I don't plan to stop there. I am gradually switching over to using Macs as there is a wonderful language called Fscript which is basically Smalltalk for OSX. So, once I have got a better understanding of Squeak, I plan to jump into Fscript.

Getting started - Squeak by Example

Hello and welcome to my new blog. I am planning to use this space as a way of capturing my thoughts and experiences as I attempt to learning Smalltalk.

If you would like to follow along with me, I strongly suggest you download a copy of Squeak by Example, as that is the main text I am using. You can get a copy of the book here