Font size when text used into 'draw
[1/6] from: christophe:coussement:mil:be at: 7-Jan-2002 15:53
Hi Fellow REBOLians:
I didn't use draw dialect a lot until now, and I have this little problem:
how can I determine the size (and other properties) of the text font when
used into a 'draw block ?
None of those seems to work :
>> view layout [box effect [draw [pen red text "hello" 20x20 font [size:
50]]]]
>> view layout [box effect [draw [pen red font [size: 50] text "hello"
20x20]]]
Thanks for helping me, and Happy New Year to all ;-))
==christophe
[2/6] from: bzr:francenet at: 7-Jan-2002 20:57
Coussement Christophe wrote:
> how can I determine the size (and other properties) of the text font when
> used into a 'draw block ?
Hello,
I would use something like:
my-font: make face/font [
size: 50
]
view layout [box 300x100 effect [draw [pen red font my-font text "Hello"
20x20]]]
[3/6] from: arolls:idatam:au at: 8-Jan-2002 12:31
view layout [
box font-size 40 effect [
draw [pen red text "hello" 20x20]
]
]
Anton :)
[4/6] from: christophe:coussement:mil:be at: 8-Jan-2002 8:52
thanks Anton !
[5/6] from: greggirwin:mindspring at: 8-Jan-2002 11:48
hi Christophe,
The Easy-Draw example gives you a start on things. Here's a snippet:
do [
italic-font: make face/font [
size: 15
style: [italic bold]
name: font-serif
]
]
box 200x200 gold effect [
draw [
pen blue text 20x20 "Default Font"
font italic-font
pen black text 20x60 "Bold Times Italic Font"
]
]
--Gregg
[6/6] from: christophe:coussement:mil:be at: 9-Jan-2002 9:32
Thanks, I can use this !
==christophe