Trait colorfully::traits::Colors
source · pub trait Colors {
Show 36 methods
fn black(&self) -> String;
fn red(&self) -> String;
fn green(&self) -> String;
fn yellow(&self) -> String;
fn blue(&self) -> String;
fn cyan(&self) -> String;
fn purple(&self) -> String;
fn white(&self) -> String;
fn gray(&self) -> String;
fn bg_black(&self) -> String;
fn bg_red(&self) -> String;
fn bg_green(&self) -> String;
fn bg_yellow(&self) -> String;
fn bg_blue(&self) -> String;
fn bg_cyan(&self) -> String;
fn bg_purple(&self) -> String;
fn bg_white(&self) -> String;
fn bg_gray(&self) -> String;
fn lighter_black(&self) -> String;
fn lighter_red(&self) -> String;
fn lighter_green(&self) -> String;
fn lighter_yellow(&self) -> String;
fn lighter_blue(&self) -> String;
fn lighter_cyan(&self) -> String;
fn lighter_purple(&self) -> String;
fn lighter_white(&self) -> String;
fn lighter_gray(&self) -> String;
fn lighter_bg_black(&self) -> String;
fn lighter_bg_red(&self) -> String;
fn lighter_bg_green(&self) -> String;
fn lighter_bg_yellow(&self) -> String;
fn lighter_bg_blue(&self) -> String;
fn lighter_bg_cyan(&self) -> String;
fn lighter_bg_purple(&self) -> String;
fn lighter_bg_white(&self) -> String;
fn lighter_bg_gray(&self) -> String;
}Required Methods§
fn black(&self) -> String
fn red(&self) -> String
fn green(&self) -> String
fn yellow(&self) -> String
fn blue(&self) -> String
fn cyan(&self) -> String
fn purple(&self) -> String
fn white(&self) -> String
fn gray(&self) -> String
fn bg_black(&self) -> String
fn bg_red(&self) -> String
fn bg_green(&self) -> String
fn bg_yellow(&self) -> String
fn bg_blue(&self) -> String
fn bg_cyan(&self) -> String
fn bg_purple(&self) -> String
fn bg_white(&self) -> String
fn bg_gray(&self) -> String
fn lighter_black(&self) -> String
fn lighter_red(&self) -> String
fn lighter_green(&self) -> String
fn lighter_yellow(&self) -> String
fn lighter_blue(&self) -> String
fn lighter_cyan(&self) -> String
fn lighter_purple(&self) -> String
fn lighter_white(&self) -> String
fn lighter_gray(&self) -> String
fn lighter_bg_black(&self) -> String
fn lighter_bg_red(&self) -> String
fn lighter_bg_green(&self) -> String
fn lighter_bg_yellow(&self) -> String
fn lighter_bg_blue(&self) -> String
fn lighter_bg_cyan(&self) -> String
fn lighter_bg_purple(&self) -> String
fn lighter_bg_white(&self) -> String
fn lighter_bg_gray(&self) -> String
Implementations on Foreign Types§
source§impl Colors for String
impl Colors for String
source§fn black(&self) -> String
fn black(&self) -> String
make black text
let text = "black.to_string()"
println!("{} color", text.black());
source§fn red(&self) -> String
fn red(&self) -> String
make red text
let text = "red".to_string();
println!("{} color", text.red());
source§fn green(&self) -> String
fn green(&self) -> String
make green text
let text = "green.to_string()"
println!("{} color", text.green());
source§fn yellow(&self) -> String
fn yellow(&self) -> String
make yellow text
let text = "yellow".to_string();
println!("{} color", text.yellow());
source§fn blue(&self) -> String
fn blue(&self) -> String
make blue text
let text = "blue".to_string();
println!("{} color", text.blue());
source§fn purple(&self) -> String
fn purple(&self) -> String
make purple text
let text = "purple".to_string();
println!("{} color", text.purple());
source§fn cyan(&self) -> String
fn cyan(&self) -> String
make cyan text
let text = "cyan".to_string();
println!("{} color", text.cyan());
source§fn white(&self) -> String
fn white(&self) -> String
make white text
let text = "white".to_string();
println!("{} color", text.white());
source§fn gray(&self) -> String
fn gray(&self) -> String
make gray text
let text = "gray".to_string();
println!("{} color", text.gray());
source§fn bg_black(&self) -> String
fn bg_black(&self) -> String
make black background text
let text = "black background".to_string();
println!("{}", text.bg_black());
source§fn bg_red(&self) -> String
fn bg_red(&self) -> String
make red background text
let text = "red background".to_string();
println!("{}", text.bg_red());
source§fn bg_green(&self) -> String
fn bg_green(&self) -> String
make green background text
let text = "green background".to_string();
println!("{}", text.bg_green());
source§fn bg_yellow(&self) -> String
fn bg_yellow(&self) -> String
make yellow background text
let text = "yellow background".to_string();
println!("{}", text.bg_yellow());
source§fn bg_blue(&self) -> String
fn bg_blue(&self) -> String
make blue background text
let text = "blue background".to_string();
println!("{}", text.bg_blue());
source§fn bg_purple(&self) -> String
fn bg_purple(&self) -> String
make purple background text
let text = "purple background".to_string();
println!("{}", text.bg_purple());
source§fn bg_cyan(&self) -> String
fn bg_cyan(&self) -> String
make cyan background text
let text = "cyan background".to_string();
println!("{}", text.bg_cyan());
source§fn bg_white(&self) -> String
fn bg_white(&self) -> String
make white background text
let text = "white background".to_string();
println!("{}", text.bg_white());
source§fn bg_gray(&self) -> String
fn bg_gray(&self) -> String
make gray background text
let text = "gray background".to_string();
println!("{}", text.bg_gray());
source§fn lighter_black(&self) -> String
fn lighter_black(&self) -> String
make light black text
let text = "black".to_string();
println!("{} color", text.lighter_black());
source§fn lighter_red(&self) -> String
fn lighter_red(&self) -> String
make light red text
let text = "red".to_string();
println!("{} color", text.lighter_red());
source§fn lighter_green(&self) -> String
fn lighter_green(&self) -> String
make light green text
let text = "green".to_string();
println!("{} color", text.lighter_green());
source§fn lighter_yellow(&self) -> String
fn lighter_yellow(&self) -> String
make light yellow text
let text = "yellow".to_string();
println!("{} color", text.lighter_yellow());
source§fn lighter_blue(&self) -> String
fn lighter_blue(&self) -> String
make light blue text
let text = "blue".to_string();
println!("{} color", text.lighter_blue());
source§fn lighter_purple(&self) -> String
fn lighter_purple(&self) -> String
make light purple text
let text = "purple".to_string();
println!("{} color", text.lighter_purple());
source§fn lighter_cyan(&self) -> String
fn lighter_cyan(&self) -> String
make light cyan text
let text = "cyan".to_string();
println!("{} color", text.lighter_cyan());
source§fn lighter_white(&self) -> String
fn lighter_white(&self) -> String
make light white text
let text = "white".to_string();
println!("{} color", text.lighter_white());
source§fn lighter_gray(&self) -> String
fn lighter_gray(&self) -> String
make light gray text
let text = "gray".to_string();
println!("{} color", text.lighter_gray());
source§fn lighter_bg_black(&self) -> String
fn lighter_bg_black(&self) -> String
make lighter black background text
let text = "black background".to_string();
println!("{}", text.lighter_bg_black());
source§fn lighter_bg_red(&self) -> String
fn lighter_bg_red(&self) -> String
maklighter e red background text
let text = "red background".to_string();
println!("{}", text.lighter_bg_red());
source§fn lighter_bg_green(&self) -> String
fn lighter_bg_green(&self) -> String
make lighter green background text
let text = "green background".to_string();
println!("{}", text.lighter_bg_green());
source§fn lighter_bg_yellow(&self) -> String
fn lighter_bg_yellow(&self) -> String
make ylighter ellow background text
let text = "yellow background".to_string();
println!("{}", text.lighter_bg_yellow());
source§fn lighter_bg_blue(&self) -> String
fn lighter_bg_blue(&self) -> String
makelighter blue background text
let text = "blue background".to_string();
println!("{}", text.lighter_bg_blue());
source§fn lighter_bg_purple(&self) -> String
fn lighter_bg_purple(&self) -> String
make plighter urple background text
let text = "purple background".to_string();
println!("{}", text.lighter_bg_purple());
source§fn lighter_bg_cyan(&self) -> String
fn lighter_bg_cyan(&self) -> String
makelighter cyan background text
let text = "cyan background".to_string();
println!("{}", text.lighter_bg_cyan());
source§fn lighter_bg_white(&self) -> String
fn lighter_bg_white(&self) -> String
make lighter white background text
let text = "white background".to_string();
println!("{}", text.lighter_bg_white());
source§fn lighter_bg_gray(&self) -> String
fn lighter_bg_gray(&self) -> String
makelighter gray background text
let text = "gray background".to_string();
println!("{}", text.lighter_bg_gray());
source§impl Colors for str
impl Colors for str
source§fn black(&self) -> String
fn black(&self) -> String
make black text
let text = "black"
println!("{} color", text.black());
source§fn green(&self) -> String
fn green(&self) -> String
make green text
let text = "green"
println!("{} color", text.green());
source§fn yellow(&self) -> String
fn yellow(&self) -> String
make yellow text
let text = "yellow"
println!("{} color", text.yellow());
source§fn purple(&self) -> String
fn purple(&self) -> String
make purple text
let text = "purple"
println!("{} color", text.purple());
source§fn white(&self) -> String
fn white(&self) -> String
make white text
let text = "white"
println!("{} color", text.white());
source§fn bg_black(&self) -> String
fn bg_black(&self) -> String
make black background text
let text = "black background"
println!("{}", text.bg_black());
source§fn bg_red(&self) -> String
fn bg_red(&self) -> String
make red background text
let text = "red background"
println!("{}", text.bg_red());
source§fn bg_green(&self) -> String
fn bg_green(&self) -> String
make green background text
let text = "green background"
println!("{}", text.bg_green());
source§fn bg_yellow(&self) -> String
fn bg_yellow(&self) -> String
make yellow background text
let text = "yellow background"
println!("{}", text.bg_yellow());
source§fn bg_blue(&self) -> String
fn bg_blue(&self) -> String
make blue background text
let text = "blue background"
println!("{}", text.bg_blue());
source§fn bg_purple(&self) -> String
fn bg_purple(&self) -> String
make purple background text
let text = "purple background"
println!("{}", text.bg_purple());
source§fn bg_cyan(&self) -> String
fn bg_cyan(&self) -> String
make cyan background text
let text = "cyan background"
println!("{}", text.bg_cyan());
source§fn bg_white(&self) -> String
fn bg_white(&self) -> String
make white background text
let text = "white background"
println!("{}", text.bg_white());
source§fn bg_gray(&self) -> String
fn bg_gray(&self) -> String
make gray background text
let text = "gray background"
println!("{}", text.bg_gray());
source§fn lighter_black(&self) -> String
fn lighter_black(&self) -> String
make light black text
let text = "black"
println!("{} color", text.lighter_black());
source§fn lighter_red(&self) -> String
fn lighter_red(&self) -> String
make light red text
let text = "red"
println!("{} color", text.lighter_red());
source§fn lighter_green(&self) -> String
fn lighter_green(&self) -> String
make light green text
let text = "green"
println!("{} color", text.lighter_green());
source§fn lighter_yellow(&self) -> String
fn lighter_yellow(&self) -> String
make light yellow text
let text = "yellow"
println!("{} color", text.lighter_yellow());
source§fn lighter_blue(&self) -> String
fn lighter_blue(&self) -> String
make light blue text
let text = "blue"
println!("{} color", text.lighter_blue());
source§fn lighter_purple(&self) -> String
fn lighter_purple(&self) -> String
make light purple text
let text = "purple"
println!("{} color", text.lighter_purple());
source§fn lighter_cyan(&self) -> String
fn lighter_cyan(&self) -> String
make light cyan text
let text = "cyan"
println!("{} color", text.lighter_cyan());
source§fn lighter_white(&self) -> String
fn lighter_white(&self) -> String
make light white text
let text = "white"
println!("{} color", text.lighter_white());
source§fn lighter_gray(&self) -> String
fn lighter_gray(&self) -> String
make light gray text
let text = "gray"
println!("{} color", text.lighter_gray());
source§fn lighter_bg_black(&self) -> String
fn lighter_bg_black(&self) -> String
make lighter black background text
let text = "black background"
println!("{}", text.lighter_bg_black());
source§fn lighter_bg_red(&self) -> String
fn lighter_bg_red(&self) -> String
maklighter e red background text
let text = "red background"
println!("{}", text.lighter_bg_red());
source§fn lighter_bg_green(&self) -> String
fn lighter_bg_green(&self) -> String
make lighter green background text
let text = "green background"
println!("{}", text.lighter_bg_green());
source§fn lighter_bg_yellow(&self) -> String
fn lighter_bg_yellow(&self) -> String
make ylighter ellow background text
let text = "yellow background"
println!("{}", text.lighter_bg_yellow());
source§fn lighter_bg_blue(&self) -> String
fn lighter_bg_blue(&self) -> String
makelighter blue background text
let text = "blue background"
println!("{}", text.lighter_bg_blue());
source§fn lighter_bg_purple(&self) -> String
fn lighter_bg_purple(&self) -> String
make plighter urple background text
let text = "purple background"
println!("{}", text.lighter_bg_purple());
source§fn lighter_bg_cyan(&self) -> String
fn lighter_bg_cyan(&self) -> String
makelighter cyan background text
let text = "cyan background"
println!("{}", text.lighter_bg_cyan());
source§fn lighter_bg_white(&self) -> String
fn lighter_bg_white(&self) -> String
make lighter white background text
let text = "white background"
println!("{}", text.lighter_bg_white());
source§fn lighter_bg_gray(&self) -> String
fn lighter_bg_gray(&self) -> String
makelighter gray background text
let text = "gray background"
println!("{}", text.lighter_bg_gray());