Layout/Pane
[1/3] from: ammonjohnson:yaho:o at: 5-Nov-2001 20:03
Hi,
If you have noticed that when you use the layout function on a block of VID data, it
returns a face inside of a face in order to work with Origins, 7 offsets. This is not
always desirable. Sometimes I want just the contents not the contents wrapped in a face.
The problem with 'wraping' it is that if you want to use the face in multiple places
at the same time, REBOL throws a fit. The cure is simple, but it requires the use of
an extra variable. I propose that REBOL add a /Pane refinement to the Layout function.
This refinement would return the contents of the pane that layout would create. See
below
;this is the current method of doing it.
a: layout [b: box 220x220 c:box 220x220 d: box 220x220] ;the main layout
e: layout [text "Testing"] ; the face to put in the main layout.
b/pane: c/pane: d/pane: make c/pane []
; the new way!
a: layout [
style testing box 220x220 with [
pane: make layout/pane [text "Testing"
]
testing
testing
testing
]
Any thoughts?
Enjoy!!
Ammon
[2/3] from: allenk::powerup::com::au at: 6-Nov-2001 21:59
Will this help?
a: get in layout [b: box 220x220 c:box 220x220 d: box 220x220] 'pane
Cheers,
Allen K
[3/3] from: ammonjohnson:yaho:o at: 6-Nov-2001 15:21
Beautiful! I like it!
Thanks!!
Ammon