我已經基於故事板和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