// // YBPopupMenuPath.h // YBPopupMenu // // Created by lyb on 2017/5/9. // Copyright © 2017年 lyb. All rights reserved. // #import typedef NS_ENUM(NSInteger, YBPopupMenuArrowDirection) { YBPopupMenuArrowDirectionTop = 0, //箭头朝上 YBPopupMenuArrowDirectionBottom, //箭头朝下 YBPopupMenuArrowDirectionLeft, //箭头朝左 YBPopupMenuArrowDirectionRight, //箭头朝右 YBPopupMenuArrowDirectionNone //没有箭头 }; @interface YBPopupMenuPath : NSObject + (CAShapeLayer *)yb_maskLayerWithRect:(CGRect)rect rectCorner:(UIRectCorner)rectCorner cornerRadius:(CGFloat)cornerRadius arrowWidth:(CGFloat)arrowWidth arrowHeight:(CGFloat)arrowHeight arrowPosition:(CGFloat)arrowPosition arrowDirection:(YBPopupMenuArrowDirection)arrowDirection; + (UIBezierPath *)yb_bezierPathWithRect:(CGRect)rect rectCorner:(UIRectCorner)rectCorner cornerRadius:(CGFloat)cornerRadius borderWidth:(CGFloat)borderWidth borderColor:(UIColor *)borderColor backgroundColor:(UIColor *)backgroundColor arrowWidth:(CGFloat)arrowWidth arrowHeight:(CGFloat)arrowHeight arrowPosition:(CGFloat)arrowPosition arrowDirection:(YBPopupMenuArrowDirection)arrowDirection; @end