ios 各种提示小红圈属性设置
来源:互联网 发布:淘宝试用中心入口 编辑:程序博客网 时间:2024/05/17 06:13
1 UITabBarItem 的小红圈属性是 badgeValue
tabBarItem.badgeValue =@"";//显示红圈
tabBarItem.badgeValue =nil; // 隐藏
tabBarItem.badgeValue =@"1";// 显示个数
2 [UIApplicationsharedApplication].applicationIconBadgeNumber 应用提示 // 默认是0 不显示
3 自定义一个lable添加View上显示
UILabel *lbl_card_count = [[UILabelalloc]initWithFrame:CGRectMake(0,0,16, 16)];
lbl_card_count.font = [UIFontboldSystemFontOfSize:12];
lbl_card_count.textColor = [UIColorwhiteColor];
lbl_card_count.textAlignment = NSTextAlignmentCenter;
lbl_card_count.text = @"1";
lbl_card_count.layer.borderWidth =1;
lbl_card_count.layer.cornerRadius =8;
lbl_card_count.layer.masksToBounds =YES;
lbl_card_count.layer.borderColor =[[UIColorclearColor] CGColor];
lbl_card_count.layer.shadowColor = [[UIColorclearColor] CGColor];
lbl_card_count.layer.shadowOffset =CGSizeMake(0.0, 0.0);
lbl_card_count.layer.shadowOpacity =0.0;
lbl_card_count.backgroundColor = [UIColorredColor];
- ios 各种提示小红圈属性设置
- iOS 各种UI控件属性设置
- iOS 各种提示框
- IOS关于设置字符串在字典中的各种属性!
- actionBar各种属性,设置
- NSAttributedString的各种属性设置
- iOS 文字属性设置
- iOS属性语义设置
- ios 设置属性依赖
- myeclipse提示信息设置(适应各种版本)
- ios跳转设置各种功能
- ios UITextField 设置默认提示
- QFileDialog 的各种属性设置介绍
- UIManager可设置的各种属性
- QFileDialog 的各种属性设置介绍 .
- Matlab 绘制地图各种属性设置
- MPandroidchart 画饼图的各种属性设置
- UIManager可设置的各种属性--记录
- Spring MyBatis
- Android fill_parent、wrap_content和match_parent的区别
- centos 快速安装ffmpeg
- JAVASE课程 第一章 第二讲JAVA数据类型和运算符
- Android:onNewIntent的调用时机
- ios 各种提示小红圈属性设置
- PL/SQL详细介绍
- Hibernate分页查询与泛型
- cocos2d-x 3.0学习一:cocostudio导出UI界面文件的加载及使用的若干问题
- struts2开发注意事项
- 常用的Struts 2.0的标志(Tag)介绍
- Linux core 文件介绍
- Struts 2中的OGNL
- 获取事件目标对象的位置坐标或者鼠标位置坐标(兼容IE和火狐)