UISegmentedControl 修改字体大小 和 颜色
UISegmentedControl 修改字体大小 和 颜色
大小:
UIFont *font = [UIFont boldSystemFontOfSize:14.0f];
NSDictionary *attributes = [NSDictionary dictionaryWithObject:font
forKey:UITextAttributeFont];
[sortListSeg setTitleTextAttributes:attributes
forState:UIControlStateNormal];
颜色:
UIColor *greenColor = [UIColor greenColor];
NSDictionary *colorAttr = [NSDictionary dictionaryWithObject:greenColor forKey:UITextAttributeTextColor];
[sortListSeg setTitleTextAttributes:colorAttr forState:UIControlStateNormal];
参考:http://stackoverflow.com/questions/2280391/change-font-size-of-uisegmentedcontrol
http://stackoverflow.com/questions/9029760/how-to-change-font-color-of-uisegmentedcontrol
UISegmentedControl 修改字体大小 和 颜色的更多相关文章
- Eclipse 在线汉化的和修改字体大小、颜色的方法
一.在线汉化 先进入 http://www.eclipse.org/babel/downloads.php 找到自己对应版本的网址,然后复制下来. 然后,进入eclipse.点工具栏上的Help - ...
- Xshell如何修改字体大小和颜色
https://jingyan.baidu.com/article/db55b609aac41e4ba30a2f86.html 打开Xshell,点击菜单栏的“文件”->“属性”,或者也可以使用 ...
- iOS 开发富文本之TTTAttributedLabel 在某个特定位置的文字添加跳转,下划线,修改字体大小,颜色
@property(nonatomic , strong) TTTAttributedLabel * ttLabel; @property(nonatomic , strong) NSRange li ...
- 设置UISegmentedControl的字体大小和颜色
NSDictionary *dic = [NSDictionarydictionaryWithObjectsAndKeys:[UIColorblackColor],UITextAttributeTex ...
- iOS开发之--如何修改TabBarItem的title的字体和颜色/BarButtonItem的title的字体大小和颜色/添加背景图片,并添加点击方法
在进行项目的过程中,我们往往会遇到各种各样的自定义颜色和字体,下面提供一种修改系统自带的TabBarItem的字体和颜色的方法,希望能帮到大家: [[UITabBarItem appearance] ...
- 【纯代码】Swift-自定义PickerView单选(可修改分割线颜色、修改字体大小、修改字体颜色。)(可根据需要自己扩展)
typealias PopPickerViewCallBackClosure = (_ resultStr:NSString?) -> () class PopPickerView : UIVi ...
- 修改Xshell字体大小和颜色
博客专区 > XManager的博客 > 博客详情 修改Xshell字体大小和颜色 XManager 发表于7个月前 分享到: 一键分享 QQ空间 微信 腾讯微博 新浪微博 QQ好友 有道 ...
- TextView字体大小及颜色设置
TextView设置文字大小及颜色: 1.1)通过xml配置 <TextView android:layout_width="match_parent" a ...
- 第一章:eclipse 中修改字体大小和编码格式
eclipse 中修改字体大小的步骤: 1. 在 eclipse 的工具栏中,找到 weindows 下面的 preferences 2. 在 preferences 的 输出 font ,在 Bas ...
随机推荐
- VisualStudio 2013 快捷键
有些快捷键不是默认的,需要插件支持,如Resharper,WebEssentials,VSCommands Ctrl单键系列 Ctrl+Q Quick Info Ctrl+W Extend Selec ...
- 876. Middle of the Linked List【Easy】【单链表中点】
Given a non-empty, singly linked list with head node head, return a middle node of linked list. If t ...
- Oracle实例,具体运用
Oracle关键字的使用 使用insert 添加数据: INSERT INTO 表名 VALUES (加入对应的数); COMMIT; INSERT INTO p_emp VALUES('TO ...
- AndroidManifest.xml文件详解(application)
http://blog.csdn.net/think_soft/article/details/7557101 语法(SYNATX): <application android:allowTas ...
- Eclipse 报 "The builder launch configuration could not be found" 错误的解决办法
http://blog.csdn.net/defonds/article/details/26340561 Eclipse 忽然报 "The builder launch configura ...
- 树链剖分【CF165D】Beard Graph
Description 给定一棵树,有m次操作. 1 x 把第x条边染成黑色 2 x 把第x条边染成白色 3 x y 查询x~y之间的黑边数,存在白边输出-1 Input 第1行为一个整数\(n\), ...
- ActiveMQ 认证(一)
新搭建的ActiveMQ服务,在发布和读取消息时,连接的权限为ActiveMQConnection.DEFAULT_USER和ActiveMQConnection.DEFAULT_PASSWORD. ...
- [Luogu1979][NOIP2013]华容道(BFS+SPFA)
考虑从起点到终点的过程,一定是先将空格子移到指定格子旁边,和指定格子交换,再移到下一个指定格子要到的地方,再交换,如此反复. 于是问题分为两个部分: 1.给定两个曼哈顿距离为2的格子求最短路,BFS即 ...
- 【推导】【贪心】Codeforces Round #431 (Div. 1) A. From Y to Y
题意:让你构造一个只包含小写字母的可重集,每次可以取两个元素,将它们合并,合并的代价是这两个元素各自的从‘a’到‘z’出现的次数之积的和. 给你K,你构造的可重集必须满足将所有元素合而为一以后,所消耗 ...
- 关于JS的This指针
下面讨论一个执行上下文的最后一个属性——this指针的概念. This指针 A this value is a special object which is related with the exe ...