CPDFTextMarkupUI.xaml.cs 1015 B

12345678910111213141516171819202122232425262728293031323334353637
  1. using System;
  2. using System.Windows;
  3. using System.Windows.Controls;
  4. namespace ComPDFKit.Controls.Edit
  5. {
  6. public partial class CPDFTextMarkupUI : UserControl
  7. {
  8. public event EventHandler<bool> TextUnderlineChanged;
  9. public event EventHandler<bool> TextStrikethroughChanged;
  10. public CPDFTextMarkupUI()
  11. {
  12. InitializeComponent();
  13. }
  14. private void AddUnderline_Click(object sender, RoutedEventArgs e)
  15. {
  16. TextUnderlineChanged?.Invoke(this, true);
  17. }
  18. private void RemoveUnderline_Click(object sender, RoutedEventArgs e)
  19. {
  20. TextUnderlineChanged?.Invoke(this, false);
  21. }
  22. private void AddStrikethrough_Click(object sender, RoutedEventArgs e)
  23. {
  24. TextStrikethroughChanged?.Invoke(this, true);
  25. }
  26. private void RemoveStrikethrough_Click(object sender, RoutedEventArgs e)
  27. {
  28. TextStrikethroughChanged?.Invoke(this, false);
  29. }
  30. }
  31. }