【发布时间】:2012-05-12 06:09:51
【问题描述】:
我注意到在我的一个分段控件上,很难看出选择了哪个分段。我在想我可以加粗字体,或者稍微增加字体大小。我正在尝试这个,但它不起作用:
UIFont *boldFont = [UIFont boldSystemFontOfSize:16.0];
NSDictionary *fontDict = [[NSDictionary alloc] initWithObjectsAndKeys:boldFont, UITextAttributeFont, nil];
[_tableSegmentedControl setTitleTextAttributes:fontDict forState:UIControlStateSelected];
我的文本在段控件的两个段中看起来相同。我需要做这样的事情吗? Change textColor in UISegmentedcontrol
如果可能的话,我希望在 iOS 5 中使用更简单的方法并添加外观。谢谢。
【问题讨论】:
标签: iphone uiview uilabel uisegmentedcontrol