title: How can I place my target view on top of the tab bar?
body: <p>I want to place my <strong>targetView</strong> right on top of the <strong>tab bar</strong>. I created a <strong>XIB-File</strong> with a <strong>targetLabel</strong> and a <strong>cancelButton</strong>.</p>
  <p>I tried to place my <a href="https://i.stack.imgur.com/JyXBd.png" rel="nofollow noreferrer">targetView</a> programmatically on top of my <strong>tab bar</strong> but I can´t figure out how to do it without space between them.</p>
  <pre><code>[self addOverlayView:self.targetView x:0 y:self.view.frame.size.height - self.targetView.frame.size.height - 10];
  </code></pre>
  <p><em><strong>addOverview</strong></em> is a func I made to place a view where ever you want:</p>
  <pre><code>- (void)addOverlayView:(UIView*)v x:(CGFloat)x y:(CGFloat)y
  {
      v.hidden = YES;
      CGRect vFrame = v.frame;
      vFrame.origin.x = x;
      vFrame.origin.y = y;
      
      if ((v.autoresizingMask &amp; UIViewAutoresizingFlexibleWidth) != 0) {
          vFrame.size.width = topView.bounds.size.width;
      }
      v.frame = vFrame;
      [v.layer setTransform:CATransform3DMakeTranslation(0, 0, OVERLAY_TRANSLATION_Z)];
      
      [overlayView addSubview:v];
      
  }
  </code></pre>
  <p>I don´t know if this was the right approach but it works for me (so far).</p>
  <p>What do I have to change in so that my <em><strong>targetView</strong></em> is right on top of my <em><strong>tabBar</strong></em>?</p>