segment.tintColor = [UIColor clearColor];//去掉颜色,现在整个segment都看不见NSDictionary* selectedTextAttributes = @{NSFontAttributeName:[UIFont boldSystemFontOfSize:16],NSForegroundColorAttributeName: [UIColor whiteColor]};[segment setTitleTextAttributes:selectedTextAttributes forState:UIControlStateSelected];//设置文字属性NSDictionary* unselectedTextAttributes = @{NSFontAttributeName:[UIFont boldSystemFontOfSize:16],NSForegroundColorAttributeName: [UIColor lightTextColor]};[segment setTitleTextAttributes:unselectedTextAttributes forState:UIControlStateNormal];
UISegmentedControl去掉边框-姬云鹏
最新推荐文章于 2018-04-10 15:34:54 发布