diff options
author | Dan Davison <dandavison7@gmail.com> | 2019-12-12 18:29:51 -0500 |
---|---|---|
committer | Dan Davison <dandavison7@gmail.com> | 2019-12-12 18:29:51 -0500 |
commit | 73b915ed057eab5d8910952f111248d89ce5c9f9 (patch) | |
tree | c244044779b172a17f8fb7cfb87cb7786cc1fef4 | |
parent | 0b4452165889406245afedc76434e68d03a881c9 (diff) |
Fix formatting of RGB hex codes
-rw-r--r-- | src/main.rs | 2 |
1 files changed, 1 insertions, 1 deletions
diff --git a/src/main.rs b/src/main.rs index e2ffeea1..05e30bfe 100644 --- a/src/main.rs +++ b/src/main.rs @@ -97,7 +97,7 @@ fn color_to_hex(color: Color) -> String { font_style: FontStyle::empty(), }; paint::paint_text( - &format!("#{:x?}{:x?}{:x?}", color.r, color.g, color.b), + &format!("#{:02x?}{:02x?}{:02x?}", color.r, color.g, color.b), style, &mut string, ) |