TextAnnotProperty.xaml 4.7 KB

123456789101112131415161718192021222324252627282930313233343536373839404142434445464748495051525354555657585960616263646566676869707172737475767778
  1. <UserControl x:Class="PDF_Office.Views.PropertyPanel.AnnotPanel.TextAnnotProperty"
  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:CompositeControl="clr-namespace:PDF_Office.CustomControl.CompositeControl"
  8. xmlns:cus="clr-namespace:PDF_Office.CustomControl"
  9. xmlns:i="http://schemas.microsoft.com/xaml/behaviors"
  10. xmlns:prism="http://prismlibrary.com/"
  11. prism:ViewModelLocator.AutoWireViewModel="True"
  12. xmlns:AnnotPanel="clr-namespace:PDF_Office.ViewModels.PropertyPanel.AnnotPanel"
  13. d:DataContext="{d:DesignInstance Type=AnnotPanel:TextAnnotPropertyViewModel}"
  14. xmlns:Convert="clr-namespace:PDF_Office.ViewModels.PropertyPanel.AnnotPanel"
  15. mc:Ignorable="d"
  16. d:DesignHeight="450" d:DesignWidth="800">
  17. <UserControl.Resources>
  18. <ResourceDictionary>
  19. <ResourceDictionary.MergedDictionaries>
  20. <ResourceDictionary Source="../../../Styles/SliderStyle.xaml"></ResourceDictionary>
  21. </ResourceDictionary.MergedDictionaries>
  22. <Convert:AnnotArgsTypeConverter x:Key="AnnotArgsTypeConverter"/>
  23. </ResourceDictionary>
  24. </UserControl.Resources>
  25. <Grid VerticalAlignment="Stretch" Background="#F3F3F3">
  26. <StackPanel Margin="12 0 12 0">
  27. <TextBlock Name="AnnotTypeTitle" FontFamily="Segoe UI" FontWeight="Bold" FontSize="18" LineHeight="24" HorizontalAlignment="Left" Margin="0,16,0,8"
  28. Text="{Binding AnnotTypeTitle}"
  29. ></TextBlock>
  30. <Border Width="228" Height="100" BorderThickness="1" CornerRadius="2" BorderBrush="#DDDDDD" Background="White" Margin="0,8,0,0">
  31. <Grid>
  32. <TextBlock Name="SampleText" Text="Sample" HorizontalAlignment="Center" VerticalAlignment="Center" FontWeight="Bold" FontFamily="Segoe UI" FontSize="18"
  33. Background="{Binding SampleTextBg}"
  34. >
  35. </TextBlock>
  36. <Path Name="UnderlinePath" HorizontalAlignment="Center" StrokeThickness="2" Margin="0,60,0,0" Stroke="{Binding SelectColor}" Visibility="{Binding AnnotType,Converter={StaticResource AnnotArgsTypeConverter},ConverterParameter=AnnotUnderline}">
  37. <Path.Data>
  38. <LineGeometry StartPoint="0,0" EndPoint="62,0"></LineGeometry>
  39. </Path.Data>
  40. </Path>
  41. <Path Name="StrikeoutPath" HorizontalAlignment="Center" StrokeThickness="2" Margin="0,50,0,0" Stroke="{Binding SelectColor}" Visibility="{Binding AnnotType,Converter={StaticResource AnnotArgsTypeConverter},ConverterParameter=AnnotStrikeout}">
  42. <Path.Data>
  43. <LineGeometry StartPoint="0,0" EndPoint="62,0"></LineGeometry>
  44. </Path.Data>
  45. </Path>
  46. <Path Name="SquigglyPath" HorizontalAlignment="Center" StrokeThickness="2" Margin="0,51,0,0" Stroke="{Binding SelectColor}" Visibility="{Binding AnnotType,Converter={StaticResource AnnotArgsTypeConverter},ConverterParameter=AnnotSquiggly}">
  47. </Path>
  48. <Path Name="StickyPath" HorizontalAlignment="Center" VerticalAlignment="Center" Visibility="Collapsed" Fill="#FF8133"
  49. Data="M28.8,4.8 L28.8,24 L16,24 L8,28.8 L8,24 L3.2,24 L3.2,4.8 L28.8,4.8 Z M24,15.2 L8,15.2 L8,17.6 L24,17.6 L24,15.2 Z M17.6,9.6 L8,9.6 L8,12 L17.6,12 L17.6,9.6 Z">
  50. </Path>
  51. </Grid>
  52. </Border>
  53. <Grid Margin="0,18,0,0">
  54. <Grid.RowDefinitions>
  55. <RowDefinition Height="auto"/>
  56. <RowDefinition/>
  57. </Grid.RowDefinitions>
  58. <CompositeControl:SlidContent x:Name="SlidOpacity" HorizontalAlignment="Right">
  59. <!--<i:Interaction.Triggers>
  60. <i:EventTrigger EventName="SelectedValueChanged">
  61. <i:InvokeCommandAction Command="{Binding SelectedValueChangedCommand}"/>
  62. </i:EventTrigger>
  63. </i:Interaction.Triggers>-->
  64. </CompositeControl:SlidContent>
  65. <CompositeControl:ColorContent Grid.Row="1" x:Name="cusColor" />
  66. </Grid>
  67. </StackPanel>
  68. </Grid>
  69. </UserControl>