UITableViewCell の UITextLabel のフレームを設定できません。CGRect を作成し、それをフレームとして設定しましたが、うまくいかないようです。以下のコードで設定された UITextLabel の他のすべてのプロパティ (カラー フォントとテキスト) は、必要に応じてレンダリングされます。
UITableViewCell *c = [tableView dequeueReusableCellWithIdentifier:@"Cell"];
if(!c)
{
c = [[UITableViewCell alloc] initWithStyle:UITableViewCellStyleDefault reuseIdentifier:@"Cell"];
}
NSString *soundName = [[soundNames objectAtIndex:[indexPath row]] valueForKey:@"Name"];
UIColor *whiteColor = [UIColor whiteColor];
[[c textLabel] setTextColor:whiteColor];
[[c textLabel] setText:soundName];
[[c textLabel] setFont:[UIFont fontWithName:@"Gill Sans" size:17]];
CGRect textLabelFrame = CGRectMake(50, 7, 270, 29);
[[c textLabel] setFrame:textLabelFrame];
return c;
ここで何が起こっているのかについてのアイデアはありますか?