FontStyleItem.cs 1.9 KB

1234567891011121314151617181920212223242526272829303132333435363738394041424344454647484950515253545556575859606162636465
  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.Windows.Media;
  8. namespace PDF_Office.Model.PropertyPanel.AnnotPanel
  9. {
  10. public class FontStyleItem
  11. {
  12. public string mFontStyleName { get; set; }
  13. public int mFontSize { get; set; }
  14. public FontFamily mFontFamily { get; set; }
  15. public FontStyle mFontStyle { get; set; }
  16. public FontWeight mFontWeight { get; set; }
  17. }
  18. public class LoadFontStyle
  19. {
  20. public static List<FontStyleItem> Load()
  21. {
  22. List<FontStyleItem> fontStyleList = new List<FontStyleItem>();
  23. FontStyleItem custom = new FontStyleItem();
  24. custom.mFontSize = 32;
  25. custom.mFontStyleName = "自定义";
  26. FontStyleItem h1 = new FontStyleItem();
  27. h1.mFontSize = 24;
  28. h1.mFontStyleName = "H1大标题";
  29. FontStyleItem h2 = new FontStyleItem();
  30. h2.mFontSize = 16;
  31. h2.mFontStyleName = "h2(标准)";
  32. FontStyleItem h3 = new FontStyleItem();
  33. h3.mFontSize = 10;
  34. h3.mFontStyleName = "H3小标题";
  35. FontStyleItem b1 = new FontStyleItem();
  36. b1.mFontSize = 8;
  37. b1.mFontStyleName = "B1标题";
  38. FontStyleItem b2 = new FontStyleItem();
  39. b2.mFontSize = 6;
  40. b2.mFontStyleName = "B2标题";
  41. FontStyleItem b3 = new FontStyleItem();
  42. b3.mFontSize = 4;
  43. b3.mFontStyleName = "B3标题";
  44. fontStyleList.Add(custom);
  45. fontStyleList.Add(h1);
  46. fontStyleList.Add(h2);
  47. fontStyleList.Add(h3);
  48. fontStyleList.Add(b1);
  49. fontStyleList.Add(b2);
  50. fontStyleList.Add(b3);
  51. return fontStyleList;
  52. }
  53. }
  54. }