Function flag
Source pub fn flag(short: &str, long: &str, doc: &str) -> impl Arg<Item = bool>
12 fn args() -> impl Arg<Item = Self> {
13 let window = args_depend! {
14 opt("", "width", "", ""),
15 opt("", "height", "", ""),
16 }
17 .option_map(|(width, height)| Dimensions::Window { width, height });
18 let fullscreen = flag("", "fullscreen", "").some_if(Dimensions::Fullscreen);
19 window.choice(fullscreen).required()
20 }