Frank Shearar uploaded a new version of Tools to project The Trunk:
http://source.squeak.org/trunk/Tools-fbs.410.mcz
==================== Summary ====================
Name: Tools-fbs.410
Author: fbs
Time: 2 June 2012, 8:51:27.787 pm
UUID: 9a35a890-56aa-4f90-9c6f-ff07f70f2919
Ancestors: Tools-cmm.409
Just a spelling correction: acceptDroppedMorphss -> acceptDroppedMorphs.
=============== Diff against Tools-cmm.409 ===============
Item was changed:
StringHolder subclass: #Workspace
instanceVariableNames: 'bindings acceptDroppedMorphs acceptAction mustDeclareVariables shouldStyle'
classVariableNames: 'LookupPools ShouldStyle'
poolDictionaries: ''
category: 'Tools-Base'!
+ !Workspace commentStamp: 'fbs 6/2/2012 20:46' prior: 0!
- !Workspace commentStamp: 'ls 10/14/2003 12:13' prior: 0!
A Workspace is a text area plus a lot of support for executable code. It is a great place to execute top-level commands to compute something useful, and it is a great place to develop bits of a program before those bits get put into class methods.
To open a new workspace, execute:
Workspace open
A workspace can have its own variables, called "workspace variables", to hold intermediate results. For example, if you type into a workspace "x := 5" and do-it, then later you could type in "y := x * 2" and y would become 10.
+ Additionally, in Morphic, a workspace can gain access to morphs that are on the screen. If acceptDroppedMorphs is turned on, then whenever a morph is dropped on the workspace, a variable will be created which references that morph. This functionality is toggled with the window-wide menu of a workspace.
- Additionally, in Morphic, a workspace can gain access to morphs that are on the screen. If acceptDroppedMorphss is turned on, then whenever a morph is dropped on the workspace, a variable will be created which references that morph. This functionality is toggled with the window-wide menu of a workspace.
The instance variables of this class are:
bindings - holds the workspace variables for this workspace
+ acceptDroppedMorphs - whether dropped morphs should create new variables!
- acceptDroppedMorphss - whether dropped morphs should create new variables!
I mused with a colleague about how I'd like to see "lexically scoped
monkey patching", and he pointed me to some guys that want to add that
to Ruby (http://timelessrepo.com/refinements-in-ruby). Note the
inspiration for their work: ClassBoxes!
(http://scg.unibe.ch/research/classboxes)
I remember reading the paper years ago, and started working through it
again now. Something that's not clear to me is this: does ClassBoxes
require VM-side changes? (Because it changes the method lookup, after
all, searching packages for methods before working up the inheritance
tree.) If so, how invasive are they? If not, do we have a ball-park
estimate of how much work it would be to update ClassBoxes to a more
recent Squeak/Pharo?
I'm more than happy to do the dogwork. I'd just like to know whether
I'm signing up for months of work or not.
Thanks!
frank