Skip to content

Commit 33556cf

Browse files
add imprint_letters_only_full_bottom_row layout (#33)
* add imprint_letters_only_full_bottom_row layout * fix style
1 parent 2962ce8 commit 33556cf

File tree

3 files changed

+20
-1
lines changed

3 files changed

+20
-1
lines changed

README.md

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -40,7 +40,7 @@ indent_str = " " # Optional, used for each indent level when printing.
4040

4141
```toml
4242
layout = "kinesis:adv360" # Required
43-
# Available options are ["kinesis:adv360", "sweep", "moergo:glove80"]
43+
# Available options are ["kinesis:adv360", "sweep", "moergo:glove80", "imprint:letters_only_full_bottom_row"]
4444
```
4545

4646
```toml
Lines changed: 15 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -0,0 +1,15 @@
1+
use super::KeyboardLayout;
2+
3+
pub fn get_layout() -> KeyboardLayout {
4+
#[rustfmt::skip]
5+
let bindings = vec![
6+
1, 1, 1, 1, 1, 1, 0, 0, 0, 1, 1, 1, 1, 1, 1,
7+
1, 1, 1, 1, 1, 1, 0, 0, 0, 1, 1, 1, 1, 1, 1,
8+
1, 1, 1, 1, 1, 1, 0, 0, 0, 1, 1, 1, 1, 1, 1,
9+
1, 1, 1, 1, 1, 0, 0, 0, 0, 0, 1, 1, 1, 1, 1,
10+
0, 0, 0, 1, 1, 1, 0, 0, 0, 1, 1, 1, 0, 0, 0,
11+
0, 0, 0, 1, 1, 1, 0, 0, 0, 1, 1, 1, 0, 0, 0,
12+
];
13+
14+
KeyboardLayout { bindings, row_count: 6 }
15+
}

src/layouts/mod.rs

Lines changed: 4 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -3,6 +3,7 @@ use serde::{Deserialize, Serialize};
33
mod adv360;
44
mod glove80;
55
mod sweep;
6+
mod imprint_letters_only_full_bottom_row;
67

78
#[derive(Serialize, Deserialize, Default)]
89
pub enum KeyboardLayoutType {
@@ -13,6 +14,8 @@ pub enum KeyboardLayoutType {
1314
Sweep,
1415
#[serde(rename = "moergo:glove80")]
1516
Glove80,
17+
#[serde(rename = "imprint:letters_only_full_bottom_row")]
18+
ImprintLettersOnlyFullBottomRow,
1619
}
1720

1821
pub struct KeyboardLayout {
@@ -31,5 +34,6 @@ pub fn get_layout(layout_type: &KeyboardLayoutType) -> KeyboardLayout {
3134
KeyboardLayoutType::Adv360 => adv360::get_layout(),
3235
KeyboardLayoutType::Sweep => sweep::get_layout(),
3336
KeyboardLayoutType::Glove80 => glove80::get_layout(),
37+
KeyboardLayoutType::ImprintLettersOnlyFullBottomRow => imprint_letters_only_full_bottom_row::get_layout(),
3438
}
3539
}

0 commit comments

Comments
 (0)