Rootless Squeak on OS X?

Aaron Reichow revaaron at bitquabit.com
Fri Feb 23 06:35:57 UTC 2007


John and the list-

I'm wondering if we can get a rootless Squeak VM for Mac OS X  
created.  I'm of the mind we could do it quite quickly and relatively  
easily.

For a photo of what this looks like on Windows, see:
http://www.d.umn.edu/~areichow/squeak/rootless/rootless-squeak.gif

I was digging through some old Squeak files, and I happened upon a  
little gem that I've not seen many people use, which is a shame.   
That little gem of a goodie is Win32 Rootless! Basically, it sets the  
background color of Squeak to something with full transparency and  
then goes full-screen.  It gives the working illusion that all your  
Squeak windows and naked morphs are just floating there, not encased  
in an inner world.  It isn't perfect, and it is far from the power  
you'd get with real OS windows or that project ... But, it still is  
awesome and with a small bit of code does a lot of good toward  
bringing Squeak more into the fold of the host OS environment, but  
without having to make the sacrifices of other more OS-specific  
Smalltalks (e.g. Smalltalk MT).

Like I said, it's basically making Squeak full screen and makings  
Squeak's background transparent and having the OS realize that.   
Which means all Squeak windows are on one layer, just like if you had  
a maximized Squeak window, in relation to other OS windows. You can't  
have a Squeak workspace and class browser with a Firefox window  
sandwiched between, or see various Squeak windows from the Windows  
taskbar That said, it really doesn't make a difference. The biggest  
thing I used rootless Squeak for was for widgets, just like with OS  
X's Dashboard.  I generally did my main development in a regular  
image for various reasons, but I always had Squeak running with a few  
widgets of my own devising- a clock/weather thing, a program  
launcher, a menu of scripts I ran a lot, some things like that.  As a  
Squeaker, I was able to implement this in Squeak 10x quicker than I  
could've writing HTML/JavaScript/CSS to create an OS X or Yahoo! widget.

There has to be a way to do this on OS X!  I'm hoping that John or  
someone else on the list might be willing to tackle it or be willing  
to tell me where to look myself.  I'm quite handy with anything in  
Smalltalk, but when it comes to the workings of the VM or FFI calls  
into C I'm lost.

It seems that this should be pretty easy to implement, if only  
because a) Mac OS X can do transparency too and b) the Windows  
version manages to be implemented in a measly ~5 pages of code,  
looking at the fileout.  When you actually file it in, it's a tiny  
bit of code, relatively.  It uses FFI to work its magic and doesn't  
require a plugin.  As you see if you download the zip below, it was  
created for Squeak 3.0, however I've used it on newer Squeaks (at  
least up to 3.6, possibly 3.7 IIRC) with no problems or patches.

For anyone interested in trying it, get it here:
http://www.d.umn.edu/~areichow/squeak/Win32-Rootless.zip

It only works with Windows 2000 and up, though I've never tried it on  
Vista. Anything older than Win2k doesn't support alpha channels. You  
just need to load in those two file-ins, and there is a class comment  
telling you what to evaluate.  I used it on Windows XP quite a bit  
and never noticed any flakiness as a result.

Regards,
Aaron



More information about the Squeak-dev mailing list