Import Complex Formatting in Flash #45
Chapter 6, Text
relatively fast. If the word lists are large, then the appropriate solution
depends on the degree to which the alphabetical word order is counter-
This technique of capturing popular words can be used for more than auto-
completing text. It can be used to accumulate statistics to, say, track the
most popular answer to a survey question or to suggest popular search terms
when no matches can be found for the requested search term. Of course,
those more sophisticated uses apply primarily when you are capturing data
on the back end server. This hack captures data locally, assuming that each
user’s commonly entered words are specific to her (such as her name and
street address). You could use Flash Remoting or other approaches to
upload the data to a server and accumulate statistics across multiple users.
Import Complex Formatting in Flash Hack #45
Reproduce complex text/graphic layouts such as mathematic notation in
Flash using Microsoft Word as a capture buffer and cleanup tool.
As Flash becomes more ubiquitous, it is being used for applications other
than pure web site design. Online learning sites require Flash to display
complex text formatting, as seen in mathematical equations for science and
For example, the MathWorld site (http://mathworld.wolfram.com) exceeds
the limitations of basic HTML fairly quickly; the equations at MathWorld
are implemented as bitmap slices within HTML tables. Those pages must
have taken ages to build! It is far easier to use Flash rather than HTML for
nonstandard text layouts. Not only can Flash place text with pixel preci-
sion, but the text also remains editable.
Flash’s formatting capabilities don’t end with text layouts, however; you can
reproduce other complex formatting in Flash beyond traditional web lay-
outs. As we will see, you can copy an entire HTML page layout into Flash!
Create Math-Formatted Text
You can create math equations in Microsoft Word using the Equation Edi-
tor. This tool is not installed as part of the Microsoft Office default installa-
tion. To install it in Windows XP (using Office XP), go to the Windows
Control Panel and click on the Add or Remove Programs icon. Find
Microsoft Office XP and click the Change button. In the Microsoft XP Setup
dialog box that appears, choose the Add or Remove Features radio button
and click Next. You can now install the Equation Editor (you will find it
under Office Tools), as shown in Figure 6-7.
Chapter 6, Text
#45 Import Complex Formatting in Flash
You can also install the Equation Editor on Mac OS X as part of the
Microsoft Office Value Pack component that comes on the Microsoft Office
for Mac OS X CD-ROM; however, this hack’s techniques seem to work bet-
ter on Windows than on the Mac.
After installing the Equation Editor, to use it from within Microsoft Word,
➝ Object and choose Microsoft Equation. You can then create
your equation using the Equation Editor toolbar that appears. The main
Microsoft Word pull-down menus also change to facilitate adding further
equation-specific formatting (particularly adding subscripts, superscripts,
and Greek symbols).
You can upgrade the Equation Editor with MathType (http://www.mathtype.
com), a third-party equation editor for Word. (Word may give you a pester
dialog box to tell you about MathType when you first use the Equation Edi-
tor.) MathType objects are more complex than Equation Editor’s standard
output, and Flash doesn’t seem to be able to import them. So decline the
invitation if your goal is to use math equations in Flash.
Figure 6-7. Installing the Equation Editor that comes with Microsoft Office