[Cuis] [4.1-1544] LayoutMorph example2 -- add #morphPosition: method as illustration
Juan Vuletich
juan at jvuletich.org
Sat Jan 5 20:35:39 CST 2013
Followed your suggestion. Find it in the latest updates.
Cheers,
Juan Vuletich
H. Hirzel wrote:
> Hello
>
> I suggest that as an example
>
> pane morphPosition: 50 at 30.
>
> is added to
> LayoutMorph example2
>
> and maybe other examples
>
> so that
>
> a) not all tests cover up each other in the upper right corner
> b) people do have an indication that the method
> #position: (of Squeak) has changed to
> #morphPosition:
>
> (less surprise and a few minutes of exploring saved which can be
> spent on other things :-).
>
>
> And the example exposes the same problem with layout and screen update
> as the others.
>
> Kind regards
>
> --Hannes
>
> CLASS
> LayoutMorph
>
> example2
> "
> self example2
> "
> | pane row |
> pane _ LayoutMorph newColumn separation: 5.
> pane morphPosition: 50 at 30. "<<<<<<<<<<< NEWLY ADDED"
>
> pane color: Color red.
> row _ LayoutMorph newRow separation: 5.
> row
> color: (Color h: 270 s: 0.2 v: 0.6);
> addMorph: (BorderedRectMorph new color: (Color h: 120 s: 0.6 v: 0.6))
> layoutSpec: (LayoutSpec fixedWidth: 20 proportionalHeight: 0.8
> minorDirectionPadding: #bottom);
> addMorph: (BorderedRectMorph new color: (Color h: 90 s: 0.6 v: 0.6))
> layoutSpec: (LayoutSpec proportionalWidth: 0.8 fixedHeight: 40
> minorDirectionPadding: #top);
> addMorph: (BorderedRectMorph new color: (Color h: 150 s: 0.6 v: 0.6))
> layoutSpec: (LayoutSpec fixedWidth: 30 proportionalHeight: 0.7
> minorDirectionPadding: #center).
> pane addMorph: row layoutSpec: (LayoutSpec proportionalHeight: 0.9).
> pane openInWorld
>
> _______________________________________________
> Cuis mailing list
> Cuis at jvuletich.org
> http://jvuletich.org/mailman/listinfo/cuis_jvuletich.org
>
>
>
More information about the Cuis
mailing list