newbie needs help

Rob Whitfield rob at customfun.com
Fri May 17 15:07:13 UTC 2002


First, a sincere thanks for you advice Göran!!!

I am developing a solution that needs to run on NT, Mac OS 9, Mac OS X and 
a few flavors of Unix.  This is what attracted me to squeak - there is 
really no cross-platform that has squeak's advantages.  Java has too much 
baggage.  Cross platform GUI tools like XVT require a lot more bookkeeping 
since the app has to be built in the native environments.

I have a few specific questions.

1) How did you remove the flaps and windows so that your app could come up 
without all the other squeak stuff?  You mentioned that this could be done 
programmatically as well.  Is this documented somewhere?

2) Does the swiki server support multi-part form data so that files can be 
uploaded?

3) Does swiki support some notion of session variables so that multiple 
sessions can be kept track of?

At 09:19 AM 5/17/2002 +0100, you wrote:
>Rob Whitfield <rob at customfun.com> wrote:
> > I'd like to use squeak to serve as a platform independent means to collect
> > user input and drive a series of command line utilities.  I've downloaded
>
>Sounds fine.
>
> > squeak and worked through a number of tutorials.  Squeak is 
> cool!  However,
> > at this point I have no idea how I'd create a squeak program to open a
> > file, read some data, display the data, allow the user to enter some
> > additional data, start a separate executable, etc.
> > Can anyone point me to documentation that would be of use in creating a
> > standalone squeak application that does the things mentioned above?  Is
>
>Well, my advice is that first you read a beginners book on Smalltalk
>with Squeak running on the side of course to try stuff. There are also
>quite a lot of tutorials etc for Squeak (check the Squeak swiki).
>
>Then, when you have learned the basics of the language you should start
>learning how to find your way in the image. The image is like a big
>Library and if you don't know how all the books are categorized etc in a
>Library you won't find your answers!
>
>Some things off the top of my head:
>
>1. Method finder.
>2. Alt-m, Alt-n, Alt-b, Alt-q, Alt-p, Alt-d, Alt-i, Alt-I (these are the
>most important I think) and friends.
>3. "find class..."
>4. Reading class comments (press the '?' in the system browser) - those
>that are there! :-)
>5. Use Hierarchy browsers
>6. Good to repeat: Use Alt-n (senders of). If you have found a method in
>a class that seems interesting this will bring up other methods using it
>so that you can "learn by example".
>
>Note: "Alt" for Win32 - on Linux it seems to be in a flux and on Mac I
>think it's called "Command".
>
> > there a good book that I should buy?  Also, when I start squeak it 
> comes up
>
>There are a few Squeak books - especially two by Mark Guzdial. Those
>books are "compilations" of chapters written by a number of people and
>some chapters are for newbies, especially in the first white book. So
>unless someone else here knows a better book that might be a good
>starting point.
>
> > with its own environment containing elements of the development
> > environment.  How do I start squeak in a way that would run my program so
> > that my users don't need to know anything about squeak?
>
>Well, what platform are you on? We just deployed an application on Linux
>and Win32 and we do it in two steps:
>
>1. Do a few manual things like removing all windows, destroying global
>flaps, check Preferences etc. (that can off course also be done
>programmatically).
>
>2. Run a class method in the development image that:
>         -cleans up a few things of our own (checks that there are no stray
>instances/Processes of ours around etc)
>         -strips the image from stuff our app doesn't need. (based on 
> stripping
>code available on the Squeak swiki)
>         -saves this new image on another name
>
>This gives us an image that doesn't need the sources or the changes file
>and is about 6Mb with Morphic still in - it only needs a VM to run. Note
>that we do NOT prepare the image in any way to "autostart" stuff when
>coming up - like a first window on the application. You can do that of
>course in a number of ways, but we instead opted to use the facility of
>the VM to pass a little script-file as first input:
>
>On Win32 we have a .bat file called "proxy.bat" (the name of the
>application is 'Proxy') with one line in it:
>
>..\Squeak.exe squeak.image proxy.st
>
>This starts the image and the script proxy.st will be evaluated
>immediately.
>The script "proxy.st" is also just a oneliner that looks like:
>
>VHProxy startProxy
>
>....and that is the class method that starts the application. One of the
>advantages of putting "startup" code in a script file like this is that
>we can have multiple files for different apps all using the same image.
>;-)
>
>regards, Göran




More information about the Squeak-dev mailing list