1 2 3 4 5 6 7 8 9 10 11 12 13 14 15 16 17 18 19 20 21 22 23 24 25 26 27 28 29 30 31 32 33
| <UserControl x:Class="AxronWebSite.PagesHome.Partenaires"
xmlns="http://schemas.microsoft.com/winfx/2006/xaml/presentation"
xmlns:x="http://schemas.microsoft.com/winfx/2006/xaml"
xmlns:p="clr-namespace:AxronWebSite.PagesHome">
<UserControl.Resources>
<p:ListPartner x:Name="lstPartner">
<p:Partner Uri="PartnerThermic" ImageName="themicpetit_180.jpg" />
<p:Partner Uri="PartnerBorel" ImageName="new-borel.jpg" />
<p:Partner Uri="PartnerStrong" ImageName="strong_180.jpg" />
</p:ListPartner>
</UserControl.Resources>
<Grid x:Name="LayoutRoot" >
<ListBox x:Name="lb1" Margin="5,5,5,5" Width="Auto"
ItemsSource="{Binding Path=MyList, Source={StaticResource lstPartner}}" Background="{x:Null}" BorderBrush="{x:Null}" Foreground="#FF000000" >
<ListBox.ItemTemplate>
<DataTemplate>
<StackPanel Orientation="Horizontal" >
<Image Source="{Binding Path=ImageName}" MaxWidth="100" />
<TextBlock TextWrapping="Wrap" Text="{Binding Path=Description}" Margin="5,5,5,5" />
</StackPanel>
<!--<Grid>
<Grid.ColumnDefinitions>
<ColumnDefinition Width="0.20*" MaxWidth="150"/>
<ColumnDefinition Width="0.80*"/>
</Grid.ColumnDefinitions>
<Image Grid.Column="0" Source="{Binding Path=ImageName}" MaxWidth="100" />
<TextBlock Grid.Column="1" TextWrapping="Wrap" Text="{Binding Path=Description}" Margin="5,5,5,5" />
</Grid>-->
</DataTemplate>
</ListBox.ItemTemplate>
</ListBox>
</Grid>
</UserControl> |
Partager