CPDFViewModeUI.xaml 12 KB

123456789101112131415161718192021222324252627282930313233343536373839404142434445464748495051525354555657585960616263646566676869707172737475767778798081828384858687888990919293949596979899100101102103104105106107108109110111112113114115116117118119120121122123124125126127128129130131132133134135136137138139140141142143144145146147148149150151152153154155156157158159160161162163164165166167168169170171172173174175176177178179180181182183184185186187188189190191192193194195196
  1. <UserControl x:Class="Compdfkit_Tools.PDFControlUI.CPDFViewModeUI"
  2. xmlns="http://schemas.microsoft.com/winfx/2006/xaml/presentation"
  3. xmlns:x="http://schemas.microsoft.com/winfx/2006/xaml"
  4. xmlns:mc="http://schemas.openxmlformats.org/markup-compatibility/2006"
  5. xmlns:d="http://schemas.microsoft.com/expression/blend/2008"
  6. mc:Ignorable="d"
  7. d:DesignHeight="30" d:DesignWidth="350">
  8. <UserControl.Resources>
  9. <ResourceDictionary>
  10. <ResourceDictionary.MergedDictionaries>
  11. <ResourceDictionary Source="../../../Asset/Styles/ButtonStyle.xaml"></ResourceDictionary>
  12. <ResourceDictionary Source="../../../Asset/Styles/ToggleButtonStyle.xaml"></ResourceDictionary>
  13. </ResourceDictionary.MergedDictionaries>
  14. </ResourceDictionary>
  15. </UserControl.Resources>
  16. <Grid>
  17. <StackPanel Orientation="Horizontal" VerticalAlignment="Center" Visibility="Collapsed">
  18. <RadioButton x:Name="ContinuousRadioButton" Tag="Continuous" GroupName="Continuous" IsChecked="True" Click="ContinuousRadioButton_Click">
  19. <TextBlock Text="Continous"></TextBlock>
  20. <RadioButton.ToolTip>
  21. <ToolTip Content="Continuous"></ToolTip>
  22. </RadioButton.ToolTip>
  23. </RadioButton>
  24. <RadioButton x:Name="DiscontinuousRadioButton" Tag="Discontinuous" GroupName="Continuous" Click="ContinuousRadioButton_Click">
  25. <TextBlock Text="Discontinous"></TextBlock>
  26. <RadioButton.ToolTip>
  27. <ToolTip Content="Discontinuous"></ToolTip>
  28. </RadioButton.ToolTip>
  29. </RadioButton>
  30. <Rectangle Margin="10,0,10,0" Width="1" Fill="Black"></Rectangle>
  31. <RadioButton x:Name="SinglePageModeRadioButton" GroupName="ViewMode" Tag="Single" IsChecked="True" Checked="ViewModeRadioButton_Checked">
  32. <TextBlock Text="Single Page"></TextBlock>
  33. <RadioButton.ToolTip>
  34. <ToolTip Content="Single Page"></ToolTip>
  35. </RadioButton.ToolTip>
  36. </RadioButton>
  37. <RadioButton x:Name="DoublePageModeRadioButton" GroupName="ViewMode" Tag="Double" Grid.Row="1" Checked="ViewModeRadioButton_Checked">
  38. <TextBlock Text="Double Page"></TextBlock>
  39. <RadioButton.ToolTip>
  40. <ToolTip Content="Double Page"></ToolTip>
  41. </RadioButton.ToolTip>
  42. </RadioButton>
  43. <RadioButton x:Name="BookModeRadioButton" GroupName="ViewMode" Grid.Row="2" Tag="Book" Checked="ViewModeRadioButton_Checked">
  44. <TextBlock Text="Cover Mode"></TextBlock>
  45. <RadioButton.ToolTip>
  46. <ToolTip Content="Cover Mode"></ToolTip>
  47. </RadioButton.ToolTip>
  48. </RadioButton>
  49. </StackPanel>
  50. <Grid>
  51. <Grid.RowDefinitions>
  52. <RowDefinition Height="auto"></RowDefinition>
  53. <RowDefinition Height="auto"></RowDefinition>
  54. <RowDefinition Height="auto"></RowDefinition>
  55. </Grid.RowDefinitions>
  56. <Border BorderThickness="0,0,0,1" BorderBrush="#EDEDED" Padding="0,0,0,7.5" Name="SplitContainer">
  57. <Grid>
  58. <Grid.RowDefinitions>
  59. <RowDefinition Height="auto"></RowDefinition>
  60. <RowDefinition Height="auto"></RowDefinition>
  61. </Grid.RowDefinitions>
  62. <TextBlock Foreground="#43474D" FontSize="14" LineHeight="16" Margin="0,0,0,18">Split View</TextBlock>
  63. <StackPanel Orientation="Horizontal" Grid.Row="1">
  64. <ToggleButton Name="VerticalBtn" Width="50" Height="36" BorderThickness="0" Style="{StaticResource RoundToggleButtonStyle}"
  65. Background="Transparent" Click="VerticalBtn_Click">
  66. <ToggleButton.Content>
  67. <Path Name="VerticalPath" Fill="#999999" >
  68. <Path.Data>
  69. M20.5 0H0.5V14H20.5V0ZM4.34628 8.75L4.6731 7.73649H6.05023L6.37455 8.75H6.96333L5.66353 5H5.05979L3.76 8.75H4.34628ZM5.90054 7.26871H4.82279L5.33921
  70. 5.65748H5.38162L5.90054 7.26871ZM10 13V1H11V13H10ZM16.0694 7.69231C16.0694 8.34979 15.6078 8.75 14.8394 8.75H13.36V5H14.807C15.4831 5 15.8897
  71. 5.35863 15.8897 5.93295V5.93815C15.8897 6.32796 15.6128 6.67879 15.2585 6.74116V6.78534C15.745 6.83992 16.0694 7.19854 16.0694 7.68711V7.69231ZM13.9188
  72. 6.59563H14.5825C15.0764 6.59563 15.3334 6.40333 15.3334 6.0395V6.0343C15.3334 5.68087 15.0914 5.47557 14.6773 5.47557H13.9188V6.59563ZM14.7272
  73. 8.27443H13.9188V7.04002H14.6947C15.2211 7.04002 15.498 7.24792 15.498 7.65073V7.65593C15.498 8.05873 15.2311 8.27443 14.7272 8.27443Z
  74. </Path.Data>
  75. </Path>
  76. </ToggleButton.Content>
  77. <ToggleButton.ToolTip>
  78. <ToolTip Content="Vertical"></ToolTip>
  79. </ToggleButton.ToolTip>
  80. </ToggleButton>
  81. <ToggleButton Name="HorizonBtn" Width="50" Height="36" BorderThickness="0" Margin="5,0,0,0" Style="{StaticResource RoundToggleButtonStyle}"
  82. Background="Transparent" Click="HorizonBtn_Click">
  83. <ToggleButton.Content>
  84. <Path Name="HorizonPath" Fill="#999999">
  85. <Path.Data>
  86. M0.5 0V16H17.5V0H0.5ZM1 8.5H17V7.5H1V8.5ZM8.45114 5.23649L8.11071 6.25H7.5L8.85395 2.5H9.48285L10.8368 6.25H10.2235L9.88565
  87. 5.23649H8.45114ZM8.60707 4.76871H9.72973L9.18919 3.15748H9.14501L8.60707 4.76871ZM10.8222 12.3923C10.8222 13.0498 10.3415 13.45
  88. 9.54106 13.45H8V9.70001H9.50728C10.2115 9.70001 10.6351 10.0586 10.6351 10.633V10.6382C10.6351 11.028 10.3467 11.3788 9.97765
  89. 11.4412V11.4854C10.4844 11.5399 10.8222 11.8986 10.8222 12.3871V12.3923ZM8.58212 11.2956H9.27339C9.78794 11.2956 10.0556 11.1033
  90. 10.0556 10.7395V10.7343C10.0556 10.3809 9.80353 10.1756 9.37214 10.1756H8.58212V11.2956ZM9.42412 12.9744H8.58212V11.74H9.39033C9.93867
  91. 11.74 10.2271 11.9479 10.2271 12.3507V12.3559C10.2271 12.7587 9.94906 12.9744 9.42412 12.9744Z
  92. </Path.Data>
  93. </Path>
  94. </ToggleButton.Content>
  95. <ToggleButton.ToolTip>
  96. <ToolTip Content="Horizontal"></ToolTip>
  97. </ToggleButton.ToolTip>
  98. </ToggleButton>
  99. </StackPanel>
  100. </Grid>
  101. </Border>
  102. <Border Name="DisplayContainer" Grid.Row="1" Margin="0,30,0,0">
  103. <Grid>
  104. <Grid.RowDefinitions>
  105. <RowDefinition Height="auto"></RowDefinition>
  106. <RowDefinition Height="auto"></RowDefinition>
  107. </Grid.RowDefinitions>
  108. <TextBlock Foreground="#43474D" FontSize="14" LineHeight="16" Margin="0,0,0,18">Display Mode</TextBlock>
  109. <StackPanel Orientation="Horizontal" Grid.Row="1">
  110. <ToggleButton Name="SingleViewBtn" Width="50" Height="36" BorderThickness="0" Style="{StaticResource RoundToggleButtonStyle}" Background="Transparent"
  111. Click="SingleViewBtn_Click">
  112. <ToggleButton.Content>
  113. <Path Name="SingleViewPath" Fill="#999999">
  114. <Path.Data>
  115. M0 0H8L12 4.2V16H0V0Z
  116. </Path.Data>
  117. </Path>
  118. </ToggleButton.Content>
  119. <ToggleButton.ToolTip>
  120. <ToolTip Content="Single Page"></ToolTip>
  121. </ToggleButton.ToolTip>
  122. </ToggleButton>
  123. <ToggleButton Name="DoubleViewBtn" Width="50" Height="36" BorderThickness="0" Margin="5,0,0,0" Style="{StaticResource RoundToggleButtonStyle}" Background="Transparent"
  124. Click="DoubleViewBtn_Click">
  125. <ToggleButton.Content>
  126. <Path Name="DoubleViewPath" Fill="#999999">
  127. <Path.Data>
  128. M11 5H1V19H11V5ZM19 5H13V19H23V9.2L19 5Z
  129. </Path.Data>
  130. </Path>
  131. </ToggleButton.Content>
  132. <ToggleButton.ToolTip>
  133. <ToolTip Content="Double Page"></ToolTip>
  134. </ToggleButton.ToolTip>
  135. </ToggleButton>
  136. <ToggleButton Name="BookViewBtn" Width="50" Height="36" BorderThickness="0" Margin="5,0,0,0" Style="{StaticResource RoundToggleButtonStyle}" Background="Transparent"
  137. Click="BookViewBtn_Click">
  138. <ToggleButton.Content>
  139. <Path Name="BookViewPath" Fill="#999999">
  140. <Path.Data>
  141. <GeometryGroup>
  142. <PathGeometry>M11 15H1V21H11V15ZM23 15H13V21H23V15Z</PathGeometry>
  143. <PathGeometry>M1 3H8L11 6.2V13H1V3Z</PathGeometry>
  144. </GeometryGroup>
  145. </Path.Data>
  146. </Path>
  147. </ToggleButton.Content>
  148. <ToggleButton.ToolTip>
  149. <ToolTip Content="Cover Mode"></ToolTip>
  150. </ToggleButton.ToolTip>
  151. </ToggleButton>
  152. </StackPanel>
  153. </Grid>
  154. </Border>
  155. <Border Grid.Row="2" Margin="0,30,0,0" BorderThickness="0,1,0,1" BorderBrush="#EDEDED" Padding="0,26,0,26">
  156. <Grid>
  157. <Grid.RowDefinitions>
  158. <RowDefinition Height="auto"></RowDefinition>
  159. <RowDefinition Height="auto"></RowDefinition>
  160. </Grid.RowDefinitions>
  161. <Grid>
  162. <Grid.ColumnDefinitions>
  163. <ColumnDefinition Width="*"></ColumnDefinition>
  164. <ColumnDefinition Width="auto"></ColumnDefinition>
  165. </Grid.ColumnDefinitions>
  166. <TextBlock FontSize="14" Foreground="#43474D">Continuous Scroll</TextBlock>
  167. <ToggleButton Name="ContinuePageBtn" Style="{StaticResource ToggleButtonSwitchStyle}" Margin="0,0,33,0" Grid.Column="1" Width="40" BorderThickness="0"
  168. Click="ContinuePageBtn_Click"></ToggleButton>
  169. </Grid>
  170. <Grid Grid.Row="1" x:Name="CropContainer" Visibility="Collapsed">
  171. <Grid.ColumnDefinitions>
  172. <ColumnDefinition Width="*"></ColumnDefinition>
  173. <ColumnDefinition Width="auto"></ColumnDefinition>
  174. </Grid.ColumnDefinitions>
  175. <TextBlock FontSize="14" Foreground="#43474D" Margin="0,24,0,0">Crop</TextBlock>
  176. <ToggleButton Name="CropModeBtn" Style="{StaticResource ToggleButtonSwitchStyle}" Margin="0,24,33,0" Grid.Column="1" Width="40" BorderThickness="0"
  177. Click="CropModeBtn_Click"></ToggleButton>
  178. </Grid>
  179. </Grid>
  180. </Border>
  181. </Grid>
  182. </Grid>
  183. </UserControl>