[Newbies] Keyboard input - programming course
sdw2 at shineonline.co.nz
Mon Jul 4 20:47:52 UTC 2011
>> - how would one display a text label and a text field and obtain input from the text field (am thinking of Morphic)
> name := UIManager default request: 'Enter your name'.
> Transcript show: name; cr.
Thank you - this is exactly what I was looking for - the simplest way of
> However, IMHO this is *not* the best way to introduce Squeak programming to beginners. It mimics procedural programming in a console.
I fully agree with you. The reason is that there are external criteria
which we have to meet. The criteria requires keyboard input, and
personally have only used Squeak for Seaside projects so didn't know how
to do this simple thing :-)
> Instead, just open a Workspace and begin evaluating expressions. There doesn't have to be a "program". In fact, there is no "main". Just send messages to objects.
> 3 + 4
> 1234 / 56
> 100 factorial
> 'foo bar' asUppercase
> Then, make a Morph and send it messages. Evaluate each line individually to see its effect.
> joe := Morph new.
> joe openInWorld.
> joe position: 100 at 100.
> joe color: Color red.
More information about the Beginners