Recipe 7.11. Making Text Nonselectable


Problem

You want to prevent users from selecting text in a text field when viewing the movie.

Solution

Choose the text field on the stage, and toggle off the Selectable button in the Property inspector (so that it is not selected).

Discussion

By default, Flash text is selectable. Users can use their mouse to highlight and copy text in the movie. This is a feature you may want in many cases. But in other cases, it may not be what you want. For example, if you use text to label a button, you don't want the text to be selectable, because it will interfere with the button functionality. Also, by making text nonselectable, you can make sure that users cannot copy and paste itwhich may be something you want to ensure in some cases.

Making text selectable or not is a fairly quick process. You need only to choose the text field on the stage, and then make sure that the Selectable option is toggled to the off position in the Property inspector. The Selectable option is located to the immediate right of the Line type menu in the Property inspector.




Flash 8 Cookbook
Flash 8 Cookbook (Cookbooks (OReilly))
ISBN: 0596102402
EAN: 2147483647
Year: 2007
Pages: 336
Authors: Joey Lott

flylib.com © 2008-2017.
If you may any questions please contact us: flylib@qtcs.net