Bold and Italic HTML text sometimes disappears from a textfield. Here’s a brief tutorial that tries to explain why this happens and more importantly how you can stop it.
The problem occurs when you are using an HTML textfield that has font outlines included. By including font outlines you can ensure that your chosen font will be displayed, even if the user viewing the movie does not have that particular font installed on their machine.
However when you include outlines for a font Flash will only include the outlines for the font style variations (bold, italic, bold and italic) used in the movie. That is, if your movie doesn’t contain a textfield (with font outlines included) that explicitly uses bold text, no bold font outlines will get included in the file.
If a textfield is setup so that it uses embedded font outlines, but is then used to display characters for which the outlines aren’t included in the movie.
The characters that can’t be displayed using the embedded font outlines won’t be displayed at all. This is what is happening when bits of
HTML text goes missing. The use of
i tags in some HTML text
can inadvertently create text that can’t be displayed — unless special care is taken to include all the font outlines that will be required — including the variations of bold and italic.
One easy way you to do this is to creating a hidden textfield (maybe positioned off the edge of the stage) that contains text using all the variations in font styles that will be required for the movie.
To do this, create a textfield off the edge of the stage. From the Character Options dialog box choose to include font outlines for all the characters you need.
Then type some text into the textfield. Using the B and I buttons from the Text Properties inspector make some of this text bold, some italic and some both bold and italic. If you leave some of this text in regular all the possible variations in font style (for the chosen font) will now be included in the movie. With this done all the font styles can safely be used in HTML text.
If you have time, please let me know if there are any other instances that would keep the "disapearing text in html" fix from not working.
Realy this tutorial helped me, before I was in trouble since morning.
Thanks a lot
# Posted by Aamir on 5th December 2006.
Sorry, comments for this item are currently closed.