开发者

Label in the table's cell

开发者 https://www.devze.com 2023-02-17 16:40 出处:网络
I want to add a label into the table\'s cell. In my case the cell is 开发者_运维技巧generated from another file using UITableViewCell . any guidance ?

I want to add a label into the table's cell. In my case the cell is 开发者_运维技巧generated from another file using UITableViewCell . any guidance ?

Thanks...


If your other file is a subclass of UITableViewCell you can:

  1. define the UITableViewCell view programmatically
  2. define the view using a NIBfile

You would typically pass a pointer to the content of your table view cell to the cell init method so the cell can initialize itself with proper model information.

You should also typically retrieve the cell content view size to place your elements programmatically if you choose method 1.

Good luck.

0

精彩评论

暂无评论...
验证码 换一张
取 消