What is Software? | What is Education? | What is Technology? | What is Research? | What is Wi-Fi? | What is Communication? | What is Customer Service?

Free SEO Tutorials & Help

Tutorials:   Adobe Flash   Adobe Photoshop   CorelDRAW   SEO  

Site Map

Website Development | Cable & Broadband Magazine | Solutions for Higher Education | Auction Anything Online

 

Adobe Flash Help & Tutorials

 Back to Topics

 

 How to Work with Layers in Flash

Basic Tasks: Work with Layers

Set up your workspace

Select a layer

Hide and show layers

Lock a layer

Add and name a layer

Change the order of layers

Organize layers in a folder

Add a mask layer

Delete a layer

Summary

 

Basic Tasks: Work with Layers

TOP

In Macromedia Flash Basic 8 and Macromedia Flash Professional 8, layers are analogous to transparent sheets of acetate stacked on top of each other. In the areas of a layer that don't contain content, you can see through to content in the layers below. Layers assist you in organizing content in your document. For example, you can keep background art on one layer and navigational buttons on another. Additionally, you can create and edit objects on one layer without affecting objects on another layer.

 

Set up your workspace

#TOP

First, you'll open the start file for the lesson and set up your workspace to use an optimal layout for taking lessons.

  1. To open your start file, in Flash select File > Open and navigate to the file:

    • In Windows, browse to boot drive\Program Files\Macromedia\Flash 8\Samples and Tutorials\Tutorial Assets\Basic Tasks\Work with Layers and double-click layers_start.fla.

    • On the Macintosh, browse to Macintosh HD/Applications/Macromedia Flash 8/Samples and Tutorials/Tutorial Assets/Basic Tasks/Work with Layers and double-click layers_start.fla.

    NOTE The Work with Layers folder contains completed versions of the tutorial FLA files for your reference.

  2. Select File > Save As and save the document with a new name, in the same folder, to preserve the original start file.

  3. Select Window > Workspace Layout > Default to set up your workspace for taking lessons.

  4. In the Stage View pop-up menu, in the upper-right side of the Timeline, select Show Frame to view both the Stage and the workspace.

  5. If necessary, drag the lower edge of the Timeline (Window > Timeline) down to enlarge the Timeline view.

    You can also use the scroll bar to scroll through the layers.

 

Select a layer

TOP

You place objects, add text and graphics, and edit on the active layer. To make a layer active, you either select the layer in the Timeline or select a Stage object in the layer. The active layer is highlighted in the Timeline, and the pencil icon indicates it can be edited.

  1. In the Tools panel, click the Selection tool.

  2. On the Stage, select the red car.

    A pencil icon in the Timeline indicates that the Red Car layer is now the active layer.

  3. Select the Text layer in the Timeline.

    The text blocks above and below the red car are both selected on the Stage, since they're both on the Text layer.

     

Hide and show layers

TOP

You can hide layers to view content on other layers. When hiding layers, you have the option of hiding all layers in your document simultaneously or hiding layers individually.

  1. Click the eye icon above the layers so that a red X appears in the Eye column.

    All content disappears from the Stage.

  2. One by one, click each red X in the column and watch the content for the layer reappear on the Stage.

    Controls to the right of each layer name let you show or hide the contents of a layer.

NOTE You may need to use the scroll bar to see all the layers.

 

Lock a layer

TOP

When you've placed content as desired on a layer, you can lock the layer to avoid inadvertent changes to the content by you or by others working on the document.

  1. In the Timeline, click the black dot under the Lock column, next to the Logo layer.

    A padlock icon appears, indicating the layer is now locked.

  2. With the Selection tool, try to drag the logo that appears along the top of the Stage.

    You can't drag the logo, because the layer is locked.

NOTE If you accidentally drag something from an unlocked layer, press Control+Z (Windows) or Command+Z (Macintosh) to undo your change.

 

Add and name a layer

TOP

You'll now add a layer, name the layer, and then add a graphic symbol to the layer.

  1. In the Timeline, click the Car layer.

  2. Click Insert Layer below the Timeline.

    The new layer appears above the Car layer and becomes the active layer.

  3. Double-click the layer name, type Background as the new name for the layer, and press Enter (Windows) or Return (Macintosh).

    As a best practice, always name each layer, and give the layer a meaningful name that indicates the type of content in the layer.

  4. In the Library panel (Window > Library), select the background graphic symbol and drag it to the Stage.

    Because the Background layer is above all layers except the Mask layer, objects on that layer appear over objects on lower layers.


 

Change the order of layers

TOP

Obviously, you don't want the background to cover the other objects on the Stage. Normally, the background layer is the bottom layer on the Timeline. You'll move the Background layer you just created.

  1. In the Timeline, drag the Background layer from the top position to the bottom position.

    All objects on the Stage now appear on top of the background.

  2. With the Background layer still selected, in the Property inspector, enter 0 in the X text box and 72 in the Y text box. Press Enter (Windows) or Return (Macintosh) to precisely position the Background layer on the Stage.

 

Organize layers in a folder

TOP

You can create layer folders to organize layers and reduce Timeline clutter. The Timeline contains two layers that contain navigation objects: one for navigational buttons and another for navigational art. You'll create a layer folder, named Navigation, for both layers.

  1. In the Timeline, select the Buttons layer.

  2. Click Insert Layer Folder, which is below the layer names.

    NOTE If the Property inspector shows properties for the frame rather than for the movie clip, click the Background movie clip on the Stage.

  3. Double-click the layer folder name and rename the folder Navigation.

  4. Drag the Navbar layer and the Buttons layer to the Navigation folder.

    The layers appear indented to indicate that they're within the folder.

    You can click the expander arrow to expand and collapse the folder and included layers.

 

Add a mask layer

TOP

Using a mask layer provides a simple way to selectively reveal portions of the layer or layers below it. Masking requires making one layer a mask layer and the layers below it masked layers.

You'll use the rectangular shape on the Stage to mask part of the road graphic and animation so that the animation fits better on the Stage.

  1. On the Stage, with the Selection tool selected, click the rectangular shape below the road.

  2. Drag the shape straight up and align the left edge of the shape with the left edge of the road.

  3. Right-click (Windows) or Control-click (Macintosh) the Mask layer in the Timeline and select Mask from the context menu.

    The layer converts to a mask layer, indicated by a blue diamond-shaped icon. The layer immediately below the layer is linked to the mask layer. The masked layer's name is indented, and its icon changes to a blue layer icon.

  4. In the Timeline, drag the Road layer to the Mask layer, placing it below the Car layer.

    The mask layer and the layers it masks are automatically locked.

  5. To view the mask effect, select Control > Test Movie.

  6. When you finish viewing the mask effect, close the SWF file window to return to your document.

 

Delete a layer

TOP

Because you don't really need the guide layer in your document, you'll delete it.

  • In the Timeline, with the Notes layer selected, click the Delete Layer button.

 

Summary

TOP

Congratulations on learning how to work with layers in Flash. In just a few minutes, you learned how to accomplish the following tasks:

  • Select a layer.

  • Hide and show layers.

  • Lock a layer.

  • Add and name a layer.

  • Change the order of layers.

  • Organize layers in a folder.

  • Add a mask layer.

  • Add a guide layer.

  • Delete a layer.

To learn more about Flash, take another lesson.

 

Copyright ADOBE - All Rights Reserved Worldwide

 

 

More Topics:

Working with Flash Documents

How to work in Flash WorkSpace

Working with Projects in Flash

Process to Build your First Application in Flash

Using Symbols, Instances and Library Assets in Flash

How to Build Video Player in Flash

How to Work with Color, Strokes and Fills in Flash

How to Create Document in Flash

What is Vector and Bitmap Graphics in Flash

How to Create a Banner in Flash, Part 1

How to Work with Text in Flash

How to Create a Banner in Flash, Part 2

How to Use Imported Artwork in Flash

How to Create a Banner in Flash, Part 3

How to Work with Graphic Objects in Flash

How to Work with Layers in Flash

How to Use Filters and Blends

Working with Graphics in Flash

What is Accessibility Features in Flash

How to Create Motion (Shape Tween & Motion Tween) in Flash

How to Create an Application in Flash

What is Masking in Flash

How to Work with Video in Flash

How to Use Layout Tools in Flash

What are Behaviors in Flash

How to Work with Sound in Flash

How to Create Symbols and Instances in Flash

What is ActionScript in Flash

How to Write ActionScript With Script Assist in Flash

How to Add Button Animation and Navigation in Flash

What is Data Integration in Flash

How to Work with Screens

How to Create a Presentation with Screens

What is Extending Flash

How to Create Multilanguage Text in Flash

How to Create Graphics: Draw in Flash

What is Flash Lite

Ways of Data Integration

How to Create Graphics: Create a Timeline Animation in Flash

Getting Started with Flash Lite in Flash

How to Publish Flash Documents

How to Create Graphics: Making Animations with Easing

Learning Flash Lite 1.X ActionScript in Flash

How to Export Flash Content and Images from Flash

How to Create Graphics: Applying Gradients in Flash

Process of Writing and Editing ActionScript 2.0 in Flash

How to Create Accessible Content in Flash

How to Create Graphics: Apply Graphic Filters and Blends

What is Data and Data Types in Flash

Process of Printing from SWF Files in Flash

Using ActionScript: How to Use Script Assist mode in Flash

Learn Syntax and Language Fundamentals in Flash

How to Create E-learning Content in Flash

Using ActionScript: How to Write Scripts in Flash

Working with Functions and Methods in Flash

Process of Using Templates in Flash

Using ActionScript: Process of Adding Interactivity in Flash

What are Classes in Flash

Control Tag Summary of XML to UI in Flash

Using ActionScript: How to Create a Form with Conditional Logic and Send Data in Flash

What is Inheritance in Flash

What is Data Integration: Overview

Using ActionScript: How to Work with Objects and Classes in Flash

Overview on Interfaces in Flash

What is Data Integration: Using XML for a Timesheet

How to Work with Text and Strings in Flash

How to use Handling Events in Flash

What is Data Integration: Using XUpdate to Update the Timesheet

Learning Animation, Filters and Drawings in Flash

How to Work with Movie Clips in Flash

How to Create Interaction with ActionScript in Flash

How to Work with Images, Sound, and Video in Flash

How to Work with External Data in Flash

What is Security in Flash

How to Debug Applications in Flash

List of Error Messages in Flash

Using Object-Oriented Programming with ActionScript 1.0 in Flash

How to Write Scripts for Earlier Versions of Flash Player in Flash

List of all Keyboard Keys and Key Code Values for using in Flash

Terminology

Introduction to Components in Flash

What are Components in Flash

How to Create an Application with Components

How to Work with Components in Flash

How to Handle Component Events in Flash

How to Customize Components in Flash

How to Create Components in Flash

What is Collection Properties in Flash