CreateFromScannerDialogs.xaml 4.8 KB

123456789101112131415161718192021222324252627282930313233343536373839404142434445464748495051525354555657585960616263646566676869707172737475767778798081828384858687888990919293949596979899100101102103104105106107108109110111112113114115116117118119120121122123124125
  1. <UserControl
  2. x:Class="PDF_Master.Views.Dialog.HomePageToolsDialogs.CreateFromScannerDialogs"
  3. xmlns="http://schemas.microsoft.com/winfx/2006/xaml/presentation"
  4. xmlns:x="http://schemas.microsoft.com/winfx/2006/xaml"
  5. xmlns:d="http://schemas.microsoft.com/expression/blend/2008"
  6. xmlns:mc="http://schemas.openxmlformats.org/markup-compatibility/2006"
  7. xmlns:prism="http://prismlibrary.com/"
  8. Width="468"
  9. Height="520"
  10. prism:Dialog.WindowStyle="{StaticResource DialogWindowStyle}"
  11. prism:ViewModelLocator.AutoWireViewModel="True"
  12. Background="White"
  13. mc:Ignorable="d">
  14. <UserControl.Resources>
  15. <Style x:Key="radioButtonStyle" TargetType="{x:Type ListBox}">
  16. <Setter Property="ItemContainerStyle">
  17. <Setter.Value>
  18. <Style TargetType="{x:Type ListBoxItem}">
  19. <Setter Property="Margin" Value="9,8,0,0" />
  20. <Setter Property="Template">
  21. <Setter.Value>
  22. <ControlTemplate TargetType="ListBoxItem">
  23. <RadioButton Focusable="False" IsChecked="{Binding Path=IsSelected, Mode=TwoWay, RelativeSource={RelativeSource TemplatedParent}}">
  24. <ContentPresenter />
  25. </RadioButton>
  26. </ControlTemplate>
  27. </Setter.Value>
  28. </Setter>
  29. </Style>
  30. </Setter.Value>
  31. </Setter>
  32. </Style>
  33. </UserControl.Resources>
  34. <Grid Margin="16,0,16,0" Background="White">
  35. <Grid.RowDefinitions>
  36. <RowDefinition Height="48" />
  37. <RowDefinition />
  38. <RowDefinition Height="64" />
  39. </Grid.RowDefinitions>
  40. <TextBlock
  41. Height="24"
  42. HorizontalAlignment="Left"
  43. VerticalAlignment="Center"
  44. FontFamily="Segoe UI"
  45. FontSize="16"
  46. FontStyle="Normal"
  47. FontWeight="SemiBold"
  48. Text="{Binding TextCreate}" />
  49. <Grid Grid.Row="1" Background="#F7F8FA">
  50. <StackPanel>
  51. <TextBlock
  52. Margin="8,8,0,0"
  53. VerticalAlignment="Center"
  54. FontFamily="Segoe UI"
  55. FontSize="14"
  56. Foreground="#616469"
  57. LineHeight="20"
  58. Text="{Binding TextScans}" />
  59. <ListBox
  60. Name="Listboxscan"
  61. Height="Auto"
  62. Margin="0,10,0,0"
  63. Background="#F7F8FA"
  64. ItemsSource="{Binding Scanitems}"
  65. BorderThickness="0"
  66. SelectedIndex="{Binding SeIndex, Mode=TwoWay}"
  67. Style="{StaticResource radioButtonStyle}" />
  68. </StackPanel>
  69. </Grid>
  70. <Grid Grid.Row="1" Visibility="{Binding Gridvis,Mode=TwoWay}" Background="#FFFFFF" >
  71. <StackPanel VerticalAlignment="Center">
  72. <Image
  73. Width="128"
  74. Height="128"
  75. HorizontalAlignment="Center"
  76. VerticalAlignment="Center"
  77. Source="pack://application:,,,/PDF Master;component/Resources/HomeIcon/noScanner.png"
  78. Visibility="Visible"
  79. />
  80. <TextBlock
  81. VerticalAlignment="Center"
  82. HorizontalAlignment="Center"
  83. FontFamily="Segoe UI"
  84. FontSize="12"
  85. Foreground="#94989C"
  86. LineHeight="20"
  87. Text="{Binding TextNoScan}" />
  88. </StackPanel>
  89. </Grid>
  90. <Grid Grid.Row="2">
  91. <WrapPanel HorizontalAlignment="Right" VerticalAlignment="Center">
  92. <Button
  93. x:Name="But_Scan"
  94. Width="80"
  95. Height="32"
  96. HorizontalAlignment="Center"
  97. VerticalAlignment="Top"
  98. Command="{Binding ToScanCommand}"
  99. Content="{Binding BtnScan}"
  100. IsDefault="True"
  101. IsEnabled="{Binding IsEnable,Mode=TwoWay}"
  102. Style="{StaticResource Btn.cta}" />
  103. <Button
  104. Width="80"
  105. Height="32"
  106. Margin="16,0,0,0"
  107. HorizontalAlignment="Center"
  108. VerticalAlignment="Top"
  109. Content="{Binding BtnCancle}"
  110. IsCancel="True"
  111. Style="{StaticResource btn.sec}" />
  112. </WrapPanel>
  113. </Grid>
  114. </Grid>
  115. </UserControl>