building flash templates

Adding Text to Flash projects

16. Adding text to the text section

Drag your red playhead to the text section of your timeline. Click on the text tool in your tool pallet.

 Text tool in Flash

You will notice that your property inspector will change, giving you various text options.

Text properties in Flash

Unlike the titles you created earlier, this time choose Dynamic Text. Why? Because the text you are about to import will be changeable, meaning it will not stay in one "static" position.

Change your font size to a small number, such as 10, to accommodate a large amount of text. You should also change the text color to black and change the line setting to Multiline to accommodate multiple line breaks.

Multiline button in Flash

Other options include the Ab button, which enables your text to be selectable, the <> angle bracket button, which means your text will render HTML, and the square button, which applies a background to your text.

Draw a text box on your stage and paste in some sample text from the tutorial file sample.txt.

You might have noticed that there is far too much text for the text box you have. In order to shrink your text box, you will have to turn on the Scrollable option found under the Text menu.

Text menu in Flash

Since your text is scrollable we need to add a scroll bar. Simply grab the UI Scrollbar component from your components window pane on to the right side of the text box. Placement is important, because the UI Scrollbar will detect the textbox and latch to the nearest side. To prevent horizontal scrolling, make sure you latch the scrollbar to the right side only.

Placing the UIScrollbar in Flash

The scrollbar won’t be functional in the authoring environment. You will have an opportunity to test it out once we create button actions in the next section.

Working with dynamic text: Dynamic text works a lot differently than static text. Flash converts static text into “outlines,” or graphical images, so you don’t have to worry about fonts. But dynamic text is more like real Web text, so you must embed the fonts.

After selecting a font, click the embed button in your property inspector and choose the glyphs you want to embed.

Embed button in Flash for dynamic text

(The embed button will appear in the property inspector when clicking on a text box.)

Embedding glyphs to Flash

Hold the shift key to select multiple glyphs. For virtually all English text, you will only need four sets: Uppercase, Lowercase, Numerals and Punctuation. Flash allows you to select individual glyphs so that if you're only using certain characters, you don’t have to embed everything, taking up memory on a visitor’s computer.