title: Apply bolding to portion of NSAttributedString, while preserving font sizes and faces
body: <p>I'm working on a rich text editor for iOS, using a <code>UITextView</code> along with an <code>NSAttributedString</code>. It'll function similarly to traditional ones (i.e. selecting a region, clicking a button, and it applies that effect to that region, while preserving any other attributes on the text.</p>
  
  <p>Unfortunately with <code>NSAttributedString</code>, not all of them can be adjusted independently. Several of them (at least bold, font face, and font size) all require passing a <code>UIFont</code>, which'll set all of those attributes for the region (even if you only wanted to set one). Seeing as a single region might include several faces and sizes, this'll result in the naive approach breaking a lot of existing formatting.</p>
  
  <p>Is there any recommended means to accomplish this? I'm thinking my only option will be to iterate through the attributes for the region I want to apply it to, group it into chunks that have the same other font attributes, and then apply it to each chunk individually.</p>