<UserControl
    x:Class="PdfViewerSamples.FindText"
    xmlns="http://schemas.microsoft.com/winfx/2006/xaml/presentation"
    xmlns:x="http://schemas.microsoft.com/winfx/2006/xaml"
    xmlns:local="using:PdfViewerSamples"
    xmlns:d="http://schemas.microsoft.com/expression/blend/2008"
    xmlns:mc="http://schemas.openxmlformats.org/markup-compatibility/2006"
    xmlns:c1="using:C1.Xaml.PdfViewer"
    mc:Ignorable="d">

    <Grid>
        <Grid.RowDefinitions>
            <RowDefinition Height="Auto"/>
            <RowDefinition/>
        </Grid.RowDefinitions>
        <Grid.ColumnDefinitions>
            <ColumnDefinition/>
            <ColumnDefinition Width="Auto"/>
        </Grid.ColumnDefinitions>
        <c1:C1PdfViewer x:Name="pdfViewer" ViewMode="Normal"  Grid.Row="1" Grid.ColumnSpan="2"/>
        <StackPanel Orientation="Horizontal" VerticalAlignment="Center" >
            <TextBlock Text="{Binding ElementName=pdfViewer, Path=PageNumber}" FontSize="20" Foreground="{ThemeResource ApplicationForegroundThemeBrush}" />
            <TextBlock Text=" / " Foreground="{ThemeResource ApplicationForegroundThemeBrush}" FontSize="20"/>
            <TextBlock Text="{Binding ElementName=pdfViewer, Path=PageCount}" FontSize="20" Foreground="{ThemeResource ApplicationForegroundThemeBrush}" />

        </StackPanel>
        <StackPanel Orientation="Horizontal" Grid.Column="0">
            <TextBlock Text="Find Text:" VerticalAlignment="Center" FontSize="16" Margin="80 0" />
            <TextBox x:Name="txtFindText" Width="200" Margin="-70 0" />
            <Button x:Name="btnNext" Content="Find Next" Margin="75 0" Click="btnNext_Click" />
            <Button x:Name="btnPrevious" Content="Find Previous" Margin="-70 0" Click="btnPrevious_Click"/>
        </StackPanel>
        <Button x:Name="btnLoad" Content=" Load Pdf... " HorizontalAlignment="Right" VerticalAlignment="Top" Click="btnLoad_Click" Grid.Column="1" />

    </Grid>
</UserControl>