title: Adding Margin to UITableViewCell
body: <p>I am trying to achieve a view I mocked out on sketch. I've replicated it on Android cause I'm really good on that platform. I'm good on iOS, but the UI is kind of my weak point. <a href="https://i.stack.imgur.com/oIdiZ.png"><img src="https://i.stack.imgur.com/oIdiZ.png" alt="The Image"></a> </p>
  
  <p>I extended a <code>UIViewController</code> and on my StoryBoard have the top to be a view and the bottom a tableview. The problem I'm having is centering the <code>UITableViewCell</code> to look like that in the app itself. Below is the solution I've tried. But, it just squeeze it all to the top. NB. I use <code>UIView</code> to draw those Tiny Lines in the <code>UITableViewCell</code></p>
  
  <pre><code>func configureTableView() {
      //First One I tried then later commented it out
      loanStateTable.rowHeight = UITableViewAutomaticDimension
      loanStateTable.scrollToNearestSelectedRowAtScrollPosition(UITableViewScrollPosition.Middle, animated: true)
  
      //Second One I tried
      var edgeInset = UIEdgeInsets(top: 16, left: 16, bottom: 0, right: 16)
      loanStateTable.contentInset = edgeInset
  }
  </code></pre>
  
  <p>And the storyboard view <a href="https://i.stack.imgur.com/cRTeJ.png"><img src="https://i.stack.imgur.com/cRTeJ.png" alt="UITableViewCell"></a></p>
  
  <p>Any help would be appreciated. Thanks</p>
  
  <p>Output:</p>
  
  <p><a href="https://i.stack.imgur.com/a9tyO.png"><img src="https://i.stack.imgur.com/a9tyO.png" alt="OutPut Image"></a></p>