[CS] TicTacToe
Ned Konz
ned at bike-nomad.com
Sun Apr 27 22:36:06 UTC 2003
On Sunday 27 April 2003 04:39 pm, Martin Drautzburg wrote:
> ingo at 2b1.de writes:
> You asked: How can I make it resizable?
Using the ProportionalLayout is probably the easiest way.
For instance, try this in a Workspace:
field _ RectangleMorph new extent: 300 at 300; openInWorld.
field layoutPolicy: ProportionalLayout new.
1 to: 3 do: [ :row |
1 to: 3 do: [ :col |
field addMorph: (RectangleMorph new color: Color red)
fullFrame: (LayoutFrame fractions: (((row - 1)/3.0 @ ((col -
1)/3.0)) extent: 0.333 at 0.333))
]
]
--
Ned Konz
http://bike-nomad.com
GPG key ID: BEEA7EFE
More information about the Squeak-dev
mailing list
|