4 # Programming Languages {#programming-languages}
6 DALi applications can be written in several different programming languages.
11 Dali::Actor actor = Dali::Actor::New();
12 actor.SetParentOrigin( Dali::ParentOrigin::CENTER );
13 actor.SetAnchorPoint( Dali::AnchorPoint::CENTER );
14 Dali::Stage::GetCurrent().Add( actor );
16 bool OnPressed( Dali::Actor, const TouchData& touch )
18 Dali::Animation anim = Dali::Animation::New( 1.5f );
19 anim.AnimateTo( Property( actor, Actor::Property::POSITION ), Vector3( 200, -100, 0 ), AlphaFunctions::Bounce );
21 return true; // consume the touch event
24 actor.TouchSignal().Connect( &OnPressed );
29 ## JavaScript {#java-script-support}
32 var actor = new dali.Actor();
33 actor.parentOrigin = dali.CENTER;
34 actor.anchorPoint = dali.CENTER;
35 dali.stage.add( actor );
37 function onPressed( actor, touch )
39 var animOptions = { alpha: "bounce", delay: 0, duration: 15 };
40 var anim = new dali.Animation();
41 anim.animateTo( actor, "position", [ 200, -100, 0 ], animOptions );
43 return true; // consume the touch event
46 actor.connect( "touch", onPressed );
50 ## JSON {#json-support}
63 "property":"position",
65 "alphaFunction": "BOUNCE"
75 "anchorPoint": "CENTER",
76 "parentOrigin": "CENTER",
79 { "name" : "touch", "action": "play", "animation": "move" }