Flash components – As Forms

March 16th, 2006 by ae

Anyone who has done any serious flash development has worked out that the macromedia components are bloated and buggy. There are some really decent open source alternatives out there but in general they didn’t suit me for a project I was about to start. Check here for an open source component list.

The project was basically a online registration form- the app had to capture data, process some of it then post it to a server. For something like this a full blown component framework was overkill. And because of the older userbase the components had to look very similar to existing html components so that there would be no confusion (hopefully :) ).

My requirements were:

- they had to look like established user interface components (a radio button had to look like a html radio button).

- they had to be very small in size (anything over 40k was way too big)

- they had to be as fast as using a browsers components (that is, they draw with no lag whatsoever)

- they needed to be skinnable (in regards to colours and size mainly)

- they had to respond to events and be easily redrawn

Although all of the open source flash alternatives were of a high quality they just didn’t quite fit my requirements.

So, I set about creating my own. Below you will find an example of what I have temporarily called As Forms (until I can think of a snappier name).

They are small in size – the movie below is only 12k.
Its super simple to change the colours, size and fonts. However changing the shape requires getting your hands dirty in the core code. For example if you dont like the arrow in the combobox then you will need to edit the draw code for it.
They are really snappy which I’m really happy with. The reason I think they are snappy is because of the hard coded shapes. By limiting how much you can change, you gain speed improvements. They are also quite independent in terms of kb size. For example the movie below with all components in it is 12k, a movie with only the radio buttons is 4k. With macromedia just the radio buttons comes in at 90k last time I tried :)

These components are designed for people who just want quick and easy components – rather than the more full blown one. Over the coming week I will tidy up the code and release it under the GPL. They are already being used in production without any issues, but I’d hate to release something without tidying up my abusive comments in code :)
Here is an example of the flash forms. When you click the submit button (which isn’t apart of AS Forms) it will email me your response

[kml_flashembed movie="/flashForms/FormExamples.swf" height="650" width="333" /]

technorati tags: , ,

7 Comments » Comments to this post

7 Responses to “Flash components – As Forms”

  1. iiley Says:

    Awesome, only 12k, really snappy, can’t wait to see it to be published. :)

  2. Philippe Says:

    interesting – too bad there is no focus management though

  3. lazygekko Says:

    This looks really good – any ideas on when it will be released?

  4. ae Says:

    Iiley: Thanks Iiley – thats good praise coming from the author of AsWing

    Philippe: well spotted! focus management is in fact implemented except its implemented badly :)
    Its on the list of things to tidy up

    Lazygekko: i will try and get something out before the week is up.

  5. Aaron Says:

    These look very good. Are you still planning to release them?

  6. ae Says:

    Hi Aaron

    Yeah i’m still planning on releasing them – i’ve just been trying to get the documentation done – which is taking longer than i expected – plus being quite busy hasn’t helped :)

    i’ll release something tonight. honest :)

  7. ae Says:

    ok its released :)

Leave a Reply