<UserControl x:Class="DataGridSamples.Performance"
      xmlns="http://schemas.microsoft.com/winfx/2006/xaml/presentation"
      xmlns:x="http://schemas.microsoft.com/winfx/2006/xaml"
      xmlns:mc="http://schemas.openxmlformats.org/markup-compatibility/2006" 
      xmlns:c1="http://schemas.componentone.com/winfx/2006/xaml"
      xmlns:local="clr-namespace:DataGridSamples"
      xmlns:d="http://schemas.microsoft.com/expression/blend/2008" 
      mc:Ignorable="d" 
      d:DesignHeight="300" d:DesignWidth="300">
    <Grid>
        <Grid Margin="0 0 0 0">
            <Grid.RowDefinitions>
                <RowDefinition Height="Auto" />
                <RowDefinition />
            </Grid.RowDefinitions>
            <Grid Margin="10,0,0,10">
                    <Grid.ColumnDefinitions>
                        <ColumnDefinition />
                        <ColumnDefinition  Width="Auto"/>
                    </Grid.ColumnDefinitions>
                    
                    <ComboBox x:Name="cmbViewPortSize" Margin="10 0 0 0" Height="22" Width="130" Padding="10 0" Grid.Column="1" VerticalContentAlignment="Center"/>
            </Grid>

            <c1:C1DataGrid x:Name="grid"
                Grid.Row="1"
                 RowHeaderWidth="50"
                 ColumnWidth="100"
                 IsReadOnly="true" 
                 CanUserAddRows="False"
                 AutoGenerateColumns="False" Opacity="0.3">
                <c1:C1RowIndexHeaderBehavior.RowIndexHeaderBehavior>
                    <c1:C1RowIndexHeaderBehavior InitialIndex="1"/>
                </c1:C1RowIndexHeaderBehavior.RowIndexHeaderBehavior>
            </c1:C1DataGrid>

            <StackPanel x:Name="info" 
                    Grid.Row="1"
                    Visibility="Collapsed" HorizontalAlignment="Center" VerticalAlignment="Center">
                <c1:C1ProgressBar x:Name="progress" Width="400" Height="20" />
                <StackPanel Orientation="Horizontal" HorizontalAlignment="Center">
                    <TextBlock HorizontalAlignment="Center" Text="Generating" Margin="0,4,4,0"/>
                    <TextBlock x:Name="txt" HorizontalAlignment="Center" Margin="0,4,0,0"/>
                </StackPanel>
            </StackPanel>
            <Button x:Name="btn" 
                Grid.Row="1"
                Width="140" Height="40" HorizontalAlignment="Center" 
                Content="Generate" Click="Button_Click" />
        </Grid>
    </Grid>
</UserControl>
