IOS7 and iOS8 in the TableView cell division line left-aligned method is not the same, hereby for later need to take notes.
IOS7 method is very simple, only need to set _table.separatorinset = Uiedgeinsetsmake (0, 0, 0, 0);
The IOS8 method needs to write a piece of code:
-(void) Viewdidlayoutsubviews { if ([_table respondstoselector: @selector (setseparatorinset:)]) { [_table Setseparatorinset:uiedgeinsetszero]; } if ([_table respondstoselector: @selector (setlayoutmargins:)]) { [_table Setlayoutmargins:uiedgeinsetszero ]; }} -(void) TableView: (UITableView *) TableView Willdisplaycell: (UITableViewCell *) cell Forrowatindexpath: (Nsindexpath *) indexpath{ if ([Cell respondstoselector: @selector (setlayoutmargins:)]) { [cell setlayoutmargins: Uiedgeinsetszero]; } if ([Cell respondstoselector: @selector (setseparatorinset:)]) { [cell Setseparatorinset:uiedgeinsetszero]; } }
IOS7 iOS8 tableview separatorinset cell split line left justified