Skip to content

Commit d121b9c

Browse files
light4aevyrie
authored andcommitted
bevy_render: add a small color box to each color (bevyengine#4387)
# Objective - bevy_render: add a small color box to each color ## Solution ![bevy_color_doc](https://user-images.githubusercontent.com/1318472/161241226-e7632a90-f526-44de-a68e-ff63b848164b.png) --- ## Changelog
1 parent d4e961b commit d121b9c

File tree

1 file changed

+38
-0
lines changed
  • crates/bevy_render/src/color

1 file changed

+38
-0
lines changed

crates/bevy_render/src/color/mod.rs

Lines changed: 38 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -47,43 +47,81 @@ pub enum Color {
4747
}
4848

4949
impl Color {
50+
/// <div style="background-color:rgb(94%, 97%, 100%); width: 10px; padding: 10px; border: 1px solid;"></div>
5051
pub const ALICE_BLUE: Color = Color::rgb(0.94, 0.97, 1.0);
52+
/// <div style="background-color:rgb(98%, 92%, 84%); width: 10px; padding: 10px; border: 1px solid;"></div>
5153
pub const ANTIQUE_WHITE: Color = Color::rgb(0.98, 0.92, 0.84);
54+
/// <div style="background-color:rgb(49%, 100%, 83%); width: 10px; padding: 10px; border: 1px solid;"></div>
5255
pub const AQUAMARINE: Color = Color::rgb(0.49, 1.0, 0.83);
56+
/// <div style="background-color:rgb(94%, 100%, 100%); width: 10px; padding: 10px; border: 1px solid;"></div>
5357
pub const AZURE: Color = Color::rgb(0.94, 1.0, 1.0);
58+
/// <div style="background-color:rgb(96%, 96%, 86%); width: 10px; padding: 10px; border: 1px solid;"></div>
5459
pub const BEIGE: Color = Color::rgb(0.96, 0.96, 0.86);
60+
/// <div style="background-color:rgb(100%, 89%, 77%); width: 10px; padding: 10px; border: 1px solid;"></div>
5561
pub const BISQUE: Color = Color::rgb(1.0, 0.89, 0.77);
62+
/// <div style="background-color:rgb(0%, 0%, 0%); width: 10px; padding: 10px; border: 1px solid;"></div>
5663
pub const BLACK: Color = Color::rgb(0.0, 0.0, 0.0);
64+
/// <div style="background-color:rgb(0%, 0%, 100%); width: 10px; padding: 10px; border: 1px solid;"></div>
5765
pub const BLUE: Color = Color::rgb(0.0, 0.0, 1.0);
66+
/// <div style="background-color:rgb(86%, 8%, 24%); width: 10px; padding: 10px; border: 1px solid;"></div>
5867
pub const CRIMSON: Color = Color::rgb(0.86, 0.08, 0.24);
68+
/// <div style="background-color:rgb(0%, 100%, 100%); width: 10px; padding: 10px; border: 1px solid;"></div>
5969
pub const CYAN: Color = Color::rgb(0.0, 1.0, 1.0);
70+
/// <div style="background-color:rgb(25%, 25%, 25%); width: 10px; padding: 10px; border: 1px solid;"></div>
6071
pub const DARK_GRAY: Color = Color::rgb(0.25, 0.25, 0.25);
72+
/// <div style="background-color:rgb(0%, 50%, 0%); width: 10px; padding: 10px; border: 1px solid;"></div>
6173
pub const DARK_GREEN: Color = Color::rgb(0.0, 0.5, 0.0);
74+
/// <div style="background-color:rgb(100%, 0%, 100%); width: 10px; padding: 10px; border: 1px solid;"></div>
6275
pub const FUCHSIA: Color = Color::rgb(1.0, 0.0, 1.0);
76+
/// <div style="background-color:rgb(100%, 84%, 0%); width: 10px; padding: 10px; border: 1px solid;"></div>
6377
pub const GOLD: Color = Color::rgb(1.0, 0.84, 0.0);
78+
/// <div style="background-color:rgb(50%, 50%, 50%); width: 10px; padding: 10px; border: 1px solid;"></div>
6479
pub const GRAY: Color = Color::rgb(0.5, 0.5, 0.5);
80+
/// <div style="background-color:rgb(0%, 100%, 0%); width: 10px; padding: 10px; border: 1px solid;"></div>
6581
pub const GREEN: Color = Color::rgb(0.0, 1.0, 0.0);
82+
/// <div style="background-color:rgb(28%, 0%, 51%); width: 10px; padding: 10px; border: 1px solid;"></div>
6683
pub const INDIGO: Color = Color::rgb(0.29, 0.0, 0.51);
84+
/// <div style="background-color:rgb(20%, 80%, 20%); width: 10px; padding: 10px; border: 1px solid;"></div>
6785
pub const LIME_GREEN: Color = Color::rgb(0.2, 0.8, 0.2);
86+
/// <div style="background-color:rgb(50%, 0%, 0%); width: 10px; padding: 10px; border: 1px solid;"></div>
6887
pub const MAROON: Color = Color::rgb(0.5, 0.0, 0.0);
88+
/// <div style="background-color:rgb(10%, 10%, 44%); width: 10px; padding: 10px; border: 1px solid;"></div>
6989
pub const MIDNIGHT_BLUE: Color = Color::rgb(0.1, 0.1, 0.44);
90+
/// <div style="background-color:rgb(0%, 0%, 50%); width: 10px; padding: 10px; border: 1px solid;"></div>
7091
pub const NAVY: Color = Color::rgb(0.0, 0.0, 0.5);
92+
/// <div style="background-color:rgba(0%, 0%, 0%, 0%); width: 10px; padding: 10px; border: 1px solid;"></div>
7193
pub const NONE: Color = Color::rgba(0.0, 0.0, 0.0, 0.0);
94+
/// <div style="background-color:rgb(50%, 50%, 0%); width: 10px; padding: 10px; border: 1px solid;"></div>
7295
pub const OLIVE: Color = Color::rgb(0.5, 0.5, 0.0);
96+
/// <div style="background-color:rgb(100%, 65%, 0%); width: 10px; padding: 10px; border: 1px solid;"></div>
7397
pub const ORANGE: Color = Color::rgb(1.0, 0.65, 0.0);
98+
/// <div style="background-color:rgb(100%, 27%, 0%); width: 10px; padding: 10px; border: 1px solid;"></div>
7499
pub const ORANGE_RED: Color = Color::rgb(1.0, 0.27, 0.0);
100+
/// <div style="background-color:rgb(100%, 8%, 57%); width: 10px; padding: 10px; border: 1px solid;"></div>
75101
pub const PINK: Color = Color::rgb(1.0, 0.08, 0.58);
102+
/// <div style="background-color:rgb(50%, 0%, 50%); width: 10px; padding: 10px; border: 1px solid;"></div>
76103
pub const PURPLE: Color = Color::rgb(0.5, 0.0, 0.5);
104+
/// <div style="background-color:rgb(100%, 0%, 0%); width: 10px; padding: 10px; border: 1px solid;"></div>
77105
pub const RED: Color = Color::rgb(1.0, 0.0, 0.0);
106+
/// <div style="background-color:rgb(98%, 50%, 45%); width: 10px; padding: 10px; border: 1px solid;"></div>
78107
pub const SALMON: Color = Color::rgb(0.98, 0.5, 0.45);
108+
/// <div style="background-color:rgb(18%, 55%, 34%); width: 10px; padding: 10px; border: 1px solid;"></div>
79109
pub const SEA_GREEN: Color = Color::rgb(0.18, 0.55, 0.34);
110+
/// <div style="background-color:rgb(75%, 75%, 75%); width: 10px; padding: 10px; border: 1px solid;"></div>
80111
pub const SILVER: Color = Color::rgb(0.75, 0.75, 0.75);
112+
/// <div style="background-color:rgb(0%, 50%, 50%); width: 10px; padding: 10px; border: 1px solid;"></div>
81113
pub const TEAL: Color = Color::rgb(0.0, 0.5, 0.5);
114+
/// <div style="background-color:rgb(100%, 39%, 28%); width: 10px; padding: 10px; border: 1px solid;"></div>
82115
pub const TOMATO: Color = Color::rgb(1.0, 0.39, 0.28);
116+
/// <div style="background-color:rgb(25%, 88%, 82%); width: 10px; padding: 10px; border: 1px solid;"></div>
83117
pub const TURQUOISE: Color = Color::rgb(0.25, 0.88, 0.82);
118+
/// <div style="background-color:rgb(93%, 51%, 93%); width: 10px; padding: 10px; border: 1px solid;"></div>
84119
pub const VIOLET: Color = Color::rgb(0.93, 0.51, 0.93);
120+
/// <div style="background-color:rgb(100%, 100%, 100%); width: 10px; padding: 10px; border: 1px solid;"></div>
85121
pub const WHITE: Color = Color::rgb(1.0, 1.0, 1.0);
122+
/// <div style="background-color:rgb(100%, 100%, 0%); width: 10px; padding: 10px; border: 1px solid;"></div>
86123
pub const YELLOW: Color = Color::rgb(1.0, 1.0, 0.0);
124+
/// <div style="background-color:rgb(60%, 80%, 20%); width: 10px; padding: 10px; border: 1px solid;"></div>
87125
pub const YELLOW_GREEN: Color = Color::rgb(0.6, 0.8, 0.2);
88126

89127
/// New `Color` from sRGB colorspace.

0 commit comments

Comments
 (0)