Hi -> Light
This commit is contained in:
parent
6f1621d2d0
commit
543b2f8975
32
src/color.rs
32
src/color.rs
|
@ -18,21 +18,21 @@ pub enum Color {
|
||||||
/// White.
|
/// White.
|
||||||
White,
|
White,
|
||||||
/// High-intensity black.
|
/// High-intensity black.
|
||||||
HiBlack,
|
LightBlack,
|
||||||
/// High-intensity red.
|
/// High-intensity red.
|
||||||
HiRed,
|
LightRed,
|
||||||
/// High-intensity green.
|
/// High-intensity green.
|
||||||
HiGreen,
|
LightGreen,
|
||||||
/// High-intensity yellow.
|
/// High-intensity yellow.
|
||||||
HiYellow,
|
LightYellow,
|
||||||
/// High-intensity blue.
|
/// High-intensity blue.
|
||||||
HiBlue,
|
LightBlue,
|
||||||
/// High-intensity magenta.
|
/// High-intensity magenta.
|
||||||
HiMagenta,
|
LightMagenta,
|
||||||
/// High-intensity cyan.
|
/// High-intensity cyan.
|
||||||
HiCyan,
|
LightCyan,
|
||||||
/// High-intensity white.
|
/// High-intensity white.
|
||||||
HiWhite,
|
LightWhite,
|
||||||
/// 216-color (r, g, b ≤ 5) RGB.
|
/// 216-color (r, g, b ≤ 5) RGB.
|
||||||
Rgb(u8, u8, u8),
|
Rgb(u8, u8, u8),
|
||||||
/// Grayscale (max value: 24)
|
/// Grayscale (max value: 24)
|
||||||
|
@ -61,14 +61,14 @@ impl Color {
|
||||||
Magenta => 0x5,
|
Magenta => 0x5,
|
||||||
Cyan => 0x6,
|
Cyan => 0x6,
|
||||||
White => 0x7,
|
White => 0x7,
|
||||||
HiBlack => 0x8,
|
LightBlack => 0x8,
|
||||||
HiRed => 0x9,
|
LightRed => 0x9,
|
||||||
HiGreen => 0xA,
|
LightGreen => 0xA,
|
||||||
HiYellow => 0xB,
|
LightYellow => 0xB,
|
||||||
HiBlue => 0xC,
|
LightBlue => 0xC,
|
||||||
HiMagenta => 0xD,
|
LightMagenta => 0xD,
|
||||||
HiCyan => 0xE,
|
LightCyan => 0xE,
|
||||||
HiWhite => 0xF,
|
LightWhite => 0xF,
|
||||||
Rgb(r, g, b) => 16 + 36 * r + 6 * g + b,
|
Rgb(r, g, b) => 16 + 36 * r + 6 * g + b,
|
||||||
Grayscale(shade) => 0xE8 + shade,
|
Grayscale(shade) => 0xE8 + shade,
|
||||||
}
|
}
|
||||||
|
|
Loading…
Reference in New Issue