It sort of does not make sense to have something be width="100%", then
set horizontalCenter.  The width setting will make the component be the
same width as the container, so it will automatically be "centered", but
again, that does not really make sense.

 

Marco is probably right. In this case, since your button bar fill the
whole horizontal space, what you really want is to center the buttons
within it, by setting horizontalalign="center"

 

Tracy Spratt 
Lariat Services 

Flex development bandwidth available 

________________________________

From: [email protected] [mailto:[email protected]] On
Behalf Of Marco Catunda
Sent: Monday, February 02, 2009 5:50 AM
To: [email protected]
Subject: Re: [flexcoders] Buttonbar not centering at startup

 

Ben,

horizontalCenter="0"?? It should be horizontalAlign="center", shouldn't
it?

--
Marco Catunda

On Sun, Feb 1, 2009 at 10:29 PM, Ben Cessa <[email protected]
<mailto:bcessa%40gmail.com> > wrote:
> Hi again, right now I'm just playing a little with AIR and PV3D
writing a
> little useless app as an exercise. I'm having an odd problem with
ButtonBar,
> the thing don't get the horizontal center when the apps starts, is
aligned
> to the left, however, as soon as I start resizing the main window it
works
> very nice. Any ideas about what could this be?
> The actual portion of code I'm using is this:
> <mx:ButtonBar id="figSelector"
> width="100%" height="100%"
> horizontalGap="20" horizontalCenter="0"
> verticalAlign="middle"
> buttonWidth="50" buttonHeight="50">
> And here's a little screencap of what the component shows at startup
>
> By the way, I'm also having problems removing that ugly background
from the
> buttons, can't figure out the skin needed, I was thinking in use a
100%
> transparent PNG as background image but I'm not sure, just in case
someone
> know how to remove that too :P
> Well, thanx a lot for your attention and I hope someone can give me
hand
> with this

 

Reply via email to