Yes, I did mean HBox, there is a VBox container around the label,
because once I have the layout figured out, there will be more then just
a label in it.
Here is the code that did not work for me:
<mx:Repeater id="weekRows" dataProvider="{weekStartsAry}" >
<mx:HBox width="100%">
<mx:Repeater id="dayCells" dataProvider="{parentApplication.daysAry}"
startingIndex="{weekRows.currentItem}" count="7">
<mx:VBox width="14.25%" height="200" horizontalScrollPolicy="off">
<mx:Label text="{dayCells.currentItem}" />
</mx:VBox>
</mx:Repeater>
</mx:HBox>
</mx:Repeater>
The last minute before I had to leave and catch my train home, I worked
up this solution:
<mx:Label width="{parentDocument.width/7}" text="{dayCells.currentItem}"
includeInLayout="false" truncateToFit="true" />
This works, but I'm a bit confused about the parentDocument, I expected
that to refer to the VBox around the label, but apparently it is
referring to some higher container|control, can somebody provide any
insight to what element this is referring?
Confidentiality Notice: This message including any
attachments is for the sole use of the intended
recipient(s) and may contain confidential and privileged
information. Any unauthorized review, use, disclosure or
distribution is prohibited. If you are not the
intended recipient, please contact the sender and
delete any copies of this message.
--- Begin Message ---
Did you mean HBox instead of VBox?
>From your description of the layout, it should just work. Can you post
a simple example that doesn't work?
On 4/28/07, Ian Skinner <ian.skinner@ <mailto:ian.skinner%40bloodsource.org>
bloodsource.org> wrote:
> I have a Panel that I have sized to be constrained at 10 pixels top,
> bottom, left and right so that it is flexible and based on the size of
> the browser.
>
> Inside this I have a VBox that I want to be 100% the width of the Panel.
>
> Inside this I have Labels that I want to be 20% of the width of the
> VBox, so that they are 5 of them evenly spaced across.
>
> The text of this label maybe longer then can be displayed within the
> above constraints, that is fine and I want it to be truncated if it can
> not fit into the width equal to ~20% of the browser.
>
> The trouble is that if I code all the above elements with percentages
> the labels will expand and push the parent VBox beyond the width of the
> Panel and I do not want this.
>
> How can I constrain the widths of the Labels (or other
> containers|controls I may want to put at this level) so that it will not
> expand, without losing the flexibility of the overall design?
>
>
>
> --
> Flexcoders Mailing List
> FAQ: http://groups.
> <http://groups.yahoo.com/group/flexcoders/files/flexcodersFAQ.txt>
> yahoo.com/group/flexcoders/files/flexcodersFAQ.txt
> Search Archives: http://www.mail-
> <http://www.mail-archive.com/flexcoders%40yahoogroups.com>
> archive.com/flexcoders%40yahoogroups.com
> Yahoo! Groups Links
>
>
>
>
--- End Message ---