Implement `Show` for `Color`

This PR adds `Color::to_32_bit()` and `Color::to_hex()`. 

It also implements `Show` for `Color`, which outputs the result of `Color::to_hex()`.

Hexadecimal is a familiar representation for colors, but it does require clamping to `[0..255]` and rounding.

Closes #57. 

Open to suggestions. If a simple printing of the array is preferred, I will withdraw this PR, though the hexadecimal conversion might be useful.
Yeah, good catch.
On Aug 30, 2014 12:31 AM, "Mitchell Nordine" <notifications@github.com>
wrote:

> In src/color.rs:
>
> > @@ -180,6 +183,31 @@ impl Color {
> >          (self.r() + self.g() + self.b()) / 3f32
> >      }
> >
> > +    /// Return an array of the channels in this color
> > +    /// clamped to [0..255]
> > +    pub fn to_32_bit(&self) -> [u8, ..4] {
> > +        [
> > +            to_8_bit(self.r()),
> > +            to_8_bit(self.g()),
> > +            to_8_bit(self.b()),
> > +            to_8_bit(self.a()),
> > +        ]
> > +    }
> > +
> > +    /// Return the hex representation of this color
> > +    /// in the format #RRGGBBAA
> > +    /// e.g. `Color(1.0, 0.0, 5.0, 1.0) == "#FF0080FF"`
>
> I think you meant to write 0.5 instead of 5.0 here for the 'blue' arg?
> (each Color element should be clamped between 0.0 and 1.0).
>
> —
> Reply to this email directly or view it on GitHub
> <https://github.com/PistonDevelopers/conrod/pull/108/files#r16928482>.
>