Latest Tutorials| Questions and Answers|Ask Questions?|Site Map



Home Answers Viewqa Flex Flex4 container
Login         

View Questions and Answers by Category

Advertisements


 
Have Programming Question? Ask it here!
 
 
 


BikrantSingh
Flex4 container
1 Answer(s)      4 years ago
Posted in : Flex


Hi...

I have a custom component that is larger than a certain container, and I need it to be centered in that container. Best using only MXML, styles and properties

This does not work as expected:

<s:BorderContainer x="300" y="300" width="200" height="200">
   <s:Button label="Not centered" horizontalCenter="0" verticalCenter="0" width="300" height="250"/>
</s:BorderContainer>

Thanks


Advertisement
View Answers

October 29, 2010 at 4:42 PM


Ans:

I noticed that using the whole Application as the Container in the example, the Component would center itself even when larger than the Stage. I cannot use another Application, so I used the next inherited class: SkinnableContainer, instead of BorderContainer, in the above example. It works properly.

Thanks



Related Tutorials/Questions & Answers:
Flex4 container
Flex4 container   Hi... I have a custom component that is larger than a certain container, and I need it to be centered in that container. Best... the whole Application as the Container in the example, the Component would center
WindowedApplication Container in Flex4
WindowedApplication container in Flex4: The WindowedApplication container is an application container which is use to create Flex applications for AIR. The WindowedApplication container is used in desktop and window based applications
Advertisements
Spark Application Container in Flex4
Spark Application Container in flex4: Spark container is define in the spark.components package. The application container is the first container of the spark components. Basically it is layout container. you can start adding
Flex4
Flex4  Hi...... please tell me about that..... What?s new in flex4? Thanks   Ans: The Flex SDK has been focused around three primary... in flex4. Integration with Adobe Catalyst Spark Component Architecture MXML
Flex4
Flex4  Hi.. What is the difference between Flex3 and Flex4? Please tell me about that...... Thanks   Difference between Flex3 and Flex4: Adobe Flex 4 including a new skinning and component architecture, a new
Form Layout Container in Flex4
Form Layout Container in Flex4: The Form Layout container is a MX container. There is no Spark equivalent. Flex uses the Form Layout container for making... can see how we can use a Form Layout Container control in Flex4. Output
Tile Layout Container in Flex4
Tile Layout Container in Flex4: The Tile Layout Container is a MX container... you can see how we can use a Tile Layout Container control in Flex4. Output... use 4 components in a Tile container Flex arrange two components wide and two
Window Container in Flex4
Window Container in Flex4 : This container are use window applications in flex 4. Spark Window container is provide a way if user want to create own window... can see how to create Window container in Flex4. The MXML tag for creating
VBox Container in Flex4
VBox container in Flex4: The VBox container is a MX component. There is no Spark Component. The VBox container is used for vertical layout in which... instead of VBox Container. The tag of VBox Container is <mx:VBox>
HBox Container in Flex4
HBox container in Flex4: The HBox container is a MX component. There is no Spark Component. The HBox container is used for horizontal layout in which... Horizontal layout instead of HBox Container. The tag of HBox Container is <mx
HDivideBox Container in Flex4
HDividedBox container in Flex4: The HDividedBox container is a MX component. There is no Spark Component. The HDividedBox container is used for horizontal.... It is similar to a HBox container, except the HDividedBox container contains
VDividedBox Container in Flex4
VDividedBox container in Flex4: The VDividedBox container is a MX component. There is no Spark Component. The VDividedBox container is used for vertical.... It is similar to a VBox container, except the VDividedBox container contains a divider
Grid Layout Container in Flex4
Grid Layout Container in Flex4: The Grid Layout Container is a MX container... Container control in Flex4. Output: Running Application... in a row and each cell can have a Grid container. The default Horizontal and Vertical
DividedBox Container in Flex4
DividedBox container in Flex4: The DividedBox container is a MX component. There is no Spark Component. The DividedBox container is used for both... for horizontal and vertical layout. It is similar to a Box container, except
Panel Container in Flex4
Panel container in Flex4: A Panel container can contain many components. ... children components. It also contains a sub panel container according to requirement. The tag of Panel container is <s:Panel>. The default size of panel
Box Container in Flex4
Box container in Flex4: The Box container is a MX component. There is no Spark Component. The Box container is used for both horizontal and vertical... and vertical layout. The tag of Box Container is <mx:Box>. In this example you can
Canvas Layout Container in Flex4
Canvas Layout Container in Flex4: The Canvas layout Container is used... or controls. The Canvas layout Container is a MX component. There is no spark component... of Canvas Layout Container is <mx:Canvas>. In this example the colored area
Spark DataGroup Container in Flex4
Spark DataGroup Container in Flex 4: DataGroup container is a Spark container... as children. These container uses item renderer that provide visual representation of the data item in the container. Item renderer converts data item in the format
Group Container in Flex4
Group container in Flex4: The Spark Group containers take any components...) you can use Group container. The Group container is designed for simplicity... of the Group container. You can use Horizontal and Vertical layout with Group
Accordion Navigator Container in Flex4
Accordion Navigator Container in Flex4: The Accordion Navigator container... container in Flex4. Example: <?xml version="1.0" encoding...;pnl" title="Accordion Navigator Container Example" width="
SkinnableDataContainer in Flex4
SkinnableDataContainer in Flex4: SkinnableDataConatiner Container is a Flex4 container hold and lays out data items and supports virtualization.  SkinnableDataContainer Container contains only these component which implement 
NavigatorcontentContainer in Flex4
NavigatorContent Container in Flex4: The NavigatorContent Container is a Flex4 container that's used to switch between multiple children which are other... have create a NavigatorContent container. A NavigatorContent must
servlet container
servlet container  What is servlet container
Java container
Java container  What is a Container in a GUI
java container
java container  Why the container does not support multiple layout managers
Flex4 FXG and Image
Flex4 FXG and Image  Hi.... Flex4 skin in FXG or image which is more efficient? please tell me about that... Thanks   Ans: Is your app going to be scaled? If not use bitmaps or vectors cached as bitmaps. if you
servlet container
servlet container  When a client request is sent to the servlet container, how does the container choose which servlet to invoke?   The servlet container determines which servlet to invoke based on the configuration
Accordian container
Accordian container  Hi.. How to customize accordian and panel look? Thanks   Ans: You can use the stylesheet or creating custom skin. Custom skin is the only way to make a component or container customize. Thanks
Spark Container in Flex 4
Spark Container in flex4: The container provides content area that contains its child component. The size of the content area is set by the container. If you want to create a application then you require at least one container
What is Spring IOC Container ?
What is Spring IOC Container ?  Hi, What is Spring IOC Container ? Thanks
Advertisements
 

 

 

DMCA.com