tags:

views:

63

answers:

1

I want to center "Your Banner Text" but don't know how to calculate the text width

view layout [
    box white 728x90 effect [
        draw [ 
            text 100x20 "Your Banner Text"
        ]
    ]
]
+1  A: 

Here's a way of doing it by putting text straight into the box instead of using the DRAW dialect:

view layout [
    box white 728x90 font [align: 'center] "Your banner text"
]
Sunanda