If you are upgrading from stooop 2.x to 3.x (namespace version), there
is not much complication: it may just be a little fastidious. I am
sorry but there was no other way to make stooop compatible with the
new tcl 8.0 namespace facility, and I made as little conceptual
changes as possible.

Furthermore, there is a lot to gain from the namespace version: object
member data is no longer at the global level. Consequently, you can
use variable names that are identical to class names (widget for
example). You no longer have to make a global declaration whe you want
to access other classes data (use the otherClass::(...) syntax).
Invoking member procedures within the same class procedures does not
require a fully qualified name. For example:

class a {
    proc p {x} {}
    proc q {} {
        a::p 0 ;# fully qualified name
        p 0    ;# is no longer required
    }
}


Enough talk, here is the easiest way to upgrade:

--- from the 2.x version: --------------------------------------------
proc shape::shape {this x y} {
    set shape($this,x) $x
    set shape($this,y) $shape($this,x)
}
...
--- to the 3.x version (look carefully :): ---------------------------
class shape {}
proc shape::shape {this x y} {
    set shape::($this,x) $x
    set shape::($this,y) $shape::($this,x)
}
...
----------------------------------------------------------------------

and that's it!


--- if you want to get fancy: ----------------------------------------
class shape {
    proc shape {this x y} {
        set shape::($this,x) $x
        set shape($this,y) $shape($this,x)
    }
    ...
--- or even fancier: -------------------------------------------------
class shape {
    proc shape {this x y} {
        set ($this,x) $x
        set ($this,y) $($this,x) ;# with patched tcl
    }
    ...
----------------------------------------------------------------------

Please note that a patch (included in this distribution) is needed for
the second constructor line to work. The patch may be included in the
8.1 release (I have written to the people at Sun about this).


Access to other classes members (not base classes) no longer requires
a global declaration (it is actually mandatory to remove it). Example:

--- from the 2.x version: --------------------------------------------
proc shape::shape {this x y} {
    global gizmo
    set shape($this,x) $x
    set shape($this,y) $gizmo(yStart)
}
...
--- to the 3.x version (look carefully :): ---------------------------
class shape {}
proc shape::shape {this x y} {
    set shape::($this,x) $x
    set shape::($this,y) $gizmo::(yStart)
}
...
----------------------------------------------------------------------


That's it, boys and girls. Live long and prosper.
