APPSettingProperties.cs 5.8 KB

123456789101112131415161718192021222324252627282930313233343536373839404142434445464748495051525354555657585960616263646566676869707172737475767778798081828384858687888990919293949596979899100101102103104105106107108109110111112113114115116117118119120121122123124125126127128129130131132133134135136137138139140141142143144145146147148149150151152153154155156157158159160161162163164165166167168169170171172173174175176177178179180181182183184185186187188189190191192193194195196197198199200201202203204205206207208
  1. using System;
  2. using System.Collections.Generic;
  3. using System.Linq;
  4. using System.Text;
  5. using System.Threading.Tasks;
  6. using System.Windows;
  7. using System.Drawing;
  8. using ComPDFKitViewer.PdfViewer;
  9. using ComPDFKitViewer;
  10. namespace PDFSettings
  11. {
  12. public class APPSettingProperties
  13. {
  14. public DescriptionPropertyClass Description = new DescriptionPropertyClass();
  15. public InitialVIewPropertyClass InitialVIew = new InitialVIewPropertyClass();
  16. public AnnotatePropertyClass Annotate = new AnnotatePropertyClass();
  17. //自定义主题色保存
  18. public List<System.Windows.Media.Color> CustomColorList = new List<System.Windows.Media.Color>();
  19. //动态图章日期格式 下拉列表索引
  20. public int DateMode = 0;
  21. public string CustomAuthor = "PDF Reader Pro";
  22. //ToolTabControl 选中项
  23. public int TabSelectedIndex = 0;
  24. //是否固定
  25. public bool IsFixed = true;
  26. //需要重启后删除的临时文件
  27. public List<string> NeedToDeletePath = new List<string>();
  28. //文件源路径集合
  29. public List<string> CustomStampFilePathLists = new List<string>();
  30. public List<string> SignatureFilePathLists = new List<string>();
  31. public string culture = System.Globalization.CultureInfo.CurrentUICulture.ToString();
  32. /// <summary>
  33. /// 0 - listView 1-GridView
  34. /// </summary>
  35. public int RecentFileListMode = 0;
  36. /// <summary>
  37. /// 切换语言时 重启时需要打开的文档列表
  38. /// </summary>
  39. public List<string> NeedToOpenFileList = new List<string>();
  40. }
  41. public class DescriptionPropertyClass
  42. {
  43. /// <summary>
  44. /// app启动时打开上次未关闭的文档
  45. /// </summary>
  46. public bool OpenUnClosedFileWhenOpen = false;
  47. /// <summary>
  48. /// 文档打开时恢复上次视图设置
  49. /// </summary>
  50. public bool RecoveryViewWhenOpen = false;
  51. /// <summary>
  52. /// 最近打开中文档最多显示数量
  53. /// </summary>
  54. public int FileCountInRecentFiles = 10;
  55. /// <summary>
  56. /// 是否自动保存
  57. /// </summary>
  58. public bool AutoSave = true;
  59. /// <summary>
  60. /// 自动保存频次
  61. /// </summary>
  62. public int AutoSaveInterval = 5;
  63. /// <summary>
  64. /// 关闭文档 弹出保存提示
  65. /// </summary>
  66. public bool ShowSaveWhenClose = true;
  67. /// <summary>
  68. /// 关闭文档 无提示 直接保存
  69. /// </summary>
  70. public bool NotShowSaveWhenClose = false;
  71. /// <summary>
  72. ///打开图片文档 自动扫描并识别文本
  73. /// </summary>
  74. public bool AutoScanImageFile = true;
  75. /// <summary>
  76. /// 提示扫描并识别文本
  77. /// </summary>
  78. public bool TipScanImageFile = false;
  79. /// <summary>
  80. /// 用户名
  81. /// </summary>
  82. public string Author = Environment.UserName;
  83. }
  84. public class InitialVIewPropertyClass
  85. {
  86. /// <summary>
  87. /// 页面显示模式
  88. /// </summary>
  89. public ViewMode PageView = ViewMode.SingleContinuous;
  90. /// <summary>
  91. /// 缩放比例
  92. /// </summary>
  93. public FitMode ZoomMode = FitMode.FitWidth;
  94. /// <summary>
  95. /// 默认收起BOTA
  96. /// </summary>
  97. public bool NotShowBOTA = true;
  98. /// <summary>
  99. /// 记住上一次BOTA是否展开
  100. /// </summary>
  101. public bool RememberBOTA = false;
  102. /// <summary>
  103. /// 记录本次BOTA的展开状态
  104. /// </summary>
  105. public bool IsBOTAOpen = false;
  106. /// <summary>
  107. /// 有大纲时默认显示大纲列表
  108. /// </summary>
  109. public bool ShowOutLine = true;
  110. /// <summary>
  111. ///属性面板 自动展开
  112. /// </summary>
  113. public bool AutoExpandProperty = true;
  114. /// <summary>
  115. /// 属性面板 手动展开
  116. /// </summary>
  117. public bool ClickOpenProperty = true;
  118. /// <summary>
  119. /// 阅读页背景色
  120. /// </summary>
  121. public Color BackGround = Color.White;
  122. /// <summary>
  123. /// 全屏背景色
  124. /// </summary>
  125. public Color BackGroundInFulWindow = Color.White;
  126. /// <summary>
  127. ///高亮表单
  128. /// </summary>
  129. public bool HignlightForm = true;
  130. /// <summary>
  131. /// 域高亮色
  132. /// </summary>
  133. public Color FormHighLightColor = Color.White;
  134. /// <summary>
  135. /// 必填栏高亮色
  136. /// </summary>
  137. public Color RequiredFieldsColor = Color.White;
  138. /// <summary>
  139. /// 高亮链接
  140. /// </summary>
  141. public bool HighlightLink = true;
  142. }
  143. public class AnnotatePropertyClass
  144. {
  145. //各类型注释默认颜色
  146. public Color HighLightColor = Color.White;
  147. public Color UnderLineColor = Color.White;
  148. public Color StrikethroughColor = Color.White;
  149. public Color FreeHandColor = Color.White;
  150. public Color TextAnnoteColor = Color.White;
  151. public Color NoteAnnoteColor = Color.White;
  152. public Color RectangleBorderColor = Color.White;
  153. public Color RectangleFillColor = Color.White;
  154. public Color CircleBorderColor = Color.White;
  155. public Color CircleFillColor = Color.White;
  156. public Color LineColor = Color.White;
  157. /// <summary>
  158. ///文本对齐方式
  159. /// </summary>
  160. public TextAlignment TextAlign = TextAlignment.Left;
  161. /// <summary>
  162. /// 文本注释 字体
  163. /// </summary>
  164. public string TextFontFamaily = "Helvetica";
  165. /// <summary>
  166. /// 标签Note 字体
  167. /// </summary>
  168. public string AnchoredFamaily = "Helvetica";
  169. }
  170. }