=== Top of the Swiki === Attachments ===

Linked Squeak FAQ

This is an alternative representation of the Squeak FAQ. I created this page because I really like to use the Recent Changes and I got tired of scolling through the whole Squeak FAQ. (Of course, I have now doomed myself to maintaining this alternate fork, but if others find it useful, I won't have to.) This page is a sort of test against a self-contained FAQ, though you should be able to get a self-contained version by Displaying This Page And All Of Its References. ----
Where is InterpreterProxy
How do I change the font size
Q:
Jeffrey J. Hallman asked:
I started Squeak 2.2 on NT, and found the fonts too small to read comfortably. What should I do? (-- from the Squeak Mailing List, Nov 23, 1998)

A:
David Mitchell answered:
TextStyle changeDefaultFontSizeBy: 1.
See TextStyle class>>changeDefaultFontSizeBy:
"This sample method recreates the default textStyle, with font 1 being a size larger than the smallest. It then initializes most references in the system as well, although most windows will have to be closed and reopened to get the effect."


Note The technique discussed in this post applies to all
versions of Squeak on all platforms. Tested on Windows 95, Linux, and the Mac.


-cap 11/23/98



Q:
Question - How can I change default font in Squeak, for exmaple to
Comic font ?

A:
Answer(s):
Follow this link to: Changing fonts


How can I get a complete class-hierarchy list
Q:
Is there an easy way to generate an indented listing of the complete Squeak hierarchical class structure?

A:
Open up a "System Browser", select "Kernel-Objects", select class Object, pop up the class context menu and select "hierarchy". This will create exactly what you want. To get it out to a file, scroll to the end of the text, place mouse pointer after all the text and double-click. This selects all the hierarchy text, which you can then copy-and-paste to your favorite text editor.
If you want to do this in a more direct fashion, evaluate:
(FileStream newFileNamed: 'hierarchySqueak2.2.txt') nextPutAll: Object printHierarchy; close


What are Squeak's image size extremes
Q:
At the outset, the system creates quite an illusion of "power under the hood." Can you give me a handle on the limits of the implementation in terms of speed and memory? - A.G.

A:
Smallest version runs in under 1 megabyte (for PDAs). The standard version can go up to 511 megabytes now, and this will rise to 1.5 gigs (of memory!) as of version 2.3. Ted Kaehler


What aspects of Squeak are particularly fast or slow
Q:
What aspects are fast and slow? -A.G.

A:
You don't have to worry about this. It's fast enough. Message sends (calling a subroutine) are a lot cheaper than other languages.
N-squared loops are slow, just like other systems. Floating point is a little slow, but version 2.3 has improvements. There are array operations for floating point that go faster. 'Become' is slow (swapping the references to two objects), but you won't use this in normal code. Ted Kaehler


How stable is Squeak
Q:
How stable is it? It seems to me remarkably robust. -A.G.

A:
It is very stable. Ted Kaehler


Q:
I have gotten the browser to break a bit from time to time (occasional array bound errors that seem to clear up by redrilling through the paths). -A.G.

A:
Yes. After you add a class, you may want to choose "update" from the upper left hand pane menu of each Browser. We know it should update by itself, but have not gotten around to doing it. Redrilling is fine also. Ted Kaehler


How can I learn Morphic
Q:
Can you give me any leads for docs on Morphic or related technologies so I can learn the lay of the land? -A.G.

A:
See http://minnow.cc.gatech.edu/squeak.30 for a page on Morphic, including a tutorial. See http://minnow.cc.gatech.edu/SqueakDoc.11 See the "Play with me" windows in Squeak. Ted Kaehler


How fast is Squeak
Q:
Roughly speaking, how fast is Squeak?

A:
400 MHz Pentium:
550,000 message sends/sec
9,000,000 bytecodes/sec
[Ummm, sorta -- actually I'm seeing higher numbers with 2.3beta on Andreas' standard 2.3beta VM
(assuming you're using the normal #benchmark and #benchFib in Squeak) -- Dwight Hughes]


292 MHz G3:
700,000 message sends/sec
16,000,000 bytecodes/sec
John Maloney
275MHz StrongARM in Corel NetWinder

Tim Rowledge

How do you bootstrap a Squeak image
Q:
Stephen Pair asked:
How do you bootstrap a Squeak image? Meaning, if I don't have an image and only sources, is it possible to build a new image? Or, with an existing image, can I compile source files and create another brand new image? I want to play around a little bit with object header formats and such, but to do this, I'll need to build new images completely from the ground up. mailto:spair@acm.org

A:
i) You don't. Some bits is this Squeak are descended from Smalltalk-76. They have been loaded and saved in a 'core image' many times. It is, theoretically possible to start from nothing (since it has been done in the past, back before the earth cooled), but t'ain't easy.

ii) Use the SystemTracer. A SystemTracer reads every object in the system, and constructs a new '.image' file byte-by-byte. Transformations can be done along the way. TK estimates that the main line Squeak has been through the SystemTracer only 16 times since 1977.
Look at the code in the standard system for the basics, and consider looking at my ( Tim Rowledge) code for converting the compiled method format using the tracer. Go to http://sumeru.stanford.edu/tim/pooters/squeak.html to see more. Basically you can do just about anything using the tracer if you're careful, patient and precise.

iii) In general, the complete source code of a Smalltalk system is not a complete definition of the contents of the image (even for Squeak), though arguably it should be. There are usually a number of pools and dictionaries and such whose contents were defined interactively as needed back in the depths of time. However, these could be hunted down and proper initialization code written for them. Basking in the ignorance of never having actually bootstrapped an image, this is what I would do (I think :-b): first define a special compiler outside of the image you are creating (duh, since you don't have an image to begin with), then give the compiled code (and all related source and information) to a special image creator/interpreter to package everything up, do the initializations, and create all the oops and object structures and such - it would also need to link each CompiledMethod to the sources file and lots of other little details (as Tim said - t'ain't easy). Budd's "Little Smalltalk" has this capability I believe (for a greatly simplified implementation). All this assumes you have a VM that understands your image format and compiled code to run the image on when you get through - if not,.... The more I think about it the uglier it gets, but you get the idea. -- Dwight Hughes



What is the SystemMonitor
Q:
Dave Newman asked:
What is the SystemMonitor? I've been able to start it, but it does not appear to display any activity happening within Squeak. Is there more to using SystemMonitor than just sending it the #start or #startDefault messages?

Addendum: I was able to get some activity to display by doing the following in a worksheet.
SystemMonitor initialize.
SystemMonitor startMemory.

sending #startDefault still seems to produce a divide by zero error
that Squeak catches.
mailto:tinman@pobox.com

A:


What can Squeak do
Q:
As someone that has never used Squeak before and not knowing anything about its capiblities, what can I expect to be able to accomplish along the lines of graphics and sound abilties?

- phypor

A:


What can Squeak do for me
Q:
I ran across Squeak in an article in Wired magazine. I am a casual computer user, mostly using it for gaming, and I am just learning C++. What would downloading Squeak do for me? I just want to make the casual computer use that I have described into a more interesting experience.

- Smoove K, mailto: kaphilli@mccallie.org

A:


How do I change the Morphic world background
Q:
How can I give my Morphic world wallpaper (a background image)?

A:

img
img _ GIFReadWriter formFromFileNamed: 'image.gif'.
World color: (InfiniteForm with: img).
World fullRepaintNeeded.

How do I make Scamper work behind a firewall
Q:
How do I configure TCP-IP to start a Scamper (web-browser) from behind a Firewall?

A:
Do you have an HTTP proxy server available? If so, you can set it up like this:

HTTPSocket useProxyServerNamed: 'my.server.name.com' port: 8080


How can Squeak deal with text files on non-Unix machines
Q: How can Squeak deal with text files on non-Unix machines?

A: See CrLfFileStream. It lets you transparently
deal with text files on systems that don't use carriage returns
to denote line endings. In particular, Unix uses line feeds, and
DOS/Windows uses both a carriage return and a line feed.


Is there a searchable archive of the Squeak List
Q: If I can't find the answer to my Squeak question here, is there a way to see if the subject has already been discussed on the Squeak mailing list?

A: Yes. The Squeak mailing list archives can be searched at http://macos.tuwien.ac.at:9009/Server.home. For example, if you're looking for information on the Gtk widget toolkit related to Squeak, a search on "gtk" will bring up a few dozen relevant messages.

Also, a nice hierarchical (but not searchable) view of the Squeak mailing list archive is available at http://squeak.cs.uiuc.edu/mail/squeak/.