TextEditToolContent.xaml 4.3 KB

1234567891011121314151617181920212223242526272829303132333435363738394041424344454647484950515253545556575859606162636465666768697071727374
  1. <UserControl
  2. x:Class="PDF_Master.Views.Tools.TextEditToolContent"
  3. xmlns="http://schemas.microsoft.com/winfx/2006/xaml/presentation"
  4. xmlns:x="http://schemas.microsoft.com/winfx/2006/xaml"
  5. xmlns:customControl="clr-namespace:PDF_Master.CustomControl"
  6. xmlns:d="http://schemas.microsoft.com/expression/blend/2008"
  7. xmlns:local="clr-namespace:PDF_Master.Views.Tools"
  8. xmlns:mc="http://schemas.openxmlformats.org/markup-compatibility/2006"
  9. xmlns:prism="http://prismlibrary.com/"
  10. xmlns:viewmodels="clr-namespace:PDF_Master.ViewModels.Tools"
  11. Height="40"
  12. d:DataContext="{d:DesignInstance Type=viewmodels:TextEditToolContentViewModel}"
  13. d:DesignHeight="450"
  14. d:DesignWidth="800"
  15. prism:ViewModelLocator.AutoWireViewModel="True"
  16. mc:Ignorable="d">
  17. <Grid>
  18. <Border BorderBrush="{StaticResource color.sys.layout.divider}" BorderThickness="0,1,0,1">
  19. <StackPanel HorizontalAlignment="Center" Orientation="Horizontal">
  20. <customControl:CustomIconToggleBtn
  21. x:Name="BtnAddText"
  22. Height="28"
  23. Padding="4,0"
  24. Command="{Binding AddContentCommand}"
  25. CommandParameter="{Binding ElementName=BtnAddText}"
  26. ContentStringFormat="156"
  27. Foreground="Black"
  28. IsChecked="{Binding IsTextEdit}"
  29. Style="{StaticResource SubToolbarTgb}"
  30. Tag="Text">
  31. <StackPanel Orientation="Horizontal">
  32. <Path
  33. Width="20"
  34. Height="20"
  35. Data="M2 3C2 2.44772 2.44772 2 3 2H9H11H17C17.5523 2 18 2.44772 18 3V7H16V4H11L11 16H13V18H11H9H7V16H9L9 4H4V7H2V3Z"
  36. Fill="{StaticResource color.icon.base.brand}" />
  37. <TextBlock
  38. Margin="4,0,0,0"
  39. VerticalAlignment="Center"
  40. FontFamily="Segoe UI"
  41. FontSize="12"
  42. Foreground="{StaticResource color.icon.base.brand}"
  43. Text="Add Text" />
  44. </StackPanel>
  45. </customControl:CustomIconToggleBtn>
  46. <customControl:CustomIconToggleBtn
  47. x:Name="BtnAddImage"
  48. Height="28"
  49. Margin="8,0"
  50. Padding="4,0"
  51. Command="{Binding AddContentCommand}"
  52. CommandParameter="{Binding ElementName=BtnAddImage}"
  53. ContentStringFormat="156"
  54. Foreground="{StaticResource color.icon.base.brand}"
  55. IsChecked="{Binding IsImgEdit}"
  56. Style="{StaticResource SubToolbarTgb}"
  57. Tag="Image">
  58. <StackPanel Orientation="Horizontal">
  59. <Grid Width="20" Height="20">
  60. <Path Data="M17.5 4H2.5C2.22386 4 2 4.22386 2 4.5V15.5C2 15.7761 2.22386 16 2.5 16H17.5C17.7761 16 18 15.7761 18 15.5V4.5C18 4.22386 17.7761 4 17.5 4ZM2.5 2C1.11929 2 0 3.11929 0 4.5V15.5C0 16.8807 1.11929 18 2.5 18H17.5C18.8807 18 20 16.8807 20 15.5V4.5C20 3.11929 18.8807 2 17.5 2H2.5Z" Fill="{StaticResource color.icon.base.brand}" />
  61. <Path Data="M14.5 9C15.3284 9 16 8.32843 16 7.5C16 6.67157 15.3284 6 14.5 6C13.6716 6 13 6.67157 13 7.5C13 8.32843 13.6716 9 14.5 9ZM7.33654 8.21171L4.09402 13.1639C3.86307 13.5131 4.08478 14.0104 4.46354 13.9998H15.5399C15.9186 13.9998 16.1403 13.4919 15.9001 13.1427L13.5999 9.75662C13.4151 9.49208 13.0641 9.4815 12.8793 9.74604L10.9393 11.4232L8.07558 8.20113C7.88158 7.92601 7.5213 7.93659 7.33654 8.21171Z" Fill="{StaticResource color.icon.base.neutral.norm.lv2}" />
  62. </Grid>
  63. <TextBlock
  64. Margin="4,0,0,0"
  65. VerticalAlignment="Center"
  66. FontFamily="Segoe UI"
  67. FontSize="12"
  68. Text="Add Image" />
  69. </StackPanel>
  70. </customControl:CustomIconToggleBtn>
  71. </StackPanel>
  72. </Border>
  73. </Grid>
  74. </UserControl>