UITableViewCell是指UITableView表格的单元。
主要用法:
1、创建
- (id)initWithStyle:(UITableViewCellStyle)style reuseIdentifier:(NSString *)reuseIdentifier
UITableViewCell * tableViewCell =[ [UITableViewCell alloc] initWithStyle:UITableViewCellStyleValue1reuseIdentifier:@"txCell";
2、常用属性
@property(nonatomic, readonly, retain)UILabel *textLabel
@property(nonatomic, readonly, retain)UILabel *detailTextLabel
@property(nonatomic, readonly, retain) UIImageView *imageView
@property(nonatomic) UITableViewCellSelectionStyle selectionStyle //主要用于设置UITableViewCell选中后的颜色变化
@property(nonatomic, getter=isHighlighted) BOOL highlighted
@property(nonatomic, readonly) UITableViewCellEditingStyle editingStyle //UITableViewCell的编辑状态,主要有删除和添加3种,
UITableViewCellEditingStyleNone,
UITableViewCellEditingStyleDelete,
UITableViewCellEditingStyleInsert