CheckBoxParam.cs 747 B

12345678910111213141516171819202122232425262728293031323334
  1. using ComPDFKit.PDFAnnotation;
  2. using ComPDFKit.PDFAnnotation.Form;
  3. namespace ComPDFKit.Tool
  4. {
  5. public class CheckBoxParam:WidgetParm
  6. {
  7. public CheckBoxParam ()
  8. {
  9. CurrentType = C_ANNOTATION_TYPE.C_ANNOTATION_WIDGET;
  10. WidgetType = C_WIDGET_TYPE.WIDGET_CHECKBOX;
  11. }
  12. public C_CHECK_STYLE CheckStyle { get; set; }
  13. public bool IsChecked { get; set; }
  14. public override bool CopyTo(AnnotParam transfer)
  15. {
  16. CheckBoxParam checkboxTransfer = transfer as CheckBoxParam;
  17. if (checkboxTransfer == null)
  18. {
  19. return false;
  20. }
  21. if (!base.CopyTo(checkboxTransfer))
  22. {
  23. return false;
  24. }
  25. checkboxTransfer.CheckStyle = CheckStyle;
  26. checkboxTransfer.IsChecked = IsChecked;
  27. return true;
  28. }
  29. }
  30. }