tabbar 设置选中文字的颜色

NSMutableDictionary *textAttrs = [NSMutableDictionary dictionary];

        textAttrs[NSForegroundColorAttributeName] =COLOR(102, 102, 102, 1);

        NSMutableDictionary *selectTextAttrs = [NSMutableDictionary dictionary];

        selectTextAttrs[NSForegroundColorAttributeName] = COLOR(255, 18, 69, 1);;

        [navigation.tabBarItem setTitleTextAttributes:textAttrs forState:UIControlStateNormal];

        [navigation.tabBarItem setTitleTextAttributes:selectTextAttrs forState:UIControlStateSelected];

你可能感兴趣的:(tabbar 设置选中文字的颜色)