Unable to resize UITableViewCell in Interface Builder

Does anyone have the same problem as mine? ... I upgraded to iPhone SDK 3.2 and I cannot resize the UITableViewCell object in my XIB file (usually I just resized the view, but now the cell has one same size, and there is only gray color around) ... btw, I tried to reinstall twice, including one deep reinstall.

+4
source share
5 answers

Hey, I had the same problem. It's old, so maybe you have found a solution already, but for those who donโ€™t ...

Select a cell in IB and raise the size panel (by clicking on it or using command-3). In the "Size and position" section, set the frame and edit the height field.

Easy, yes. I donโ€™t know how we missed it.

+4
source

The size of the table can be set by dragging and dropping the cell frame in the interface builder. Then do then tableview delegate tableView heightForRowAtIndexPath for the specific cell in which you want to have different heights.

+3
source

I have 3.2 and I do not have this problem. Make sure you return the correct cell height for heightForRowAtIndexPath. So, for a cell at zero of a zero row, zero (which uses a custom UITableViewCell), use the cell height defined in the XIB:

- (CGFloat)tableView:(UITableView *)tableView heightForRowAtIndexPath:(NSIndexPath *)indexPath { if(indexPath.section == 0 && indexPath.row == 0) return m_customCell.frame.size.height; else return 44; } 
+2
source

first tab (Attributes) โ†’ subtab (Elements of the simulated user interface) โ†’ Status bar: set (not specified). Worked for me

+1
source

The accepted answer (choosing TableCell) and using the inspector did not help me with XCODE 5.

This worked: - In the Interface Builder, select TABLE VIEW (NOT TableViewCell). - Then in the inspector (size inspector), pay attention to the top line "Row Height". Install it as desired. - Also note that the section height can also be set here!

Final note: a table cell can definitely be dragged and resized.

+1
source

Source: https://habr.com/ru/post/1301774/


All Articles