FansTagFlagView Class Reference
Inherits from | UIView |
---|---|
Declared in | FansTagFlagView.h FansTagFlagView.m |
Other Methods
updateTextLenght
更新输入字符长度
@property (nonatomic, copy) void ( ^ ) ( NSString *text ) updateTextLenght
Declared In
FansTagFlagView.h
scale
icon与托盘的高度比 默认:1.8
@property (nonatomic, strong) NSNumber *scale
Declared In
FansTagFlagView.h
trailingMargin
标签内容尾部距离托盘尾部距离 默认:托盘高度一半 即圆角的半径
@property (nonatomic, strong) NSNumber *trailingMargin
Declared In
FansTagFlagView.h
– initWithFansTag:tagColorStart:tagColorEnd:tagBoderColor:tagTxt:tagLevel:levelFont:tagTxtFont:
标签视图创建方法
- (instancetype)initWithFansTag:(NSString *)tagUrl tagColorStart:(NSString *)tagColorStart tagColorEnd:(NSString *)tagColorEnd tagBoderColor:(NSString *)tagBoderColor tagTxt:(NSString *)tagTxt tagLevel:(NSString *)tagLevel levelFont:(CGFloat)levelFont tagTxtFont:(CGFloat)tagTxtFont
Parameters
tagUrl |
标签图标url |
---|---|
tagColorStart |
渐变色 开始值 |
tagColorEnd |
渐变色 结束值 |
tagBoderColor |
渐变图层边框颜色 |
tagTxt |
标签名 |
tagLevel |
标签等级 |
levelFont |
等级font |
tagTxtFont |
标签font |
Declared In
FansTagFlagView.h
– currentFanTagWithMaxWidth:ignoreCache:tagImageBlock:
绘制粉丝标签
- (void)currentFanTagWithMaxWidth:(CGFloat)maxWidth ignoreCache:(BOOL)ignoreCache tagImageBlock:(void ( ^ ) ( UIImage *))tagImageBlock
Parameters
maxWidth |
标签最大宽度 |
---|---|
ignoreCache |
是否忽略缓存 |
tagImageBlock |
标签回调 |
Declared In
FansTagFlagView.h
– currentVipTagWithFixedWidth:vipImageBlock:
绘制Vip标签
- (void)currentVipTagWithFixedWidth:(CGFloat)fixedWidth vipImageBlock:(void ( ^ ) ( UIImage *))vipImageBlock
Parameters
fixedWidth |
标签固定宽度 |
---|---|
vipImageBlock |
标签回调 |
Declared In
FansTagFlagView.h
+ tagExistCacheWithTagUrl:tagText:tagLevel:
获取粉丝标签缓存image
+ (UIImage *)tagExistCacheWithTagUrl:(NSString *)tagUrl tagText:(NSString *)tagText tagLevel:(NSString *)tagLevel
Parameters
tagUrl |
标签url |
---|---|
tagText |
标签名称 |
tagLevel |
标签等级 |
Declared In
FansTagFlagView.h
+ vipExistCacheWithVipUrl:vipLevel:
获取vip缓存image
+ (UIImage *)vipExistCacheWithVipUrl:(NSString *)vipUrl vipLevel:(long)vipLevel
Parameters
vipUrl |
vipurl |
---|---|
vipLevel |
vip等级 |
Declared In
FansTagFlagView.h
– updateDataFansTag:tagColorStart:tagColorEnd:tagBoderColor:tagTxt:tagLevel:levelFont:tagTxtFont:
更新数据
- (void)updateDataFansTag:(NSString *)tagUrl tagColorStart:(NSString *)tagColorStart tagColorEnd:(NSString *)tagColorEnd tagBoderColor:(NSString *)tagBoderColor tagTxt:(NSString *)tagTxt tagLevel:(NSString *)tagLevel levelFont:(CGFloat)levelFont tagTxtFont:(CGFloat)tagTxtFont
Parameters
tagUrl |
标签图标url |
---|---|
tagColorStart |
渐变色 开始值 |
tagColorEnd |
渐变色 结束值 |
tagBoderColor |
渐变图层边框颜色 |
tagTxt |
标签名 |
tagLevel |
标签等级 |
levelFont |
等级font |
tagTxtFont |
标签font |
Declared In
FansTagFlagView.h
Other Methods
– configTagFrameIgnoreCache:maxWidth:fixedWidth:
配置视图frame
- (void)configTagFrameIgnoreCache:(BOOL)ignoreCache maxWidth:(CGFloat)maxWidth fixedWidth:(BOOL)fixedWidth
Parameters
ignoreCache |
是否忽略缓存 |
---|---|
maxWidth |
最大宽度 |
fixedWidth |
是否固定宽度 |
Declared In
FansTagFlagView.m
Extension Methods
tagColorStart
标签背景渐变开始颜色
@property (nonatomic, copy) NSString *tagColorStart
Declared In
FansTagFlagView.m
tagColorEnd
标签背景渐变结束颜色
@property (nonatomic, copy) NSString *tagColorEnd
Declared In
FansTagFlagView.m
tagBoderColor
标签背景渐变边框颜色
@property (nonatomic, copy) NSString *tagBoderColor
Declared In
FansTagFlagView.m
lastNameText
记录上次名称
@property (nonatomic, copy) NSString *lastNameText
Declared In
FansTagFlagView.m