title: Custom UIView gets attched to MainViewcontoller
body: <p><a href="https://i.stack.imgur.com/aJ2rU.png" rel="nofollow noreferrer"><img src="https://i.stack.imgur.com/aJ2rU.png" alt="enter image description here"></a>I created a customView that I used as a tooltip in my Map application. The custom view is created by using xib and it shows up but the problem I have now is instead of the view to remain as it was created, it goes on to attach itself to the top of the view controller.</p>
  
  <p>below is the xib file and what I want my view to look like</p>
  
  <p><a href="https://i.stack.imgur.com/RGsi1.png" rel="nofollow noreferrer"><img src="https://i.stack.imgur.com/RGsi1.png" alt="enter image description here"></a></p>
  
  <p>here is what shows up on my device when I run it in simulator</p>
  
  <p><a href="https://i.stack.imgur.com/Ih8w9.jpg" rel="nofollow noreferrer"><img src="https://i.stack.imgur.com/Ih8w9.jpg" alt="enter image description here"></a></p>
  
  <p>how can Make this view the size I want it to be and not attach to the to of the ViewController.</p>
  
  <p>I called the InfoView like</p>
  
  <pre><code>func mapView(_ mapView: GMSMapView, markerInfoContents marker: GMSMarker) -&gt; UIView? {
      guard let placeMarker = marker as? PlaceMarker else {
        return nil
      }
      guard let infoView = UIView.viewFromNibName("MarkerInfoView") as? MarkerInfoView else {
        return nil
      }
  
      infoView.nameLabel.text = placeMarker.place.name
      if let photo = placeMarker.place.photo {
        infoView.placePhoto.image = photo
      } else {
        infoView.placePhoto.image = UIImage(named: "generic")
      }
  
      return infoView
    }
  </code></pre>