Function key_name

Source
pub fn key_name(key: KeyMappingCode) -> String
Expand description

Uses the operating system’s API to return a name for the key.

Examples found in repository?
examples/all_keys.rs (line 5)
3
4
5
6
7
8
9
10
11
12
fn main() {
    for &key in ALL_KEYS {
        println!("{:>30} -> {:?}", format!("{:?}", key), key_name(key));
    }
    println!();
    println!(
        "Modifiers: {}<key>",
        mods_prefix_string(true, true, true, true),
    );
}