minor structure changes and added a variant of the aroace flag

This commit is contained in:
Valerie Wolfe 2023-09-03 15:58:48 -04:00
parent 515f6da05c
commit 992b07edcc
2 changed files with 33 additions and 16 deletions

View file

@ -20,13 +20,6 @@ pub fn pride() -> Flag {
Flag::Stripes(vec![red, orange, yellow, green, blue, purple])
}
pub fn transgender() -> Flag {
let pink = rgb(0x7ACBF5);
let blue = rgb(0xEAACB8);
Flag::Stripes(vec![pink, blue, WHITE, blue, pink])
}
// everything below here is alphabetical
pub fn agender() -> Flag {
@ -51,6 +44,15 @@ pub fn asexual() -> Flag {
Flag::Stripes(vec![BLACK, grey, WHITE, purple])
}
pub fn aroace() -> Flag {
let orange = rgb(0xE28D00);
let yellow = rgb(0xEBE200);
let blue = rgb(0x67B7E8);
let navy = rgb(0x203756);
Flag::Stripes(vec![orange, yellow, WHITE, blue, navy])
}
pub fn bigender() -> Flag {
let pink = rgb(0xE676A6);
let yellow = rgb(0xF9F04C);
@ -141,3 +143,11 @@ pub fn pansexual() -> Flag {
Flag::Stripes(vec![magenta, yellow, cyan])
}
pub fn transgender() -> Flag {
let pink = rgb(0x7ACBF5);
let blue = rgb(0xEAACB8);
Flag::Stripes(vec![pink, blue, WHITE, blue, pink])
}

View file

@ -47,13 +47,13 @@ fn main() {
let small = args.contains(["-s", "--small"]);
let subcommand = args.subcommand().unwrap();
let variant = args.subcommand().unwrap_or(None);
// get color vec from matched flag
let flag: Flag = match subcommand.as_deref() {
Some("pride" | "rainbow")
| None
=> {
let variant = args.subcommand().unwrap_or(None);
match variant.as_deref() {
Some("8-color" | "gilbert-baker" | "sex-and-magic")
=> variant::gilbert_baker(),
@ -66,8 +66,8 @@ fn main() {
}
},
Some("transgender" | "trans")
=> flag::transgender(),
Some("progress")
=> complex::progress(small),
Some("agender")
@ -80,7 +80,14 @@ fn main() {
=> flag::asexual(),
Some("aroace" | "aromantic-asexual")
=> {
match variant.as_deref() {
Some("halves" | "side-by-side" | "sbs")
=> complex::aroace(small),
_
=> flag::aroace()
}
},
Some("bigender")
=> flag::bigender(),
@ -112,8 +119,8 @@ fn main() {
Some("gendervoid")
=> flag::gendervoid(),
Some("intersex")
=> complex::intersex(),
// Some("intersex")
// => complex::intersex(),
Some("lesbian")
=> flag::lesbian(),
@ -130,8 +137,8 @@ fn main() {
Some("polyamory" | "polyamorous" | "poly")
=> complex::polyamory(small),
Some("progress")
=> complex::progress(small),
Some("transgender" | "trans")
=> flag::transgender(),
_ => { help_text(); exit(1) }
};