title: Grid layout with CollectionView in Swift
body: <p>I would like to achieve this result:
  <a href="https://i.stack.imgur.com/Pl6CG.jpg" rel="noreferrer"><img src="https://i.stack.imgur.com/Pl6CG.jpg" alt="enter image description here"></a></p>
  
  <p>Searching around I found out that probably the way to do it is using <code>UICollectionView</code>, so no problem with that since there are many tutorials and questions on Stack Overflow. I have 3 questions: </p>
  
  <ol>
  <li><p>I cannot find anything about the "separators" (the line that divides all the boxes). I like that it doesn't touch the screen borders horizontally. Is it done programmatically? </p></li>
  <li><p>To divide the space equally in all devices (3 boxes/buttons horizontally)  I found this answer <a href="https://stackoverflow.com/questions/28325277/how-to-set-cell-spacing-and-uicollectionview-uicollectionviewflowlayout-size-r">answer</a>. Is this the right approach?</p></li>
  <li><p>For the Blur effect I found this answer:  <a href="https://stackoverflow.com/questions/24424165/how-to-implement-uivisualeffectview-in-uitableview-with-adaptive-segues">How to implement UIVisualEffectView in UITableView with adaptive segues</a></p></li>
  </ol>
  
  <p>For a <code>TableView</code> it would be:</p>
  
  <pre><code>if (!UIAccessibilityIsReduceTransparencyEnabled()) {
  tableView.backgroundColor = UIColor.clearColor()
  let blurEffect = UIBlurEffect(style: .Light)
  let blurEffectView = UIVisualEffectView(effect: blurEffect)
  tableView.backgroundView = blurEffectView
  }
  </code></pre>
  
  <p>Can I do something like this?</p>
  
  <pre><code>     @IBOutlet var collectionView: UICollectionView!
      if (!UIAccessibilityIsReduceTransparencyEnabled()) {
      collectionView.backgroundColor = UIColor.clearColor()
      let blurEffect = UIBlurEffect(style: .Light)
      let blurEffectView = UIVisualEffectView(effect: blurEffect)
      collectionView.backgroundView = blurEffectView
      }
  </code></pre>