SGTopTitleView
查看次数:4439
下载次数:882
上传时间:2016-08-28
大小:628 B
GitHub下载地址:https://github.com/kingsic/SGTopTitleView.git
* 静止状态下标题按钮的创建
* 滚动状态下标题按钮的创建
* 导航栏上标题按钮的创建
一、SGTopTitleView使用方法一:
1、将项目中SGTopTitleView文件夹拖入工程
2、导入#import "SGTopTitleView.h"头文件
3、通过alloc、initWithFrame或者类方法topTitleViewWithFrame去创建
4、遵循SGTopTitleViewDelegate协议的delegate_SG方法(- (void)SGTopTitleView:(SGTopTitleView *)topTitleView didSelectTitleAtIndex:(NSInteger)index)
二、SGTopTitleView使用方法二:(详细使用方法,请参考Demo)
三、父子控制器的使用
四、navigationItem的titleView的屏幕尺寸处理
五、通过Label创建标题并在其上添加手势(UITapGestureRecognizer)根据标题内容,通过(- (CGRect)boundingRectWithSize:(CGSize)size options:(NSStringDrawingOptions)options attributes:(nullable NSDictionary *)attributes context:(nullable NSStringDrawingContext *)context方法,实现标题宽度自适应);
收藏