BezierPathTool.h 1.8 KB

12345678910111213141516171819202122232425262728293031323334353637383940414243444546474849505152535455565758
  1. //
  2. // BezierPathTool.h
  3. // 圆角设置测试
  4. //
  5. // Created by Zuobian on 2019/12/4.
  6. // Copyright © 2019 admin. All rights reserved.
  7. //
  8. #import <Foundation/Foundation.h>
  9. #import <UIKit/UIKit.h>
  10. NS_ASSUME_NONNULL_BEGIN
  11. @interface BezierPathTool : NSObject
  12. @property (nonatomic, assign) float radius;
  13. @property (nonatomic, assign) float radius_TopLeft;
  14. @property (nonatomic, assign) float radius_TopRight;
  15. @property (nonatomic, assign) float radius_BottomLeft;
  16. @property (nonatomic, assign) float radius_BottomRight;
  17. @property (nonatomic, assign) CGPoint hLeftUpPoint;
  18. @property (nonatomic, assign) CGPoint hRightUpPoint;
  19. @property (nonatomic, assign) CGPoint hLeftDownPoint;
  20. @property (nonatomic, assign) CGPoint vLeftUpPoint;
  21. @property (nonatomic, assign) CGPoint vRightDownPoint;
  22. @property (nonatomic, assign) CGPoint centerLeftUp;
  23. @property (nonatomic, assign) CGPoint centerRightUp;
  24. @property (nonatomic, assign) CGPoint centerLeftDown;
  25. @property (nonatomic, assign) CGPoint centerRightDown;
  26. @property (nonatomic, assign) CGSize rectSize;
  27. @property (nonatomic, strong) UIColor *fillColor;
  28. - (instancetype)initWithRadius:(float)radius rectSize:(CGSize)rectSize fillColor:(UIColor *)fillColor;
  29. - (instancetype)initWithRadius_TopLeft:(float)radius_TL
  30. radius_TopRight:(float)radius_TR
  31. radius_BottomLeft:(float)radius_BL
  32. radius_BottomRight:(float)radius_BR
  33. rectSize:(CGSize)rectSize
  34. fillColor:(UIColor *)fillColor;
  35. - (UIBezierPath *)configCornerBezierPath:(UIBezierPath *)bezierPath;
  36. - (void)configAllCornerPoint;
  37. - (void)configTopLeftPoint;
  38. - (void)configTopRightPoint;
  39. - (void)configBottomLeftPoint;
  40. - (void)configBottomRightPoint;
  41. @end
  42. NS_ASSUME_NONNULL_END