2
0

XLPageViewControllerConfig.m 2.3 KB

12345678910111213141516171819202122232425262728293031323334353637383940414243444546474849505152535455565758596061626364656667
  1. //
  2. // XLPageViewControllerConfig.m
  3. // XLPageViewControllerExample
  4. //
  5. // Created by MengXianLiang on 2019/5/8.
  6. // Copyright © 2019 xianliang meng. All rights reserved.
  7. // https://github.com/mengxianliang/XLPageViewController
  8. #import "XLPageViewControllerConfig.h"
  9. @implementation XLPageViewControllerConfig
  10. + (XLPageViewControllerConfig *)defaultConfig {
  11. XLPageViewControllerConfig *config = [[XLPageViewControllerConfig alloc] init];
  12. //标题-----------------------------------
  13. //默认未选中标题颜色 灰色
  14. config.titleNormalColor = [UIColor grayColor];
  15. //默认选中标题颜色 黑色
  16. config.titleSelectedColor = [UIColor blackColor];
  17. //默认未选中标题字体 18号系统字体
  18. config.titleNormalFont = [UIFont systemFontOfSize:18];
  19. //默认选中标题字体 18号粗体系统字体
  20. config.titleSelectedFont = [UIFont boldSystemFontOfSize:18];
  21. //默认标题间距 10
  22. config.titleSpace = 10;
  23. //默认过渡动画 打开
  24. config.titleColorTransition = true;
  25. //标题栏------------------------------------
  26. //默认标题栏缩进 左右各缩进10
  27. config.titleViewInset = UIEdgeInsetsMake(0, 10, 0, 10);
  28. //默认标题栏高度 40
  29. config.titleViewHeight = 40.0f;
  30. //默认标题栏背景颜色 透明
  31. config.titleViewBackgroundColor = [UIColor clearColor];
  32. //默认标题栏对齐方式 局左
  33. config.titleViewAlignment = XLPageTitleViewAlignmentLeft;
  34. //阴影--------------------------------------
  35. //默认显示阴影
  36. config.shadowLineHidden = false;
  37. //默认阴影宽度 30
  38. config.shadowLineWidth = 30.0f;
  39. //默认阴影高度 3
  40. config.shadowLineHeight = 3.0f;
  41. //默认阴影颜色 黑色
  42. config.shadowLineColor = [UIColor blackColor];
  43. //默认阴影动画 平移
  44. config.shadowLineAnimationType = XLPageShadowLineAnimationTypePan;
  45. //底部分割线-----------------------------------
  46. //默认显示分割线
  47. config.separatorLineHidden = false;
  48. //默认分割线颜色 浅灰色
  49. config.separatorLineColor = [UIColor lightGrayColor];
  50. //默认分割线高度 0.5
  51. config.separatorLineHeight = 0.5f;
  52. //分段式标题颜色------------------------------
  53. //默认分段式选择器颜色 黑色
  54. config.segmentedTintColor = [UIColor blackColor];
  55. return config;
  56. }
  57. @end