javaguru_uk escreveu:
> --- In flexcoders@yahoogroups.com, Frederico Garcia <[EMAIL PROTECTED]>
> wrote:
>
>   
>> Have a VBox as the top level container
>>     
> (top=0;bottom=0;left=0;right=0).  
>   
>> Insert  one empty Canvas, then an HBox, then another empty Canvas. The 
>> two Canvas' having width and height of 100% and the HBox the same
>>     
> height 
>   
>> as your "Application Canvas". Now, inside the Hbox have one empty 
>> canvas, your "Application Canvas" and finally another empty canvas. The 
>> empty Canvas' with width=100% and height=100%;
>>
>> The outline tree would look like:
>>
>> Applicaton
>> |-- VBox
>>   |-- Canvas top
>>   |-- HBox
>>   |  |-- Canvas centerLeft
>>   |  |-- Canvas main
>>   |  |-- Canvas centerRight
>>   |-- Canvas bottom
>>
>> I'd only advise you to do this if you want alot of flexibility in your 
>> layout. (I did this for http://www.sizemodels.com)
>>
>> For the most cases it would be enough to have all your content inside a 
>> Canvas, and set it's verticalCenter = 0 and horizontalCenter = 0.
>>
>>     
>
> Hi Garcia,
>
> Thanks a lot for the tip. Muito obrigado mesmo.
>
> I will give it a try. But that is a hell of a lot work for a simple
> solution. :D 
>
> Fidel.
>
>
>
> --
> Flexcoders Mailing List
> FAQ: http://groups.yahoo.com/group/flexcoders/files/flexcodersFAQ.txt
> Search Archives: http://www.mail-archive.com/flexcoders%40yahoogroups.com 
> Yahoo! Groups Links
>
>
>
>
> __________ NOD32 2752 (20071228) Information __________
>
> This message was checked by NOD32 antivirus system.
> http://www.eset.com
>
>
>
>   
Well,this is in fact a lot of work. I used this because I wanted to 
surround my main canvas with different colors (like a tile). If you just 
want your canvas centered you have to insert ALL you content inside a 
SINGLE container (canvas, panel, etc...) a center that container inside 
the Application (HorizontalCenter and VerticalCenter).

I think what you'r trying to do is center the application itself. Not 
possible (or at least inside flex, in order to do that you must change 
the html template and add the swf in the middle cell of a 3x3 table)

Regards,

Frederico Garcia

Reply via email to