Archive for August 2nd, 2007

02
Aug

Using special characters in your Flex applications

Another good question/dilemma came up on FlexCoders the other day. A curious poster asked how you could embed a copyright symbol, ©, into a Flex application since using © did not seem to work. As it turns out, an easy way to do this is to use a character’s numeric value (©) instead of its code name (©).

Well, at any rate, here’s a handy little chart thing-a-ma-jig to hopefully help out if you’re looking for some specific codes. Granted, you could have probably found it on Google in a fraction of the time, but what fun would that be?

Full code after the jump.

Continue reading ‘Using special characters in your Flex applications’

02
Aug

Finding a pixel’s color value using the Bitmap classes and getPixel()

This example loads an image and then uses a combination of the Bitmap and BitmapData classes to determine the color value under the mouse cursor. Pretty basic, but kind of neat. Maybe? Sorta?

Full code after the jump.

Continue reading ‘Finding a pixel’s color value using the Bitmap classes and getPixel()’

02
Aug

Adding icons to Panel containers

Personally, I’m amazed I can write an entire post around setting a single (and simple) style, but yet here I am. The following example shows how you can place an icon of your choosing in the upper-left corner of a Panel container. As an added bonus, at least I create the Panel in both MXML and ActionScript.

Full code after the jump.

Continue reading ‘Adding icons to Panel containers’

02
Aug

Rounding a Panel container’s corners using the cornerRadius style

Another quick sample (I’m cleaning out my Flex projects from the past year). This time we look at controlling a Panel container’s roundness versus squareness by setting the cornerRadius style.

Just drag the slider to control the corner radius of the two panels (one with a ControlBar and one without).

Full code after the jump.

Continue reading ‘Rounding a Panel container’s corners using the cornerRadius style’

02
Aug

Using the Validators.validateAll() method to validate a form

I recently saw this issue in FlexCoders and filed a bug for the poster. Well, it turns out the bug I filed was a duplicate of an existing bug, and that bug has been fixed (in Flex 3 — codename:Moxie). So, long story longer, here’s how you can use the Validator class’s validateAll() method to validate a form (which may or may not have enabled validators).

Full code (and workaround) after the jump.

Continue reading ‘Using the Validators.validateAll() method to validate a form’

02
Aug

Scrubbing an FLV using the VideoDisplay control and a slider

In yet *another* post about the VideoDisplay control, this time we look at formatting playback times using the DateFormatter class/tag, creating a basic scrubber using an HSlider control, and applying a mildly annoying Zoom effect to the video.

Also, we tweak the slider control (or more accurately HSlider) and prevent users from clicking on the slider track (thanks to the allowTrackClick property, we set the liveDragging property to false to make sure we arent needlessly seeking around the video every time the slider thumb moves, and finally we invert the thumb arrow for no other reason than I didn’t know you could do that so easily.

Oh, and I also created a faux looping video by using the autoRewind property, and calling the play() method in the rewind event handler.

Full code after the jump.

Continue reading ‘Scrubbing an FLV using the VideoDisplay control and a slider’




Badge Farm

  • Firefox 2
  • Powered by Redoable 1.2
  • Feeds burnt by Feedburner
  • Feed