Asv3's Blog

November 5, 2009

Issue with HitArea in Canvas hitArea

Filed under: flex — Tags: , , , , , , , , , , — asv3 @ 6:29 am

I happen to generate a graph in Flex, I needed node element to store data, and have some graphics inside that, without second thought I extended Canvas component for GraphNode.

In flex when you use Canvas to draw some thing behind origin or point (0,0)  hitArea of that Canvas happens to behave strangely. I could figure out this problem by giving background colors to this Canvas. You can resolve it in 2 ways,

1. Use a UIComponent for inside a Canvas and set hitArea of that Canvas to it’s child UIComponent

2. Use Container instead of Canvas. If you don’t want given component to respond to updateDisplayList you can safely extend from Container (mx.core.Container)

PS: To have all your graphics behind (0,0) visible, you should have clipContent set to false.

September 26, 2009

Introduction to Flex

Filed under: flash, flex — Tags: , , , , — asv3 @ 10:43 pm

What is Flex?
Flex is the way to make Rich Internet Applications quickly and easily. It’s a framework for creating RIAs that run with widely deployed Flash Player. At its heart it uses two languages namely MXML, a markup language based on Extensive Markup Language (XML) and ActionScript an EMCAScript based native scripting language of Flash platform.

Why Flex?
Quick, Easy, Well Supported: Flex gives you interactivity in a robust development environment. The Flash Platform gives you more reach and more tools than any other technology out there. It really is the next generation of web applications and Flex has made it easy to jump in and take advantage.

Flex is nothing but Flash: Just like Flash movies Flex is deployed as SWF files to be played in Flash run-time environments like Flash Player in browser, Adobe Integrated Runtime (AIR) and Flash Lite (mobile Flash player).

September 3, 2009

Overview Actionscript

Filed under: flash, flex — Tags: , , , — asv3 @ 4:30 pm

ActionScript is a programming language for Flash Player run-time environment. It was developed targeting designers to help them program interactivity. Today ActionScript enables efficient programming of flash applications ranging from Intros to complex, data-driven interactive applications.

ActionScript 1 started with Flash 5, which used “prototype” extensively to program interactive components for flash movies. ActionScript 2 was introduced with Flash MX 2004, which for the first time got Object Oriented concepts and implementations. Even though programmers using OOP methodologies final compiled binary was still using the ActionScript 1 format, hence the performance of flash applications were not that good by then.

Here came ActionScript 3, will lots on improvements over earlier version, AVM (ActionScript Virtual Machine) was written from the scratch, standardized components creation and usage methods. Closing up lot many security loop holes, still maintaining the backward support.

Blog at WordPress.com.