title: Is it possible to set custom font & size for NSString?
body: <p>I'm working with Swift in iOS 9. I want to customize the font for a <code>UIAlertAction</code>. I searched these questions for a Swift answer:</p>
  
  <p><a href="https://stackoverflow.com/questions/31497218/change-the-font-of-uialertaction-in-swift">Change the Font of UIAlertAction in Swift</a></p>
  
  <p><a href="https://stackoverflow.com/questions/26357066/is-it-possible-to-customize-the-font-and-appearance-of-a-uialertcontroller-in-th">Is it possible to customize the font and appearance of a UIAlertController in the new XCode w/ iOS8?</a></p>
  
  <p>And this question for an Objective-C answer:
  <a href="https://stackoverflow.com/questions/26460706/uialertcontroller-custom-font-size-color">UIAlertController custom font, size, color</a></p>
  
  <p>But there was no solution for customizing the font for a <code>UIAlertAction</code>.</p>
  
  <p>I believe the problem is that a <code>UIAlertAction</code> uses an <code>NSString</code> for its <code>title</code> property. <a href="https://github.com/nst/iOS-Runtime-Headers/blob/3dde29deb7000cfac59d3e5473a71557123f29ea/Frameworks/UIKit.framework/UIAlertAction.h" rel="nofollow noreferrer">See demo project on Github.</a></p>
  
  <p>I would like to create a string like so:</p>
  
  <pre><code>let originalString: String = "OK"
  let myString: NSString = originalString as NSString
  </code></pre>
  
  <p>And then customize the string's font &amp; size. Then after adding my actions to the alert controller, assign the string to my actions using key-value coding:</p>
  
  <pre><code>alertController!.actions[0].setValue(myString, forKey: "title")
  </code></pre>
  
  <p>But as far as I can tell, there is no way to set a custom font and size for an <code>NSString</code>. If it used a <code>UILabel</code> instead, then it would be easy to customize the font. But I seem to be stuck with the limitations of strings. Does anyone know a way to assign a custom font &amp; size to a string, or am I correct in believing there is no way to do this?</p>