title: Resize Parent view dynamically when Child view is added out of bound
body: <pre><code>UIView *parentView  = [[UIView alloc]initWithFrame:[CGRectMake(0,0,100,100)]];
  UIView *childView  = [[UIView alloc]initWithFrame:[CGRectMake(0,120,100,100)]];
  [parentView addSubview:childView];
  </code></pre>
  
  <p>The code above stating childView is added into parentView at a location outside of parentView bound. Is there anyway i can resize parentView so that the childView is no longer out of bound? I want to do this dynamically. Is there any auto function available, or I have to do it manually by calculating the overall size. </p>
  
  <p>Another question is, before the resizing of parentView to fit in childView, it seems that the childView is added at (0,100) instead of (0,120) of parentView, even though I set [parentView setClipsToBounds:NO];</p>