title: how to convert int to hexadecimal color format in java
body: <p>I have real numbers 0,1,2,3,4,5,...</p>
  
  <p>I want to convert int to hexadecimal format.</p>
  
  <pre><code>Integer.toHexString(-number-);
  </code></pre>
  
  <p>This works, but it's not in color format.</p>
  
  <p>For example:</p>
  
  <pre><code>int a = 32;
  </code></pre>
  
  <p>must be converted to    000020. These zeros come automatically.</p>
  
  <p>any help ? </p>