diff options
| author | Laurenz <laurmaedje@gmail.com> | 2022-05-04 22:14:57 +0200 |
|---|---|---|
| committer | Laurenz <laurmaedje@gmail.com> | 2022-05-04 22:14:57 +0200 |
| commit | e674fd7e909c273c36952f01829544a2efc11c92 (patch) | |
| tree | c74218ce4a546de06b28aad2f73ba460338252b7 /src/geom | |
| parent | 75472fee1a2377f56551fc856cf7511bd55091f0 (diff) | |
New raw theme & nicer debug representation
Diffstat (limited to 'src/geom')
| -rw-r--r-- | src/geom/paint.rs | 5 |
1 files changed, 3 insertions, 2 deletions
diff --git a/src/geom/paint.rs b/src/geom/paint.rs index 351ef443..9b310249 100644 --- a/src/geom/paint.rs +++ b/src/geom/paint.rs @@ -154,7 +154,7 @@ impl FromStr for RgbaColor { impl From<SynColor> for RgbaColor { fn from(color: SynColor) -> Self { - Self::new(color.r, color.b, color.g, color.a) + Self::new(color.r, color.g, color.b, color.a) } } @@ -167,10 +167,11 @@ impl Debug for RgbaColor { self.r, self.g, self.b, self.a, )?; } else { - write!(f, "#{:02x}{:02x}{:02x}", self.r, self.g, self.b)?; + write!(f, "rgb(\"#{:02x}{:02x}{:02x}", self.r, self.g, self.b)?; if self.a != 255 { write!(f, "{:02x}", self.a)?; } + write!(f, "\")")?; } Ok(()) } |
