tags:

views:

22

answers:

3

Hi Guys,

I am trying to change frame sizes of an imageView. textLabel and detailTextLabel of UITableViewCell property on inside the UITableView. I tried with change the frame size, resizing mask, resizing subviews and so on, but there is no use. Is there any way to change default frame size? and I am using UITableViewCellStyleSubtitle.

Note: My images took their own image size.

A: 

In my opinion, the right way is to redesigned the cell. 2 possibilities:

  • Programmatically in tableView:cellForRowAtIndexPath: (see iOS guide)
  • with a custom UITableCellView (see iOS guide)

And for the cell height: tableView:heightForRowAtIndexPath: of the delegate

Benoît
+1  A: 

I think is possible with a UITableViewDelegate method: – tableView:willDisplayCell:forRowAtIndexPath:

you can set frame sizes, position, etc. Basically any layout should have effect there. or you can subclass UITableViewCell and override layoutSubviews: method (don't forget to call [super layoutSubviews]; first)

Actually I am doing the second approach and works excelent.

Hope this helps ;)

nacho4d
A: 

Hi, I could change default image size by using this link. Click here

Thanks to all responses.

Sivanathan