我已经基于故事板和UITableView与UIViewTableViewCell(风格右详细)的视图之一的项目。UITableViewCell的宽度
在Xcode中一切正常,但是当我在模拟器或设备启动应用程序,该表格单元格看起来太宽。
你有任何建议,这可能是这种奇怪的现象的原因吗?我应该改变什么才能让细胞完全可见?
编辑:
我附加的cellForRowAtIndexPath:
- (UITableViewCell *)tableView:(UITableView *)tableView cellForRowAtIndexPath:(NSIndexPath *)indexPath
{
static NSString *CellIdentifier = @"MyTableCell";
UITableViewCell *cell = [tableView dequeueReusableCellWithIdentifier:CellIdentifier];
if (cell == nil) {
cell = [[UITableViewCell alloc] initWithStyle:UITableViewCellStyleDefault reuseIdentifier:CellIdentifier];
}
cell.accessoryType = UITableViewCellAccessoryDisclosureIndicator;
return cell;
}
它的工作原理与iPhone4一样吗? – 2014-10-29 08:52:29
你可以从cellForRowAtIndexPath发布代码吗? – ZeMoon 2014-10-29 09:05:17
@ZeMoon我编辑了主要问题。 – Grzegorz 2014-10-29 09:23:04