Trait colorfully::traits::Property
source · pub trait Property {
fn reset(&self) -> String;
fn bold(&self) -> String;
fn light(&self) -> String;
fn italic(&self) -> String;
fn under_line(&self) -> String;
}Required Methods§
fn reset(&self) -> String
fn bold(&self) -> String
fn light(&self) -> String
fn italic(&self) -> String
fn under_line(&self) -> String
Implementations on Foreign Types§
source§impl Property for String
impl Property for String
source§fn reset(&self) -> String
fn reset(&self) -> String
make original text
let text = "original".to_string
println!("this is {} text", text.reset.bold());
source§fn bold(&self) -> String
fn bold(&self) -> String
make bold text
let text = "bold".to_string
println!("this is {} text", text.bold());
source§fn light(&self) -> String
fn light(&self) -> String
make light text
let text = "light".to_string
println!("this is {} text", text.light());
source§fn italic(&self) -> String
fn italic(&self) -> String
make italic text
let text = "italic".to_string
println!("this is {} text", text.italic());
source§fn under_line(&self) -> String
fn under_line(&self) -> String
make under line text
let text = "under line".to_string
println!("this is {} text", text.under_line());
source§impl Property for str
impl Property for str
source§fn reset(&self) -> String
fn reset(&self) -> String
make original text
let text = "original"
println!("this is {} text", text.reset.bold());
source§fn bold(&self) -> String
fn bold(&self) -> String
make bold text
let text = "bold"
println!("this is {} text", text.bold());
source§fn light(&self) -> String
fn light(&self) -> String
make light text
let text = "light"
println!("this is {} text", text.light());
source§fn italic(&self) -> String
fn italic(&self) -> String
make italic text
let text = "italic"
println!("this is {} text", text.italic());
source§fn under_line(&self) -> String
fn under_line(&self) -> String
make under line text
let text = "under line"
println!("this is {} text", text.under_line());