LinkAnnotProperty.xaml 14 KB

123456789101112131415161718192021222324252627282930313233343536373839404142434445464748495051525354555657585960616263646566676869707172737475767778798081828384858687888990919293949596979899100101102103104105106107108109110111112113114115116117118119120121122123124125126127128129130131132133134135136137138139140141142143144145146147148149150151152153154155156157158159160161162163164165166167168169170171172
  1. <UserControl x:Class="PDF_Office.Views.PropertyPanel.AnnotPanel.LinkAnnotProperty"
  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. xmlns:local="clr-namespace:PDF_Office.Views.PropertyPanel.AnnotPanel"
  7. xmlns:Convert="clr-namespace:PDF_Office.DataConvert"
  8. mc:Ignorable="d"
  9. d:DesignHeight="450" d:DesignWidth="800">
  10. <UserControl.Resources>
  11. <ResourceDictionary>
  12. <!--<ResourceDictionary.MergedDictionaries>
  13. <ResourceDictionary Source="../Resources/Style/ToggleButtonStyle.xaml"/>
  14. </ResourceDictionary.MergedDictionaries>-->
  15. <Convert:StringToVisibleConvert x:Key="StringToVisibleConvert"/>
  16. <Convert:StringToUnVisibleConvert x:Key="StringToUnVisibleConvert"></Convert:StringToUnVisibleConvert>
  17. </ResourceDictionary>
  18. </UserControl.Resources>
  19. <Grid>
  20. <StackPanel>
  21. <TextBlock Name="AnnotTypeTitle" FontFamily="Segoe UI" FontWeight="Bold" FontSize="18" LineHeight="24" HorizontalAlignment="Center" Margin="0,12,0,12">Hyperlink</TextBlock>
  22. <StackPanel Orientation="Horizontal" Margin="12,0,0,0">
  23. <ToggleButton Name="LinkPageBtn" Width="72" Height="80" VerticalContentAlignment="Center" Tag="Page" Background="Transparent" BorderThickness="0" IsChecked="True">
  24. <StackPanel VerticalAlignment="Center">
  25. <Path Margin="8 8 8 8" Fill="#000000" HorizontalAlignment="Center">
  26. <Path.Data>
  27. M10.7071068,0 L15,4.29289322 L15,16 L1,16 L1,0 L10.7071068,0 Z M10.293,1 L2,1 L2,15 L14,15 L14,4.707 L10.293,1 Z M12,11 L12,12 L4,
  28. 12 L4,11 L12,11 Z M12,9 L12,10 L4,10 L4,9 L12,9 Z M12,7 L12,8 L4,8 L4,7 L12,7 Z M8,5 L8,6 L4,6 L4,5 L8,5 Z
  29. </Path.Data>
  30. </Path>
  31. <TextBlock x:Name="LinkPageText" Width="36" TextWrapping="Wrap" FontSize="12" FontFamily="Segoe UI" LineHeight="16" TextAlignment="Center"/>
  32. </StackPanel>
  33. </ToggleButton>
  34. <ToggleButton Name="LinkWebBtn" Width="72" Height="80" VerticalContentAlignment="Center" Tag="Web" Background="Transparent" BorderThickness="0">
  35. <StackPanel Grid.Column="1" >
  36. <Path Margin="8 8 8 8" Fill="#000000" HorizontalAlignment="Center">
  37. <Path.Data>
  38. M8,0 C12.418278,0 16,3.581722 16,8 C16,12.418278 12.418278,16 8,16 C3.581722,16 0,12.418278 0,8 C0,
  39. 3.581722 3.581722,0 8,0 Z M10.015957,11.4996518 L5.98404305,11.4996518 C6.28228653,12.6171156 6.71860376,
  40. 13.7718221 7.29369179,14.9638748 C7.52703012,14.9881352 7.76212948,15 8,15 C8.23787052,15 8.47296988,14.9881352 8.70473856,14.9649652 L8.5527864,
  41. 15.2763932 C9.20429615,13.9733737 9.69172111,12.7145042 10.015957,11.4996518 Z M4.95140445,11.5005273 L1.93671038,11.5004062 C2.83671487,
  42. 13.0560047 4.31818608,14.2331131 6.08391456,14.7345218 C5.59233631,13.6294852 5.2144726,12.5517364 4.95140445,11.5005273 Z M14.0632896,
  43. 11.5004062 L11.0485955,11.5005273 C10.7855274,12.5517364 10.4076637,13.6294852 9.91549498,14.733701 C11.6818139,14.2331131 13.1632851,
  44. 13.0560047 14.0632896,11.5004062 Z M4.73409625,5.50071837 L1.45951741,5.5002913 C1.16263785,6.27661068 1,7.11931229 1,
  45. 8 C1,8.88106408 1.16277689,9.72410957 1.4598981,10.5007039 L4.73428007,10.5002845 C4.5781846,9.64883923 4.5,8.81539751 4.5,8 C4.5,
  46. 7.18492263 4.57812322,6.35181522 4.73409625,5.50071837 Z M10.2481144,5.50109727 L5.7518856,5.50109727 C5.583851,
  47. 6.3567708 5.5,7.18972192 5.5,8 C5.5,8.81059324 5.58391624,9.64387716 5.75208172,10.4999012 L10.2479183,10.4999012 C10.4160838,9.64387716 10.5,
  48. 8.81059324 10.5,8 C10.5,7.18972192 10.416149,6.3567708 10.2481144,5.50109727 Z M14.5404826,5.5002913 L11.2659038,5.50071837 C11.4218768,6.35181522 11.5,
  49. 7.18492263 11.5,8 C11.5,8.81539751 11.4218154,9.64883923 11.2657199,10.5002845 L14.5401019,10.5007039 C14.8372231,9.72410957 15,8.88106408 15,8 C15,
  50. 7.11931229 14.8373622,6.27661068 14.5404826,5.5002913 Z M6.08450502,1.26629895 L5.91841413,1.31470614 C4.22534161,1.84130637 2.80783045,2.99335133 1.93613744,
  51. 4.50058424 L4.95115335,4.5004762 C5.21423213,3.44894951 5.5921797,2.37086613 6.08450502,1.26629895 Z M8,1 C7.76212948,1 7.52703012,1.01186476 7.29526144,
  52. 1.03503476 L7.4472136,0.723606798 C6.79552511,2.02698377 6.30801146,3.28618649 5.98377622,4.50134805 L10.0162238,4.50134805 C9.73005017,3.42883299 9.31668229,
  53. 2.32200977 8.77550381,1.18078687 L8.70473856,1.03503476 C8.47296988,1.01186476 8.23787052,1 8,1 Z M9.91608544,1.26547815 L10.1069462,1.70819247 C10.50689,
  54. 2.65884847 10.8209632,3.58962551 11.0488466,4.5004762 L14.0638626,4.50058424 C13.1639139,2.94449491 11.6821887,1.76699331 9.91608544,1.26547815 Z
  55. </Path.Data>
  56. </Path>
  57. <TextBlock x:Name="URLText" Width="52" TextWrapping="Wrap" FontSize="12" FontFamily="Segoe UI" LineHeight="16" TextAlignment="Center">Open web Page</TextBlock>
  58. </StackPanel>
  59. </ToggleButton>
  60. <ToggleButton Name="LinkMailBtn" Width="72" Height="80" VerticalContentAlignment="Center" Tag="Mail" Background="Transparent" BorderThickness="0">
  61. <StackPanel Grid.Column="2">
  62. <Path Margin="8 8 8 8" Fill="#000000" HorizontalAlignment="Center">
  63. <Path.Data>
  64. M16,2 L16,14 L0,14 L0,2 L16,2 Z M5.792,7.628 L1.533,13 L14.465,13 L10.203,7.631 L8,9.100925 L5.792,7.628 Z M15,4.434 L11.038,
  65. 7.075 L15,12.067 L15,4.434 Z M1,4.435 L1,12.064 L4.957,7.072 L1,4.435 Z M15,3 L1,3 L1,3.232 L8,7.898 L15,3.231 L15,3 Z
  66. </Path.Data>
  67. </Path>
  68. <TextBlock x:Name="EmailText" TextWrapping="Wrap" FontSize="12" FontFamily="Segoe UI" LineHeight="16" TextAlignment="Center">Email</TextBlock>
  69. </StackPanel>
  70. </ToggleButton>
  71. </StackPanel>
  72. <Line Margin="0,4,0,0" Stroke="#1A000000" StrokeThickness="1" Width="232" HorizontalAlignment="Center" X1="0" X2="232" Y1="0" Y2="0"></Line>
  73. <Grid Height="100">
  74. <StackPanel Name="LinkPagePanel">
  75. <TextBlock x:Name="PageNumberText" Margin="12,12,0,4" FontSize="14" FontFamily="Segoe UI" LineHeight="20" Height="20">Control header</TextBlock>
  76. <StackPanel Orientation="Horizontal">
  77. <Grid>
  78. <TextBox Name="PageNumText" Margin="12,0,0,0" Width="199" Height="32" BorderBrush="#FFE2E3E6" Padding="12,0,0,0" Background="Gray" MaxLength="7"
  79. VerticalContentAlignment="Center" IsEnabled="False"></TextBox>
  80. <Button Tag="PageNumText" HorizontalAlignment="Right" Margin="0,8,8,8" VerticalAlignment="Center" Width="16" Height="16" Background="Transparent"
  81. >
  82. <Button.Content>
  83. <Path Fill="#333333">
  84. <Path.Data>
  85. M9.48528137,2.98528137 L9.48428137,8.48428137 L14.9852814,8.48528137 L14.9852814,9.48528137 L9.48428137,9.48428137 L9.48528137,14.9852814 L8.48528137,
  86. 14.9852814 L8.48428137,9.48428137 L2.98528137,9.48528137 L2.98528137,8.48528137 L8.48428137,8.48428137 L8.48528137,2.98528137 L9.48528137,2.98528137 Z
  87. </Path.Data>
  88. <Path.RenderTransform>
  89. <TransformGroup>
  90. <TranslateTransform X="-8"/>
  91. <RotateTransform Angle="45"/>
  92. <TranslateTransform X="13"/>
  93. </TransformGroup>
  94. </Path.RenderTransform>
  95. </Path>
  96. </Button.Content>
  97. </Button>
  98. </Grid>
  99. <TextBlock Name="PageNumBlock" Margin="8,0,0,0" Height="20" FontSize="14" FontFamily="Segoe UI" LineHeight="20" TextAlignment="Center" VerticalAlignment="Center"></TextBlock>
  100. </StackPanel>
  101. <TextBlock Name="ErrorNumTips" Foreground="Red" Margin="12,0,0,0" Visibility="Collapsed">Page number error.</TextBlock>
  102. <TextBlock Name="ErrorRangeTips" Foreground="Red" Margin="12,0,0,0" Visibility="Collapsed">Page number out of range.</TextBlock>
  103. </StackPanel>
  104. <StackPanel Name="LinkWebPanel" Visibility="Collapsed">
  105. <TextBlock Margin="12,12,0,4" FontSize="14" FontFamily="Segoe UI" LineHeight="20" Height="20">URL</TextBlock>
  106. <Grid>
  107. <TextBox Name="PageWebText" Margin="12,0,12,0" Width="232" Height="32" BorderBrush="#FFE2E3E6" HorizontalAlignment="Left" Padding="12,0,25,0" VerticalContentAlignment="Center"
  108. IsEnabled="False" Background="Gray"></TextBox>
  109. <TextBlock x:Name="defaultPageWebText" IsHitTestVisible="False" Margin="25,0,0,0" VerticalAlignment="Center" Foreground="Gray" FontSize="14"
  110. >https://www.pdfreaderpro.com</TextBlock>
  111. <Button Tag="PageWebText" HorizontalAlignment="Right" Margin="0,8,18,8" VerticalAlignment="Center" Width="16" Height="16" Background="Transparent"
  112. >
  113. <Button.Content>
  114. <Path Fill="#333333">
  115. <Path.Data>
  116. M9.48528137,2.98528137 L9.48428137,8.48428137 L14.9852814,8.48528137 L14.9852814,9.48528137 L9.48428137,9.48428137 L9.48528137,14.9852814 L8.48528137,
  117. 14.9852814 L8.48428137,9.48428137 L2.98528137,9.48528137 L2.98528137,8.48528137 L8.48428137,8.48428137 L8.48528137,2.98528137 L9.48528137,2.98528137 Z
  118. </Path.Data>
  119. <Path.RenderTransform>
  120. <TransformGroup>
  121. <TranslateTransform X="-8"/>
  122. <RotateTransform Angle="45"/>
  123. <TranslateTransform X="13"/>
  124. </TransformGroup>
  125. </Path.RenderTransform>
  126. </Path>
  127. </Button.Content>
  128. </Button>
  129. </Grid>
  130. <TextBlock Name="ErrorUrlTips" Foreground="Red" Margin="12,0,0,0" Visibility="Collapsed">Invalid link.</TextBlock>
  131. </StackPanel>
  132. <StackPanel Name="LinkMailPanel" Visibility="Collapsed">
  133. <TextBlock Margin="12,12,0,4" FontSize="14" FontFamily="Segoe UI" LineHeight="20" Height="20">Email</TextBlock>
  134. <Grid>
  135. <TextBox Name="PageMailText" Margin="12,0,12,0" Width="232" Height="32" BorderBrush="#FFE2E3E6" HorizontalAlignment="Left" Background="Gray"
  136. Padding="12,0,0,0" VerticalContentAlignment="Center" IsEnabled="False"></TextBox>
  137. <TextBlock x:Name="defaultPageMailText" IsHitTestVisible="False" Margin="25,0,0,0" VerticalAlignment="Center" Foreground="Gray" FontSize="14"
  138. >support@pdfreaderpro.com</TextBlock>
  139. <Button Tag="PageMailText" HorizontalAlignment="Right" Margin="0,8,18,8" VerticalAlignment="Center" Width="16" Height="16" Background="Transparent"
  140. >
  141. <Button.Content>
  142. <Path Fill="#333333">
  143. <Path.Data>
  144. M9.48528137,2.98528137 L9.48428137,8.48428137 L14.9852814,8.48528137 L14.9852814,9.48528137 L9.48428137,9.48428137 L9.48528137,14.9852814 L8.48528137,
  145. 14.9852814 L8.48428137,9.48428137 L2.98528137,9.48528137 L2.98528137,8.48528137 L8.48428137,8.48428137 L8.48528137,2.98528137 L9.48528137,2.98528137 Z
  146. </Path.Data>
  147. <Path.RenderTransform>
  148. <TransformGroup>
  149. <TranslateTransform X="-8"/>
  150. <RotateTransform Angle="45"/>
  151. <TranslateTransform X="13"/>
  152. </TransformGroup>
  153. </Path.RenderTransform>
  154. </Path>
  155. </Button.Content>
  156. </Button>
  157. </Grid>
  158. <TextBlock Name="ErrorMailTips" Foreground="Red" Margin="12,0,0,0" TextWrapping="Wrap" Visibility="Collapsed">The email is invalid.Please enter a valid email address.</TextBlock>
  159. </StackPanel>
  160. </Grid>
  161. <Button Name="SaveBtn" Width="120" Height="32" Tag="go" FontSize="16" Foreground="White" BorderThickness="0" Background="#273C62" IsEnabled="False">
  162. <!--<TextBlock x:Name="GoText" Foreground="White">Go</TextBlock>-->
  163. </Button>
  164. </StackPanel>
  165. </Grid>
  166. </UserControl>