About the Book
This book is intended to help you learn how to use Smalltalk-80. Like most practical programming books, you will only get the maximum benefit from reading if you carry out the exercises. Also, reading this book sequentially from cover to cover is not recommended. It is divided into two main parts: Part I, on the language itself, and Part II, on the programming environment. The part on the language comes first because, in a theoretical sense, the language is conceptually prior to its programming environment. However, Smalltalk-80 is tied inextricably to its own distinctive environment, so it will probably not be possible for you to tackle the exercises in Part I without first reading relevant passages in Part II. This is intentional, and you will find "forward references" to such sections at various points throughout Part I. The structure of the book reflects the commitment to "learning by doing" as the best way to acquire a new programming language. Most chapters have a descriptive component, plus a set of exercises.
The description is there to introduce you to the concepts you will be using in the exercises; read this first part before tackling the exercises, but be prepared to refer back to the descriptions when needed. The descriptive material is designed not only as an introduction, but also as a beginner's reference guide. Indeed, we hope that even experienced Smalltalk users will find basic information easier to locate in this book than in some more detailed reference works on Smalltalk. This book covers Smalltalk-80, versions 2.1 to 2.5. We have also tested the exercises in Chapters 2, 3 and 4 with Apple Smalltalk v. 0.4. The exercises in Chapter 2 should work with Smalltalk/V Mac version 1.0.
Table of Contents:
Part 1 The language - introduction - what is Smalltalk?, current versions of Smalltalk, object-oriented concepts in Smalltalk; messages and methods - message syntax, variable names, literals, assignment, pseudo-variables, control structures, blocks, kinds of variables, exercises, exercises solutions; basic classes - the class hierarchy, number, boolean, the collection classes, streams, graphics primitives, forms, interaction classes, exploring the basic classes; building a model - the library management system - designing in an object-oriented manner, functional requirements, the conceptual model, specification by specialization, exercises - implementing the LMS; interactive applications - model-view-controllers, pluggable views, designing the advanced LMS, exercises; some useful classes - the display hierarchy, more on MVC, some useful user interaction classes, the compiler and decompiler. Part 2 The interactive programming environment: the Smalltalk system - ideology, Smalltalk system structure, printing, more on filing in and filing out, version management, crash recovery, user defined primites; tools - interface fundamentals, menus, windows, workspaces, the system transcript, browsers, files, projects, raster editors, inspectors, debuggers. Appendices: quadeditor source listing; LMS listing; ALMS listing; simple MVC listing; actionmenu listing; object interfaces - class order; choosing a system.