title: Line breaks not working in UILabel
body: <p>I'm loading some help text from a plist and displaying the same in the form of UILabels housed in a UIScrollView. Portion of the code follows:</p>
  
  <p><code></p>
  
  <pre><code>    UILabel *sectionDetailLabel = [[[UILabel alloc] initWithFrame:CGRectMake(34, myOriginForThisSection, 286, 20)] autorelease];
      sectionDetailLabel.backgroundColor = [UIColor clearColor];
      sectionDetailLabel.numberOfLines = 0;
      sectionDetailLabel.font = [UIFont systemFontOfSize:12];
      sectionDetailLabel.textColor = [UIColor blackColor];
      sectionDetailLabel.textAlignment = UITextAlignmentLeft;
      sectionDetailLabel.lineBreakMode = UILineBreakModeWordWrap;
  
      [baseScrollView addSubview:sectionDetailLabel];
  
      [sectionDetailLabel setText:myStringForThisSection];
      [sectionDetailLabel sizeToFit];
  </code></pre>
  
  <p></code></p>
  
  <p>While any 'long' text is getting wrapped into multiple lines correctly, I'm unable to manually insert any line-breaks using newline '\n' characters in 'myStringForThisSection'. I only see the characters '\' and 'n' printed in the UILabel wherever I wanted the line-break, instead.</p>
  
  <p>I looked this up and the general consensus seemed to be that setting numberOfLines to 0, setting the lineBreakMode to a valid value and invoking sizeToFit (or setting the frame of the UILabel based on sizeWithFont:) should do. All of which I seem to be doing in the code above - and works perfectly when fitting long strings of unknown length into multiple lines on the UILabel. So what could be missing here?</p>
  
  <p>Note: All the variables used - baseScrollView, myStringForThisSection and myOriginForThisSection - were loaded before the above code began executing, and work fine.</p>