[Vm-dev] How difficult to make a .NET VM?
andreas.raab at gmx.de
Thu Mar 27 02:56:33 UTC 2008
Sounds nasty. One thing to experiment with the -browserWindow: command
line argument. Originally, it was designed to "get Squeak into a
browser" but of course, as long as your .NET form has a HWND handle you
can get Squeak inside it by passing the handle along with
-browserWindow:. Other than that I have zero experience with what makes
.NET form a .NET form and how to get anything to behave properly inside it.
Aran Lunzer wrote:
> [Apologies if this has been addressed before or elsewhere; my Google
> attempts didn't turn up anything that seemed relevant.]
> Has anyone tried packaging the Squeak VM as a .NET class? (...if that's a
> sensible way to ask the question)
> For the past couple of years I've been using and hacking the Squeak/.NET
> bridge, created by John Pierce and Ben Schroeder, mainly so I can create
> and control IE-like Web browser views within the Squeak desktop (see, for
> While this has been successful to the degree needed to be a platform for
> HCI research, the setup is still - frankly - an untidy and fragile hack.
> The main challenge has been how to combine the .NET views with the Squeak
> desktop. Originally we made them children of the Squeak window, but this
> gave us a nasty, intermittent thread-based deadlock. We worked around
> this by keeping the .NET views independent but making them hover in front
> of the Squeak window in the Windows Z order; some tweaks to the handling
> of focus-change messages in the Squeak VM allow us to ensure - most of the
> time - that the combination shares the desktop nicely with other Windows
> However, as I say, it's pretty fragile. So we're wondering whether
> there's a clean way to make the .NET views be children of the Squeak
> window, only without running into the COM vs. .NET threading issue that
> hit us before. In particular, unless we can crack this issue it seems
> unlikely that we can get the Squeak+.NET combination to behave acceptably
> when embedded within a Web browser.
> I suspect that if we could package the Squeak desktop itself as a .NET
> Form we could then make the other views be proper children of that
> desktop, and the window management problems would all go away. I also
> imagine that we could then go the extra step of packaging this .NET-based
> VM as a browser plugin. If it all works, the result would be a pretty
> useful (though Windows-specific) Squeak+.NET environment.
> So: can anyone shed some light on how complex this is likely to be? Has
> anyone already tried it?
> ...or would we be better off just looking for another way to get Web pages
> rendered? A Squeak-native approach such as Scamper seems doomed to lag
> the state of the art by years; has anyone looked into packaging a library
> such as Gecko for use within Squeak?
> Thanks for any thoughts -
> Aran Lunzer
> Hokkaido University, Japan
More information about the Vm-dev