dkahgld

UIView+ST.h 1.4KB

12345678910111213141516171819202122232425262728293031323334353637383940414243444546474849505152535455565758596061626364656667686970717273747576777879808182838485
  1. //
  2. // UIView+ST.h
  3. // STPhotoBrowser
  4. //
  5. // Created by https://github.com/STShenZhaoliang/STPhotoBrowser.git on 16/1/15.
  6. // Copyright © 2016年 ST. All rights reserved.
  7. //
  8. #import <UIKit/UIKit.h>
  9. @interface UIView (ST)
  10. /**
  11. * 1.间隔X值
  12. */
  13. @property (nonatomic, assign) CGFloat x;
  14. /**
  15. * 2.间隔Y值
  16. */
  17. @property (nonatomic, assign) CGFloat y;
  18. /**
  19. * 3.宽度
  20. */
  21. @property (nonatomic, assign) CGFloat width;
  22. /**
  23. * 4.高度
  24. */
  25. @property (nonatomic, assign) CGFloat height;
  26. /**
  27. * 5.中心点X值
  28. */
  29. @property (nonatomic, assign) CGFloat centerX;
  30. /**
  31. * 6.中心点Y值
  32. */
  33. @property (nonatomic, assign) CGFloat centerY;
  34. /**
  35. * 7.尺寸大小
  36. */
  37. @property (nonatomic, assign) CGSize size;
  38. /**
  39. * 8.起始点
  40. */
  41. @property (nonatomic, assign) CGPoint origin;
  42. /**
  43. * 9.上 < Shortcut for frame.origin.y
  44. */
  45. @property (nonatomic) CGFloat top;
  46. /**
  47. * 10.下 < Shortcut for frame.origin.y + frame.size.height
  48. */
  49. @property (nonatomic) CGFloat bottom;
  50. /**
  51. * 11.左 < Shortcut for frame.origin.x.
  52. */
  53. @property (nonatomic) CGFloat left;
  54. /**
  55. * 12.右 < Shortcut for frame.origin.x + frame.size.width
  56. */
  57. @property (nonatomic) CGFloat right;
  58. /**
  59. * 13.设置镂空中间的视图
  60. *
  61. * @param centerFrame 中间镂空的框架
  62. */
  63. - (void)setHollowWithCenterFrame:(CGRect)centerFrame;
  64. /**
  65. * 14.获取屏幕图片
  66. * @return <#return value description#>
  67. */
  68. - (UIImage *)imageFromSelfView;
  69. @end