System Windows making me insane!
Bijan Parsia
bparsia at email.unc.edu
Wed Jan 17 02:57:16 UTC 2001
On Tue, 16 Jan 2001, Kevin Fisher wrote:
> I was just wondering if someone could throw me some sanity for a moment. :)
>
> I'm banging my head against SystemWindow right now...it never seems to do what
> I want it to do! Take this example...I've got a RectangleMorph of a given
> size. I want to wrap that in a SystemWindow. Simple, right? Well, it never
> works for me.
The problem is that 1) your window doens't have a model, thus it relies on
the default initialExtent (which is 570 at 350); this is true even if you
used the rectangle as the model since it doesn't have a specific, special
initialExtent, 2) #openInWorld uses the #initialExtent.
So the simple solution is to change the last line of your snippet to:
syswin openInWorldExtent: newExtent
This seemed to work for me in 2.8 (tiny window, white rect).
Cheers,
Bijan Parsia.
More information about the Squeak-dev
mailing list
|