This works for me

$text.locked = 1

its not in the online manual though....

thanks Schuliebug

anyone know how to center the text in the box?