squeak laptop for the rest of us

Lex Spoon lex at cc.gatech.edu
Sat Apr 16 19:05:50 UTC 2005


> What isn't a practical option is trying to fix Scamper. It is typical of
> a quick hack that got a job partly done and then simply stayed forever
> in the image. I know the value of code that actually works, but a better
> development style is to learn as much as you can from your first try and
> then to start over. This normally involves creating more infrastructure
> than you had in your first attempt. So you might build a decent layout
> framework to replace all the hacked placement code.

That is just a small part of Scamper, and indeed one that is likely to
be a part of any more complex layout engine.  Do you know anything about
Scamper before saying it is a "hack" that should be thrown out and
rewritten completely?

Do you think, for example, that the HTML tokenizer should be tossed?  
How about the parser?  The formatting code in class HtmlFormatter?  What
about Squeak's built in text-flowing code, which is what Scamper mainly
relies on for layout?  How about the model code for HTML forms?  Do
you think MIMEDocument should go, as well?  The URL hierarchy?

I agree that there is a lot to be done, and that new layout
infrastructure is well worth thinking about.  However,  that's all the
more reason to take advantage of the couple of man-months of coding that
is already in there.  If you want to quickly get to an open-source
Squeak-based web browser, then extending Scamper is a very good
approach.

In short, if you want results quickly, then it is best to leverage what is there.
I am happy to help anyone who wants to extend Scamper and is finding
it tough going.  I've long suggested that people start by pitching in on the
TableMorph effort that has already begun.  That alone will give us a
dramatic increase in the number of pages that are displayable in Squeak.
 Likewise, if TableMorph is already too difficult for people to make much
progress on, then we should certainly be afraid of trying to do anything
even more ambitious.


All this said, it might be a poor strategy to make a complete
web browser.  There's just too much to do, because we have reached a
state where "the web" is defined by what Mozilla does.  Instead, what
does make sense, and what the VW browser I have seen provides, is to
make a crutch that lets you barely manage to read a web page.  I suspect
Scamper could get there for most web sites quite quickly; TableMorph
alone should pick up many of them.  

Even given something as nice as the VW browser, though, you'd still
prefer to use Mozilla whenever you had the choice.  Mozilla will get it
right in practically all cases, and it tends to look a lot better.  
When I use BottomFeeder, a VW application, I always use its feature for
shelling out to Mozilla instead of using the built-in browser.  Happily,
Squeak can do exactly the same thing via the ExternalWebBrowsing package
on SqueakMap.

By the way, there have been efforts to implement an X server in Squeak,
and there have been efforts to hook up an existing X server to Squeak
via screen scraping.  If you are really into this sort of thing, you may
want to google around and try to get involved in existing efforts.


-Lex



More information about the Squeak-dev mailing list