title: How to handle UTF-8 email headers (like Subject:) using Ruby?
body: <p>I'm an email n00b but I am working on an application that sends HTML email with Unicode characters (as my friend noted "enjoy encoding hell").</p>
  
  <p>The <code>Subject:</code> header comes from user input and therefore may contain Unicode characters. Some mail clients (like GMail and Outlook 2007) are OK with this, but from my reading it seems the right way to do this is to use <a href="http://en.wikipedia.org/wiki/MIME#Encoded-Word" rel="noreferrer">MIME Encoded-Word encoding</a> for the headers.</p>
  
  <p>I cannot find a Ruby library to do this. Is there one?</p>
  
  <p>Also, is there a header to add that will tell mail clients to use UTF-8 when displaying the message? We are sending multipart email so our <code>Content-Type</code> is <code>multipart/mixed</code>. Apple Mail.app in particular is not using the right encoding, even though it's specified in the individual parts as being UTF-8.</p>