Skip to content

Instantly share code, notes, and snippets.

@andry1
Created August 18, 2011 23:42
Show Gist options
  • Save andry1/1155562 to your computer and use it in GitHub Desktop.
Save andry1/1155562 to your computer and use it in GitHub Desktop.
<Page
xmlns="http://schemas.microsoft.com/winfx/2006/xaml/presentation"
xmlns:x="http://schemas.microsoft.com/winfx/2006/xaml" xmlns:Monitors="clr-namespace:ParseModXIV.Monitors"
Height="300" Width="300">
<Grid>
<Grid.Resources>
<Monitors:DamageMonitor x:Key="DamageMonitor" />
<DataTemplate x:Key="statRow">
<ListBoxItem>
<Grid>
<Grid.RowDefinitions>
<RowDefinition />
<RowDefinition />
</Grid.RowDefinitions>
<Grid.ColumnDefinitions>
<ColumnDefinition />
<ColumnDefinition />
<ColumnDefinition />
<ColumnDefinition />
<ColumnDefinition />
</Grid.ColumnDefinitions>
<Label Grid.Row="1" Grid.Column="1" Content="Name" />
<Label Grid.Row="1" Grid.Column="2" Content="{Binding Path=Name}"/>
<Label Grid.Row="1" Grid.Column="3" Content="Total" />
<Label Grid.Row="1" Grid.Column="4" Content="{Binding Path=Total}" />
</Grid>
</ListBoxItem>
</DataTemplate>
</Grid.Resources>
<ListBox ItemsSource="{Binding Mode=OneWay, Source={StaticResource DamageMonitor}}"
ItemTemplate="{StaticResource statRow}"/>
</Grid>
</Page>
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment