Skip to content

Add Numpad Layout #214

New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Open
wants to merge 2 commits into
base: master
Choose a base branch
from
Open
Show file tree
Hide file tree
Changes from all commits
Commits
File filter

Filter by extension

Filter by extension

Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
3 changes: 3 additions & 0 deletions src/key_layouts.scad
Original file line number Diff line number Diff line change
Expand Up @@ -18,3 +18,6 @@ include <layouts/dactyl_manuform/4x6.scad>
include <layouts/dactyl_manuform/4x6_legends.scad>

include <layouts/plate.scad>

include <layouts/numpad/default.scad>
include <layouts/numpad/no_legends.scad>
35 changes: 35 additions & 0 deletions src/layouts/numpad/default.scad
Original file line number Diff line number Diff line change
@@ -0,0 +1,35 @@
include <../layout.scad>

/* The Plus and Enter keys will need to be added manually to the keys.scad file
Copy and paste the following two lines into keys.scad to add plus and enter, changing 'LAYOUT_ROW' to your chosen layout

translate_u(x=3.5, y=-1.5, z=0) LAYOUT_ROW(1) legend("+", size=6) numpad_plus() key();
translate_u(x=3.5, y=-3.5, z=0) LAYOUT_ROW(3) legend("⏎", size=6) numpad_enter() key();

Make sure you comment out/delete the 10u keys and their associated legends before exporting keys.
*/

numpad_default_layout = [
[1,1,1,1],
[1,1,1,],
[1,1,1],
[1,1,1],
[2,1],
[],
[10],
[10]
];

numpad_legends = [
["№", "/", "*", "-"],
["7", "8", "9"],
["4", "5", "6"],
["1", "2", "3"],
["0", "."],
[],
["CHECK NUMPAD_DEFAULT LAYOUT FILE"],
["TO ADD NUMPAD PLUS AND ENTER"]
];
module numpad_default(profile) {
layout(numpad_default_layout, profile, numpad_legends) children();
}
35 changes: 35 additions & 0 deletions src/layouts/numpad/no_legends.scad
Original file line number Diff line number Diff line change
@@ -0,0 +1,35 @@
include <../layout.scad>

/* The Plus and Enter keys will need to be added manually to the keys.scad file
Copy and paste the following two lines into keys.scad to add plus and enter, changing 'LAYOUT_ROW' to your chosen layout

translate_u(x=3.5, y=-1.5, z=0) LAYOUT_ROW(1) numpad_plus() key();
translate_u(x=3.5, y=-3.5, z=0) LAYOUT_ROW(3) numpad_enter() key();

Make sure you comment out/delete the 10u keys and their associated legends before exporting keys.
*/

numpad_no_legends_layout = [
[1,1,1,1],
[1,1,1,],
[1,1,1],
[1,1,1],
[2,1],
[],
[10],
[10]
];

numpad_legends = [
[],
[],
[],
[],
[],
[],
["CHECK NUMPAD_NO_LEGENDS LAYOUT FILE"],
["TO ADD NUMPAD PLUS AND ENTER"]
];
module numpad_no_legends(profile) {
layout(numpad_default_layout, profile, numpad_legends) children();
}