[REBOL] how to display multi-line text
From: pat665:ifrance at: 30-Dec-2001 10:22
Hi all rebol-lister
Happy New Year to all, and a new FAQ.
Patrick at Euro - 2
How to display multi-line text?
Short answer:
Using as-is and a negative height such as 400x-1
Problem illustration:
=====================
rebol []
;-------------------------------
; This program shows a one line text.
; The multi-line text to display
;-------------------------------
myCode: {view center-face layout [
banner "Test"
button "OK"
]
}
win: layout/size
[
style code text black silver bold
code 360x100 myCode
] 400x200
view center-face win
Problem resolution:
===================
win: layout/size
[
style code text black silver bold as-is
code 360x-1 myCode
] 400x200
Two things are needed : (1) the use of as-is in the style, (2) a pair with a
negative height.
Note : this answer comes from Carl Sassenrath's easyvid.r.