I've got a ContentPane that contains a XamTilesControl with TileLayoutOrder set to UseExplicitRowColumnOnTile. One of the Tiles contains an ItemsControl that lays out the items horizontally using a WrapPanel. The behavior I'd like is for the Tile to expand horizontally until reaching the XamTilesControl visible dimensions, at which point a new row would start. However, that's not what happens. What I end up with is only 1 row is created for the items and it extends far beyond the visible dimensions of the XamTilesControl. A horizontal scroll bar is created so I can scroll to view all items in the list.
Is there a way to achieve the layout I'm looking for? I'm assuming the problem is that everything is auto-sized, so there is no rule in place to prevent the ItemsControl from expanding as far as it needs to so that all items fit. I've fussed with TileConstraints but I need a more dynamic solution.
Thanks!
Hello,
Is this what you are trying to do, extending the Tile3 to the remaing available space?
If so, then you would need to explicitly set the row/column positions:
<
igTile:Tile Header="Tile1" Column="0" Row="0" RowSpan="1" ColumnSpan="1"
igTile:Tile Header="Tile2" Column="1" Row="0" RowSpan="0" ColumnSpan="1"
igTile:Tile Header="Tile3" Column="0" Row="1" RowSpan="2" ColumnSpan="2"
Sam
Thanks for the reply. However that's not really the issue at hand for me. I know it was probably had to understand what I was asking, I had a lot of trouble putting it into words.
Lets just go with a simple case of 1 tile in the xamTilesControl. If the content within the tile is an ItemsControl that lays out the items horizontally with a wrap panel, I'd like the items to wrap when reaching the boundaries of the xamTilesControl. Basically, if the xamTilesControl is the size of my window, I'd like the tile within not to exceed the width but rather wrap and start a new row, increasing the height of the tile.
Currently when I try this, the tile expands horizontally as far as is required to fit all items. It never wraps down to a second row. I get 1 very wide tile and I need to use a horizontal scrollbar to view all the items.
So what I want is this:
item1 item2 item3
item3 item5 item6
But what I get is this:
item1 item2 item3 item4 item5 item6
Is there a way to force the tile to respect the boundaries of the xamTilesControl?