title: css style hex strings and Color.decode
body: <p><a href="http://www.javalobby.org/java/forums/t19183.html" rel="noreferrer">this article</a> suggests you can use <code>Color c = Color.decode("FF0096");</code> however this understandably throws an exception</p>
  
  <pre><code>Caused by: java.lang.NumberFormatException: For input string: "FF0096"
      at java.lang.NumberFormatException.forInputString(NumberFormatException.java:48)
      at java.lang.Integer.parseInt(Integer.java:449)
      at java.lang.Integer.valueOf(Integer.java:528)
      at java.lang.Integer.decode(Integer.java:958)
      at java.awt.Color.decode(Color.java:707)
  </code></pre>
  
  <p>What is the best way of converting a String in the format of "#FF0096" or "FF0096" into a java awt Color?</p>