| < Day Day Up > |
|
Download CD Content
Symbols are the main reason that file sizes in Flash can be kept to a minimum. Symbols are usable elements that are stored in the Library with other assets, such as sound and video. When a symbol is produced it is automatically added to the Movies library. You can drag an instance (a copy) of the symbol into your movie as many times as you'd like. Libraries can be shared between movies and even be made available to all movies.
The Library contains all the symbols for your movie. When you make a Movie Clip, button symbol, or graphic symbol, they all are automatically added to the Library. You can also import bitmaps, sound, and video files. Every Flash movie has its own library, but you can drag a symbol or other asset from open Flash movie into another. To open the Library, press F11. Figure 26-1 shows the Library with various assets. Notice the different icons that represent the type of asset in the Library. The icon appears first, then the name of the item, then the type. You can change a name by opening the Library Options pop-up menu and selecting Rename.
Figure 26-1: A library showing various icons, names, and types
You can import any graphic, image, sound, or video file into your current movie's library by choosing File ® Import to Library. The asset is added to the Library. You can then add it to your movie as many times as you want. You can also access items, such as sound, from the Library without placing them on the Timeline by using ActionScript.
Cross-Reference | You learn how to access sound from the Library using ActionScript without placing it in the Timeline in Chapter 29. |
Your symbols or other assets are automatically added to the movie's Library when you produce them or when you drag one from another library. To add sound, bitmaps, vectors, or QuickTime to the Library, you import them into your movie.
To use a symbol or other asset from the Library, you simply drag an instance (a copy) of the symbol or asset to the stage.
If you have more than one movie open, you can drag assets from one to another. But if you don't have other files open and don't need them open, you can still borrow the assets of another movie by opening its library. Choose File ® Open as Library, navigate to the file that has the library you want, select it, and click Open. Only the Library opens, not the whole file. This is similar to the way common libraries work except it's more a use-as-you-need method rather than having the library permanently available.
There is another type of library, a common library. If you choose Window ® Common Libraries there are three options. These are libraries that are common and available to all movies. If you have a library in a movie that you want to make into a common library, save your Flash file with a descriptive name and place into the Libraries folder of the Flash program on your hard drive. You can delete this file anytime you decide you don't want it any longer. As soon as you drop the file into the Libraries folder it is available in Flash. You don't have to close and reopen the program.
| < Day Day Up > |
|