smalltalk

Do you use articles in your variable names?

Edit: There appears to be at least two valid reasons why Smalltalkers do this (readability during message chaining and scoping issues) but perhaps the question can remain open longer to address general usage. Original: For reasons I've long forgotten, I never use articles in my variable names. For instance: aPerson, theCar, anObject...

Why does Squeak use Colors to identify Mouse Buttons?

This is really annoying when you try to follow the documentation Squeak by Example. Instead of calling the mouse buttons left, right, and middle, like in any other documentation, they give them colors. It's even suggested to label the mouse to help you learning. It's 2009 and there are 3 dominant systems left: Windows, MacOS X, Linux ...

Current Smalltalk development activity

I'm now a couple of months into my Smalltalk learning voyage. I was aware, from the beginning that Smalltalk has several "dialects" (perhaps "dialect" isn't the best word) but by this I mean VisualWorks, Squeak and Dolphin to mention just three. So far I have limited my foray to Visualworks and Squeak. But I've now discovered that Sq...

Inter-Image communication in Smalltalk. Possible?

I have a graph-traversal problem that is beautifully and elegantly modeled in smalltalk, but it's too big (in terms of computation and storage) for one smalltalk image instance. So, I want to partition the problem across multiple instances. My question is, is there any good way to send messages between smalltalk instances. Kind of like...

What is the best way to schedule a task in gemstone?

My website runs on gemstone. To provide users with statistical data I need to run periodical tasks. How is this achieved best in gesmtone? From within gemstone or from the operating system? And would be topaz the right way to go? ...

What's the difference between a Continuation (as in Smalltalk) and an interrupt (as in an Assembler)?

I'm struggling to understand the concept of Continuations (as used in Seaside with Smalltalk). A snippet from Wikipedia says: "... refer to first-class continuations, which are constructs that give a programming language the ability to save the execution state at any point and return to that point at a later point in the program..."...

What file type starts with BOSS 7?

I am looking at some files generated in the early 90s. One of them seems to hold references to data packed in some binary format in a number of large files. The first six bytes of the file are 0x42 0x4f 0x53 0x53 0x20 0x37 which spells BOSS 7. My searches of various sources of file type information, including /usr/share/file/magic hav...

Performance overhead of perform: in Smalltalk (specifically Squeak)

How much slower can I reasonably expect perform: to be than a literal message send, on average? Should I avoid sending perform: in a loop, similar to the admonishment given to Perl/Python programmers to avoid calling eval("...") (Compiler evaluate: in Smalltalk) in a loop? I'm concerned mainly with Squeak, but interested in other Smallt...

When to use Seaside components, and when to use simple render objects?

I have been developing a web application in Seaside+Squeak recently, and have found it to be a wonderful experience. Seaside really is head and shoulders above every other framework out there, and I feel as though I am working at a higher level of abstraction (above the HTTP request/response cycle and HTML templating that other framework...

How does Smalltalk deal with monkeypatching ?

I'm a Ruby coder. For me, monkeypatching is to change, at runtime, classes or modules methods in an external project. What I'm interested in, is what mechanism you have in place that will protect you from some of the abuses of that nice feature. Follows, some scenarios that I have encountered, where monkeypatching has bitten me. While I...

How Compatible is GNU Smalltalk with Squeak

Hey all, I'm working on an app in squeak that requires no graphics at all, its all just data manipulation. The problem is that I work in a fairly conservative environment and I dont think I'll be able to sell a squeak app to my managers (I feel like the bright colors, round interface and general "what-the-heck-is-that" feel of squeak wi...

new line in squeak

i want to do something like this: Transcript show: '\n'. how? ...

How do I change a method's name dynamically in squeak?

I have a class and I want to change the name of a specific method in run time. I guess there's a method in the 'Behavior' class that does it. But I just can't find it. any help? [in squeak] ...

Message forwarding in Smalltalk

So I'm writing an application where one object has a bunch of delegate objects that it forwards messages to. The idea is that I can say someObject sendMessage:aMessage and aMessage will be sent to all of someObject's delegates (for any value of aMessage). The only way I've been able to do this is something like: sendMessage:aMessage ...

In Squeak, how to wrap every method send?

I created a class, and in that class I have a method 'sendMessage: to: withArgs:' which recieves an object, a message and an array of arguments. The method is used to send messages to object and perform some algorithm. To use this method I have to create an instance x of the class I created and do something like x sendMessage: '+' to:...

How to create a global variable in Squeak?

I don't mean a class variable. I want a variable that can be used everywhere. Where should I define it? [in squeak] ...

Proper OO modelling of correspondences

Something keeps showing up in my programming, and it is that two things are the same from some viewpoint, but different from another. Like, imagine you build a graph of rail stations, connected by trains, then the classes Vertex and RailStation are sometimes the same, other times not. So, imagine I have a graph that very much represent...

Installing Magma and LPF in Pharo

I've been trying to install Magma in Pharo, but have had absolutely no luck. This is the stuff I've tried so far: Installing with Monticello from squeaksource.com/MagmaTester -- Syntax error in MaObjectSerializer >> setUpClassDefinitionProcessing. Installing from Universe -- the image hangs, apparently getting stuck in an infinite redi...

Squeak System Browser Questions

I am using (a school modified version of) the "Squeak By Example" (SBE) image for a OOP/OOD class. However, my System Browser is missing a few features that appear in SBE. I assume there are some configuration options that can get them back for me, but I can't find them yet. My questions are: 1) How do I get the buttons back? In the bo...

Why does the Squeak interface look and act so antiquated?

Don't get me wrong - I love Smalltalk, but... To me, the Squeak interface is one of the biggest turnoffs. I love Smalltalk - not the user interface. One only has to contrast modern interfaces like GNOME, MacOS X, and Windows Vista with their combination of ease of use and visually pleasing eye-candy with Squeak's flat 2-D cartoony 16-...