Latest 0.0.1
Homepage https://github.com/liuniuliuniu/LLSegmentBar
License MIT
Platforms ios 8.0, requires ARC
Authors

CI Status
Version
License
Platform

LLSegmentBar.gif

Installation

pod "LLSegmentBar"
// 1 设置segmentBar的frame
self.segmentVC.segmentBar.frame = CGRectMake(0, 0, 320, 35);
self.navigationItem.titleView = self.segmentVC.segmentBar;
// 2 添加控制器的V
self.segmentVC.view.frame = self.view.bounds;
[self.view addSubview:self.segmentVC.view];

// 3 添加控制器数组和标题数组
NSArray *items = @[@"item-one", @"item-two", @"item-three"];
UIViewController *vc1 = [UIViewController new];
vc1.view.backgroundColor = [UIColor redColor];
UIViewController *vc2 = [UIViewController new];
vc2.view.backgroundColor = [UIColor greenColor];
UIViewController *vc3 = [UIViewController new];
vc3.view.backgroundColor = [UIColor yellowColor];
[self.segmentVC setUpWithItems:items childVCs:@[vc1,vc2,vc3]];

// 5  配置基本设置  采用链式编程模式进行设置
[self.segmentVC.segmentBar updateWithConfig:^(LLSegmentBarConfig *config) {
config.itemNormalColor([UIColor blackColor]).itemSelectColor([UIColor redColor]).indicatorColor([UIColor greenColor]);
}];

Author

  • 代码使用过程中,发现任何问题,可以随时issue
  • 如果有更多建议或者想法也可以直接联系我 QQ:416997919
  • 本人简书地址 也可随时在简书留言 奥卡姆剃须刀
  • 觉得框架对你有一点点帮助的,就请支持下,点个赞。

License

LLSegmentBar is available under the MIT license. See the LICENSE file for more info.

Latest podspec

{
    "name": "LLSegmentBar",
    "version": "0.0.1",
    "summary": "LLSegmentBar",
    "description": "LLSegmentBar tag Label",
    "homepage": "https://github.com/liuniuliuniu/LLSegmentBar",
    "license": {
        "type": "MIT",
        "file": "LICENSE"
    },
    "authors": {
        "[email protected]": "[email protected]"
    },
    "source": {
        "git": "https://github.com/liuniuliuniu/LLSegmentBar.git",
        "tag": "0.0.1"
    },
    "platforms": {
        "ios": "8.0"
    },
    "source_files": "LLSegmentBar/Classes/**/*",
    "requires_arc": true
}

Pin It on Pinterest

Share This