使用POP(面向协议编程)重构指示器视图;
以JXCategoryIndicatorLineView
使用为例子:
- 0.0.2版本用法:
JXCategoryTitleView *categoryView = [[JXCategoryTitleView alloc] initWithFrame:CGRectMake(0, 100, 300, 30)];
categoryView.titles = @[@"主题一", @"主题二"];
categoryView.indicatorLineViewShowEnabled = YES;
categoryView.indicatorLineWidth = 20;
categoryView.indicatorLineViewHeight = 3;
categoryView.indicatorLineViewColor = [UIColor redColor];
[self.view addSubview:categoryView];
- 1.0.0新版本用法:
JXCategoryTitleView *categoryView = [[JXCategoryTitleView alloc] initWithFrame:CGRectMake(0, 100, 300, 30)];
categoryView.titles = @[@"主题一", @"主题二"];
JXCategoryIndicatorLineView *lineView = [[JXCategoryIndicatorLineView alloc] init];
lineView.indicatorLineWidth = 20;
lineView.indicatorLineViewHeight = 3;
lineView.indicatorLineViewColor = [UIColor redColor];
categoryView.indicators = @[lineView];
[self.view addSubview:categoryView];