0

I need some help. I have a custom separator color of dark grey. For some reason, I'm getting a white separator above the sections, and the separator inset is white.

My layout is: A UITableView within a UIView within a normal UIViewController.

I've already tried these things:

  • Set separator inset to 0. This will make the white separator inset shorter, but it is still there. ?
  • Set the background colors of the table and the containing view to black. This didn't work.
  • For the UITableViewCell, I can set

    cell.separatorInset = UIEdgeInsetsZero;
    

    and

    cell.layoutMargins = UIEdgeInsetsZero; 
    

and then the white separator inset will disappear, but the grey separator goes to the edge of the screen. I still need a separator inset that matches the black background.

Here is what I see:

Bad Separator Inset

halfer
  • 19,824
  • 17
  • 99
  • 186
TheJeff
  • 3,665
  • 34
  • 52
  • This is not a duplicate - This post IS NOT THE SAME as the other post because that guy wants to simply remove the separator inset. Easy. If you read my question it is clear that I want to keep the separator inset, but just make it match the background color and not white. I actually read that post and it did not help in the slightest. Read the things I said I tried - it didn't work! – TheJeff Apr 08 '16 at 19:30
  • Flagging for moderator review to remove "marked as duplicate" – TheJeff Apr 08 '16 at 19:36

0 Answers0