0 Replies Latest reply on Mar 23, 2007 7:43 AM by muzikathzi

    dynamisch width of tileList Itemrenderer

    muzikathzi Level 1
      Hi

      I´ve got my own ItemRenderer for a list.

      itemrenderer.mxml:
      <mx:Canvas width="100%" height="36" minWidth="200"...>
      <mx:Image y="0" source="icons/button.png" maintainAspectRatio="false" left="0" right="0"/>
      </mx:Canvas>

      When i use this itemRenderer in a List the image is scaled to the current width of the list, as expected.

      But when i use this itemrenderer in a tilelist it doesn´t scale to the largest possible size, instead it always stays at the minWidth (200 px).
      What i want is, that, when the tilelist positions the buttons in (e.g.) two rows that the button is scaled to 50% of the width of the tilelist. And when the tilelist positions the buttons in 3 rows that the width of the button is scaled to 33% of the tileList-width, and so on.

      Does anyone have an idea how this can be done?
      thanks!
      muzi