Prevent indentation of UITableViewCell (contentView) while editing

前端 未结 9 770
心在旅途
心在旅途 2020-12-05 02:38

Is it possible to keep the contentView.frame always the same, regardless of tableView.editing? I already tried to override layoutSubviews

9条回答
  •  Happy的楠姐
    2020-12-05 02:56

    Just came across this as I was researching the same problem.

    A very easy solution is to set the indentation level to a negative number - it is a signed integer after all.

    A [cell setIndentationLevel:-3] worked perfectly for me, given a default indentation width of 10, to move the label back to the left in a plain table.

提交回复
热议问题