Home > ActionScript, Air, Flex > How to set width of close button icon (Flex)

How to set width of close button icon (Flex)

Here is how you can set close button icon width and height of the TitleWindow:

<?xml version=”1.0″ encoding=”utf-8″?>
<mx:TitleWindow xmlns:mx=”http://www.adobe.com/2006/mxml&#8221; layout=”absolute” width=”400″ height=”300″

import mx.core.mx_internal;

private function init():void
use namespace mx_internal;
mx_internal::closeButton.buttonMode = true;
closeButton.$width  = 14; //Change the button width to 14 pixels
closeButton.$height = 14; //Change the button height to 14 pixels


border-color: #FFFFFF;
corner-radius: 10;
closeButtonUpSkin=Embed(source=”/com/test/skin/assets.swf”, symbol=”ButtonUp”);
closeButtonDownSkin=Embed(source=”/com/test/skin/assets.swf”, symbol=”ButtonUp”);
closeButtonOverSkin=Embed(source=”/com/test/skin/assets.swf”, symbol=”ButtonDown”);



Categories: ActionScript, Air, Flex
  1. No comments yet.
  1. No trackbacks yet.

Leave a Reply

Fill in your details below or click an icon to log in:

WordPress.com Logo

You are commenting using your WordPress.com account. Log Out /  Change )

Google+ photo

You are commenting using your Google+ account. Log Out /  Change )

Twitter picture

You are commenting using your Twitter account. Log Out /  Change )

Facebook photo

You are commenting using your Facebook account. Log Out /  Change )


Connecting to %s

%d bloggers like this: