Rescaling a UITableView for the iPad?
Recently, I have begun porting my iPhone app to the iPad and I have a view with a UITableView subview. Is there any way to rescale the table? The autoresizing masks don't blow up the font and I basically just want a rescaled, crisp, larger version 开发者_运维技巧of the table for the iPad. Is there an easy way to go about doing this?
You could set cell.textLabel.font
to a bigger one in cellForRowAtIndexPath:
.
You could up the height of each cell by implementing heightForRowAtIndexPath:
, e.g.
- (CGFloat)tableView:(UITableView *)tableView
heightForRowAtIndexPath:(NSIndexPath *)indexPath
{
return 123.f;
}
Those are the ones I can think of, off hand.
you can set the table's rowHeight in the viewWillAppear.
self.tableView.rowHeight = 130.0;
Or use the UISplitViewController
. The Tableview on the left and show the data, which should be displayed if you click one cell in the right view. ;-)
精彩评论