button Element

The button element creates a button with the attributes described below.

Syntax

<button id="objectId" type="objectType" startSound
        up="objectUp" over="objectOver"
        down="objectDown" hit="objectHit"/>

  <!-- button sounds -->
  
  <!-- button actions -->
  
</button>

Attributes

Name

Description

Value type

Optional

Default Value

id

Object identifier, which must be unique among all the objects described in the XML file.

id

no

-

type

Button type

string

no

-

up

ID of the shape for normal button state.

string

no

-

over

ID of the shape for button state, when user move mouse over the button.

string

no

-

down

ID of the shape for this button state (button is pressed).

string

no

-

hit

ID of the button area shape. This shape is not visible on screen, it defines boundaries within which the button will respond to mouse over.

string

no

-

The button tag may contain actions and sounds that must be started when a certain event happens. For button sounds only following events are supportd: rollOver, rollOut, press, release.

Parent Elements

objects collection

Child Elements

actionFSCommand, actionGoToFrame, actionGoToLabel, actionGetURL, actionPlay, actionStop, actionStopSounds, startSound, stopSound

See Also

XML Schema Reference, objects collection