在section中更改titleFor Header的颜色 [英] changing the color of titleFor Header in section

查看:413
本文介绍了在section中更改titleFor Header的颜色的处理方法,对大家解决问题具有一定的参考价值,需要的朋友们下面随着小编来一起学习吧!

问题描述

-(NSString *)tableView:(UITableView *)tableView titleForHeaderInSection:(NSInteger)section 

{

}

您好
我在目标c中非常新... ...............通过这种方法我们可以获得标题部分的标题。但是如何改变该字符串的颜色?我可以这样做........如果任何人都知道请告诉我。

Hi
I am very new in objective c.......................through this method we can get the title for header section .but how to change the color of that string?can I do that........if any one knows that please tell me.

问候

推荐答案

当心您返回的视图未被UITableView保留(OS 3.1.2至少似乎显示此问题)。这导致在执行到viewDidLoad之前发生的难以发现的崩溃。

Beware that the view you return is not retained by the UITableView (OS 3.1.2 at least seems to display this problem). This leads to hard-to-find crashes that occur before execution gets to viewDidLoad.

表视图不会像您想象的那样按需获取视图。它会请求所有人,然后再次请求所有人,有时再多次请求他们,所以在每次请求时生成它们的效率非常低。

The table view doesn't grab your views on demand as you would think. It requests them all, then requests them all again, and sometimes several more times, so generating them on every request is very inefficient.

这篇关于在section中更改titleFor Header的颜色的文章就介绍到这了,希望我们推荐的答案对大家有所帮助,也希望大家多多支持IT屋!

查看全文
登录 关闭
扫码关注1秒登录
发送“验证码”获取 | 15天全站免登陆