Express in Bits Blog

AS3: ScrollPane, Mask & Dynamic TextField

Posted in Actionscript 3 by xding78 on February 17, 2010

Lately I ran into an issue that really had puzzled me. Now that I finally figured out what the * had happened. I just want to write  it down so that I won’t waste any time on it later.

Here is what happened. I need to use dynamic text in the source of a ScrollPane component. So I did the usual way. Add the dynamic textField to a MovieClip called: contents. And then I initiate a ScrollPane called: sp, then:

sp.source = contents

And ctrl+Enter, to my surprise the textField does not show up!!

… several hours later …

Here is the problem: Mask!!!

Mask is used in the ScrollPane component. So, in order for dynamic text to work properly in a ScrollPane it has to bend to the rules of what Mask demands.

When used under a mask, a dynamic textField has to embed fonts.

After I embedded the font to the dynamic textfield, I can finally see the text.

So, it’s It is the Mask but not the ScrollPane that caused the problem. The ScrollPane component is perfectly fine with containing dynamic text.


AS3: Use Dynamic TextField in Buttons

Posted in Actionscript 3 by xding78 on February 17, 2010

When you develop Flash animation for a while you’re bond to run into this issue: How can I use dynamic textField in a button and make it behave like a button?

To make any Sprite or MovieClip a button is as simple as telling AS3 that:

mc.buttonMode = true;

However, if you happen to use a dynamic textField in the MovieClip or Sprite then you have a problem. Whenever mouse hovers the textField, the mouse cursor changes to the cursor that typically associate to text input field. While that’s not what you want for a button.

I’m sure there are many solutions, the solution I use is kind of quick and dirty. I call it Button Mask.

Here are the steps (use timeline):

  1. Draw a shape that covers the entire button mc.
  2. Make in a MovieClip itself, give it an instance name, i.e. “btnMask
  3. Make sure the “btnMask” object is on the top layer.
  4. Make sure that the “btnMask” object is there but invisible: either set the Alpha value of the “btnMask” object to zero or make sure that the fill Alpha of the object is zero.
  5. In the actionscript code:

    mc.btnMask.buttonMode = true//mc is the instance name of the MovieClip

    mc.btnMask.addEventListener(MouseEvent.CLICK, mcClicked);

    function mcClicked(e:MouseEvent):void{
; //when clicked, mc goes to frame 2


The key here is that you have to remember to manipulate on the (which is the mc), instead of (which is the btnMask). If you encounter any problem, such as the compiler complains no such object, then it’s  always useful to first use :


to find out what exactly is the object that hovered by mouse.

If you construct everything from actionscript 3 code, then what you need to do is

  1. draw a shape
  2. give it an instance name
  3. add it to MovieClip
  4. set the index of this shape to the top
  5. Then the same code.

A Must-have Utility if you are using Windows Live Writer – Tag Enabler

Posted in Reviews by xding78 on February 14, 2010

If you are using Windows Live Writer to blog, you must’ve been annoyed by the fact that somehow adding Tag is out of reach. Luckily, there is one utility solve the problem once and for all. A must-have, the Tag/Keyword Enabler:

It’s so simple. I wish all the applications are like that.

Bing Images Search – nice filtering

Posted in Reviews by xding78 on February 14, 2010

I often like to search for images, and images in particular specifications in terms of size, layout, color, etc. Here is what Bing Images search supports:

Vodpod videos no longer available.

more about "Bing Images Search Filters", posted with vodpod

After playing with Bing Images search for a while, I wondered if Google Images search has the same thing. Yes Google Images does provide the options, it’s just nearly impossible to see if you are not searching. Typical Google.

Vodpod videos no longer available.

more about "Google Image search Filters", posted with vodpod

It’s funny that I noticed the feature in Bing and then I went back to Google to actively search for the feature in Google. Kinda of same of the privacy window. I found the Incognito window through InPrivate. I just thougth whatever MS has Goolge probably also has and vice versa.

Tagged with: , ,

Good experience with IE 8

Posted in Opinion, Reviews, User Experience by xding78 on February 14, 2010

I started to really explore IE 8 and Bing from 1.5 hours ago triggered by the positive news of the coming marriage between MS and Yahoo.

Accelerator – dreams come true!

For years I wish there is a browser provides a shortcut of different services. For instance, the most common one would be,, or Let’s compare the following scenarios and find out the benefit of using Accelerator.

Scenario: from Wikipedia –> IMDB

I’m searching characters of TV series on wiki, I would like to check certain actor/actress on

Old fashioned way:

  1. copy the name of the actor/actress
  2. start a new browser window/tab
  3. make sure mouse is at the address bar of the new window/tab
  4. type in
  5. paste the name into the search box of imdb

With Accelerator:

  1. select the name of the actor/actress
  2. wait 1 second for the Accelerator icon shows up or right click
  3. select IMDB icon from the dropdown list.

Of course, to be honest, in order to be perfect, Accelerator has a long way to go, especially to manage the Accelerator at this moment takes quite some efforts. And it is confusing. There are at least two types of Accelerators, Default Accelerators and Accelerators. The default Accelerators appear directly in the dropdown list. Non-default Accelerators can only be accessed through the 2ndary dropdown list “All Accelerators”, as shown below.


InPrivate – A little more privacy

There is a very interesting article about InPrivate, IE 8: InPrivate Browsing Mode Details. It’s interesting because according to this article, InPrivate is been used because users want to browse naughty stuff. That is quite a statement. I don’t really agree. Oh, yes, there are so many reasons why we don’t want big corporations know what we are doing. Anyway, here is the summary of what InPrivate can do:

  1. InPrivate™ Browsing lets you control whether or not IE saves your browsing history, cookies, and other data
  2. Delete Browsing History helps you control your browsing history after you’ve visited websites.
  3. InPrivate™ Blocking informs you about content that is in a position to observe your browsing history, and allows you to block it
  4. InPrivate Subscriptions allow you to augment the capability of InPrivate Blocking by subscribing to lists of websites to block or allow.

Who decided that only password is forgettable? How about Usernames?

Posted in Opinion, User Experience by xding78 on February 7, 2010

Since the first year I was on Internet, I’ve been kept wondering why there is never options like “forget your user name?” Why that all the administrators automatically assume that I could only forget my password but not my user name? Why?

The reality is that when I need to retreat log in information, 95% of the time I forgot the username instead of the password. I could always manage my passwords very well since there is no constrain in setting passwords. Your password wouldn’t be rejected because somebody else happens to use the same password. However setting user names usually does have many constrains. First of all, if it’s unique, which means if somebody has already used the string I wanted to use as my ID I would have to make up another name. Which is why I’m maintaining much less passwords than usernames at a time.

Plus, what I really hate is that when I request the “lost” password, I receive an email with the exact password just in plain text. Great, now everybody sees my password!

So, PLEASE, give us the right to forget username!!!!

Project really makes sense

Posted in Opinion, Project management by xding78 on February 3, 2010

Any one who has ever been working in (a) multidiscipline team(s) on a complex IT-related project must take a look at

So, does it remind you something?

I was working on a presentation and suddenly realized how those images are totally making sense and that these sketches are the best way to immediately make my point.