I am currently working with a custom tableviewcell xib and want the size of it to be automatically resized to the tableview's width and it's row's height.
The size of the cell's view does not auto adjusts to the tableview. So I have tried to change the frame inside the tableView(tableView: UITableView, cellForRowAtIndexPath indexPath: NSIndexPath) delegate no changes are reflected (if I print the frame size before and after it does in fact change.)
Does anyone know a solution for this? The best case would be to make the cell's frame auto adjust to the tableview's width and row height.
Edit: After further examination the problem probably has to do with iOS8 Size classes. When I resize the cell inside the xib, it will just expand to a greater width than the table view's size. The label is supposed to be in the center (had set them with constraints and programmatically, got the same results).
Here's a screenshot:

-(CGFloat)tableView:(UITableView *)tableView heightForRowAtIndexPath:(NSIndexPath *)indexPath- memmons