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

Terminology

Terminology

TOP

ThAs with all scripting languages, ActionScript uses its own terminology. Macromedia Flash also uses unique terminology. The following list provides an introduction to important ActionScript terms, and Flash terms that relate to programming with ActionScript and that are unique to working in the Flash authoring environment.

ActionScript editor is the code editor in the Actions panel and Script window. The ActionScript editor consists of a number of features, such as Auto formatting, showing hidden characters, and color coding parts of your scripts. (Also see: Script window, Actions panel).

Actions panel is a panel in the Flash authoring environment where you write ActionScript code.

Anonymous function is an unnamed function that references itself; you reference the anonymous function when you create it. For information and an example, see Writing anonymous and callback functions.

Alias refers to aliased text that does not use color variations to make its jagged edges appear smoother, unlike anti-aliased text (see following definition).

Anti-alias refers to anti-aliasing characters in order to smooth text so the edges of characters that appear onscreen look less jagged. The Anti-Alias option in Flash makes text more legible by aligning text outlines along pixel boundaries, and is effective for clearly rendering smaller font sizes.

Arrays are objects whose properties are identified by numbers representing their positions in the structure. Essentially, an array is a list of items.

Authoring environment is the Flash workspace including all elements of the user interface. You create FLA files or script files (in the Script window) using the authoring environment.

Bitmap graphics (or raster graphics) are typically photo-realistic images, or graphics with a high amount of detail. Each pixel (or bit) in the image contains a piece of data, and together these bits form the image itself. Bitmaps might be saved in the JPEG, BMP or GIF file formats. Another graphic type, different than bitmap, is vector.
Boolean is a true or false value.

Caching refers to information that is reused in your application, or information that is stored on your computer so it can be reused. For example, if you download an image from the internet, it's often cached so you can view it again without downloading the image data.

Callback functions are anonymous functions that you associate with a certain event. A function calls a callback function after a specific event occurs, such as after something finishes loading (onLoad()) or finishes animating (onMotionFinished()). For more information and an examples, see Writing anonymous and callback functions.

Characters are letters, numerals, and punctuation that you combine to make up strings. They are sometimes called glyphs.

Classes are data types that you can create to define a new type of object. To define a class, you use the class keyword in an external script file (not in a script you are writing in the Actions panel).

Classpath refers to the list of folders in which Flash searches for class or interface definitions. When you create a class file, you need to save the file to one of the directories specified in the classpath, or a subdirectory within that. Classpaths exist at the global (application) level, and at the document level.

Constants are elements that don't change. For example, the constant Key.TAB always has the same meaning: it indicates the Tab key on a keyboard. Constants are useful for comparing values.

Constructor functions (or constructors) are functions that you use to define (initialize) the properties and methods of a class. By definition, constructors are functions within a class definition that have the same name as the class. For example, the following code defines a Circle class and implements a constructor function:

// file Circle.as

class Circle {

private var circumference:Number;

// constructor

function Circle(radius:Number){

this.circumference = 2 * Math.PI * radius;

}

}

The term constructor is also used when you create (instantiate) an object based on a particular class. The following statements are calls to the constructor functions for the built-in Array class

and the custom Circle class:

var my_array:Array = new Array();

var my_circle:Circle = new Circle(9);

Data types describe the kind of information a variable or ActionScript element can contain. The built-in ActionScript data types are String, Number, Boolean, Object, MovieClip, Function, null,

and undefined. For more information, see About data types.

Device fonts are special fonts in Flash that are not embedded in a Flash SWF file. Instead, Flash Player uses whatever font on the local computer most closely resembles the device font.

Because font outlines are not embedded, SWF file size is smaller than when embedded font outlines are used. However, because device fonts are not embedded, the text that you create with them looks different than expected on computer systems that do not have a font installed that corresponds to the device font. Flash includes three device fonts: _sans (similar to Helvetica and Arial), _serif (similar to Times Roman), and _typewriter (similar to Courier).

Dot syntax refers to when you use a dot (.) operator (dot syntax) to access properties or methods that belong to an object or instance on the Stage using ActionScript. You also use the dot operator to identify the target path to an instance (such as a movie clip), variable, function, or object. A dot syntax expression begins with the name of the object or movie clip, followed by a dot, and it ends with the element you want to specify.

Events occur while a SWF file is playing. For example, different events are generated when a movie clip loads, the playhead enters a frame, the user clicks a button or movie clip, or the user types on the keyboard.

Event handlers are special events that manage when the mouse is clicked, or when data finishes loading. There are two kinds of ActionScript event handlers: event handler methods and event listeners. (There are also two event handlers, on handler and onClipEvent handler, that you can assign directly to buttons and movie clips.) In the Actions toolbox, each ActionScript object that has event handler methods or event listeners has a subcategory called Events or Listeners. Some commands can be used both as event handlers and as event listeners and are included in both subcategories. For more information on event management, see Handling Events.

Expressions are any legal combination of ActionScript symbols that represent a value. An expression consists of operators and operands. For example, in the expression x + 2, x and 2 are operands and + is an operator.

Flash Player container refers to the system that holds the Flash application, such as a browser or the desktop application. You can add ActionScript and JavaScript to facilitate communication between the Flash Player container and a SWF file.

FlashType refers to the advanced font rendering technology in Flash 8. For example, Alias Text for Readability uses the FlashType rendering technology, and Alias Text for Animation does not. For information, see About font rendering and anti-alias text.

Frame scripts are blocks of code that you add to a frame on a timeline.

Functions are blocks of reusable code that can be passed parameters and can return a value. For more information, see About functions and methods.

Function literals are unnamed functions that you declare in an expression instead of in a statement. Function literals are useful when you need to use a function temporarily, or to use a function in your code where you might use an expression instead.

IDE refers to an "integrated development environment," which is an application in which a developer can code, test, and debug applications in an interactive environment. The Flash authoring tool is sometimes called an IDE.

Identifiers are names used to indicate a variable, property, object, function, or method. The first character must be a letter, underscore (_), or dollar sign ($). Each subsequent character must be a letter, number, underscore, or dollar sign. For example, firstName is the name of a variable.

Instances are objects that contain all the properties and methods of a particular class. For example, all arrays are instances of the Array class, so you can use any of the methods or properties of the Array class with any array instance.

Instance names are unique names that let you target instances you create, or movie clip and button instances on the Stage. For example, in the following code, "names" and "studentName" are instance names for two objects, an array and a string:

var names:Array = new Array();var studentName:String = new String();
 

You use the Property inspector to assign instance names to instances on the Stage. For example, a master symbol in the library could be called counter and the two instances of that symbol in the SWF file could have the instance names scorePlayer1_mc and scorePlayer2_mc. The following code sets a variable called score inside each movie clip instance by using instance names:

 this.scorePlayer1_mc.score = 0;

this.scorePlayer2_mc.score = 0;

You can use strict data typing when creating instances so that code hints appear as you type your code.

Keywords are reserved words that have special meaning. For example, var is a keyword used to declare local variables. You cannot use a keyword as an identifier. For example, var is not a legal variable name. For a list of keywords, see About keywords and About reserved words.

Literals represent values that have a particular type, such as numeric literals or string literals. Literals are not stored in a variable. A literal is a value that appears directly in your code, and is a constant (unchanging) value within your Flash documents. Also see function literal, and string literal.

Methods are functions associated with a class. For example, sortOn() is a built-in method associated with the Array class. You can also create functions that act as methods, either for objects based on built-in classes or for objects based on classes that you create. For example, in the following code, clear() becomes a method of a controller object that you have previously

defined:

function reset(){

this.x_pos = 0;

this.y_pos = 0;

}

controller.clear = reset;

controller.clear();

The following examples show how you create methods of a class:

//ActionScript 1.0 example

A = new Object();

A.prototype.myMethod = function() {

trace("myMethod");

}

//ActionScript 2.0 example

class B {

function myMethod() {

trace("myMethod");

}

}

Named function is a kind of function that you commonly create in your ActionScript code to carry out all kinds of actions. For information and an example, see Writing named functions.

Object code is ActionScript that you attach to instances. To add object code, you select an instance on the Stage and then type code into the Actions panel. Attaching code to objects on the

Stage is not recommended. For information on best practices, see Best Practices and Coding Conventions for ActionScript 2.0.

Objects are collections of properties and methods; each object has its own name and is an instance of a particular class. Built-in objects are predefined in the ActionScript language. For example, the built-in Date class provides information from the system clock.

Operators are terms that calculate a new value from one or more values. For example, the addition (+) operator adds two or more values together to produce a new value. The values that operators manipulate are called operands.

Parameters (also called arguments) are placeholders that let you pass values to functions. For example, the following welcome() function uses two values it receives in the parameters firstName and hobby:

function welcome(firstName:String, hobby:String):String {

var welcomeText:String = "Hello, " + firstName + ". I see you enjoy " + hobby +".";

return welcomeText;

}

Packages are directories that contain one or more class files and reside in a designated classpath directory (see About packages).

Pinning scripts lets you pin multiple scripts from various objects and work with them simultaneously in the Actions panel. This feature works best with the Script navigator.

Progressive JPEG images are gradually constructed and displayed as they download from a server. A normal JPEG image is displayed line-by-line while it downloads from a server.

Properties are attributes that define an object. For example, length is a property of all arrays that specifies the number of elements in the array.

Punctuators are special characters that help you form ActionScript code. There are several language punctuators in Flash. The most common type of punctuators are semicolons (;), colons (:), parentheses [()] and braces ({}). Each of these punctuators has a special meaning in the Flash language and helps define data types, terminate statements or structure ActionScript.

Script Assist is a new assisted mode in the Actions panel. Script Assist lets you more easily create scripts without having detailed knowledge of ActionScript. It helps you build scripts by selecting items from the Actions toolbox in the Actions panel, and provides an interface of text fields, radio buttons, and check boxes that prompt you for the correct variables and other scripting language constructs. This feature is similar to normal mode in earlier editions of the Flash authoring tool.

Script pane is a pane in the Actions panel or Script window, and is the area where you type your ActionScript code.

Script window is a code editing environment where you can create and modify external scripts, such as Flash JavaScript files or ActionScript files. For example, select File > New and then select ActionScript File to use the Script window to write a class file.

Statements are language elements that perform or specify an action. For example, the return statement returns a result as a value of the function in which it executes. The if statement evaluates a condition to determine the next action that should be taken. The switch statement creates a branching structure for ActionScript statements.

String is a sequence of characters, and a data type. See About strings and the String class for more information.

String literal is a sequence of characters enclosed by straight quote characters. The characters are themselves a data value, not a reference to data. A string literal is not a String object. For more information, see About strings and the String class.

Surface is a movie clip that has its bitmap caching flag turned on. For information on bitmap caching, see Caching a movie clip.

Syntax refers to the grammar and spelling of a language that you program with. The compiler cannot understand incorrect syntax, so you see errors or warnings displayed in the Output panel when you try to test the document in the test environment. Therefore, syntax is a collection of rules and guidelines that help you form correct ActionScript.

Target paths are hierarchical addresses of movie clip instance names, variables, and objects in a SWF file. You name a movie clip instance in the movie clip Property inspector. (The main timeline always has the name _root.) You can use a target path to direct an action at a movie clip, or to get or set the value of a variable or property. For example, the following statement is the target path to the volume property of the object named stereoControl:

stereoControl.volume

Text is a series of one or more strings that can be displayed in a text field, or within a user interface component.

Text fields are visual elements on the Stage that let you display text to a user, which you can create using the Text tool or using ActionScript code. Flash lets you set text fields as editable (read-only), allow HTML formatting, enable multiline support, password masking, or apply a CSS style sheet to your HTML formatted text.

Text formatting can be applied to a text field, or certain characters within a text field. Some examples of text formatting options that can be applied to text are: alignment, indenting, bold, color, font size, margin widths, italics, and letter spacing.

Top-level functions are functions that don't belong to a class (sometimes called predefined or built-in functions), meaning that you can call them without a constructor. Examples of functions that are built in to the top level of the ActionScript language are trace() and setInterval();.

User-defined functions are functions that you create to use in applications, as opposed to functions in built-in classes that perform predefined functions. You name the functions yourself and add statements in the function block.

Variables are identifiers that hold values of any data type. Variables can be created, changed, and updated. The values they store can be retrieved for use in scripts. In the following example, the identifiers on the left side of the equal signs are variables:

var x:Number = 5;

var name:String = "Lolo";

var c_color:Color = new Color(mcinstanceName);

For more information on variables, see About variables.

Vector graphics describe images using lines and curves, called vectors, that also include color and position properties. Each vector uses mathematical calculations, instead of bits, to describe

the shape, which allows them be scaled without degrading in quality. Another graphic type is bitmap, which is represented by dots or pixels.

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