title: UIImage Is Not Fitting In UIScrollView At Start
body: <p>I have an image like:</p>
  
  <p><img src="https://i.stack.imgur.com/Tx9oC.png" alt="Want To Have"></p>
  
  <p>When I load the image to uiimageview and then adding as a subview to uiscrollview, at start the image is showing like:</p>
  
  <p><img src="https://i.stack.imgur.com/10ku2.png" alt="Dont Want To Have"></p>
  
  <p>The problem is I want to see all the image fit to screen at start but it is showing already zoomed. Is there a way to handle this please help ...</p>
  
  <p>I have the code like:</p>
  
  <pre><code>[self.view addSubview:scrollView];
  UIImageView *tempImageView = 
  [[UIImageView alloc] initWithImage:[UIImage imageNamed:@"Tree.jpg"]];
  self.imageView = tempImageView;
  [tempImageView release];
  [scrollView setContentMode:UIViewContentModeScaleAspectFit];
  [imageView sizeToFit];
  scrollView.backgroundColor=[UIColor blackColor];
  scrollView.contentSize = imageView.frame.size;
  scrollView.minimumZoomScale = scrollView.frame.size.width / imageView.frame.size.width;
  scrollView.maximumZoomScale = 4.0;
  [scrollView setZoomScale:1.0];
  scrollView.clipsToBounds = YES;
  scrollView.delegate = self;
  [scrollView addSubview:imageView];
  </code></pre>