Skip to content

Commit 19f00b5

Browse files
committed
map buttons 4 and 5 to mission control and center cursor
1 parent 5d7f1a2 commit 19f00b5

File tree

2 files changed

+187
-28
lines changed

2 files changed

+187
-28
lines changed
Lines changed: 165 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -0,0 +1,165 @@
1+
{
2+
"profiles": [
3+
{
4+
"complex_modifications": {
5+
"rules": [
6+
{
7+
"description": "Post escape if left_control is pressed alone.",
8+
"manipulators": [
9+
{
10+
"from": {
11+
"key_code": "left_control",
12+
"modifiers": { "optional": ["any"] }
13+
},
14+
"to": [{ "key_code": "left_control" }],
15+
"to_if_alone": [{ "key_code": "escape" }],
16+
"type": "basic"
17+
}
18+
]
19+
},
20+
{
21+
"description": "Change Fn + h/j/k/l to Arrows",
22+
"manipulators": [
23+
{
24+
"from": {
25+
"key_code": "h",
26+
"modifiers": {
27+
"mandatory": ["fn"],
28+
"optional": ["caps_lock"]
29+
}
30+
},
31+
"to": [{ "key_code": "left_arrow" }],
32+
"type": "basic"
33+
},
34+
{
35+
"from": {
36+
"key_code": "j",
37+
"modifiers": {
38+
"mandatory": ["fn"],
39+
"optional": ["caps_lock"]
40+
}
41+
},
42+
"to": [{ "key_code": "down_arrow" }],
43+
"type": "basic"
44+
},
45+
{
46+
"from": {
47+
"key_code": "k",
48+
"modifiers": {
49+
"mandatory": ["fn"],
50+
"optional": ["caps_lock"]
51+
}
52+
},
53+
"to": [{ "key_code": "up_arrow" }],
54+
"type": "basic"
55+
},
56+
{
57+
"from": {
58+
"key_code": "l",
59+
"modifiers": {
60+
"mandatory": ["fn"],
61+
"optional": ["caps_lock"]
62+
}
63+
},
64+
"to": [{ "key_code": "right_arrow" }],
65+
"type": "basic"
66+
}
67+
]
68+
}
69+
]
70+
},
71+
"devices": [
72+
{
73+
"identifiers": {
74+
"is_keyboard": true,
75+
"product_id": 630,
76+
"vendor_id": 1452
77+
},
78+
"manipulate_caps_lock_led": false
79+
},
80+
{
81+
"identifiers": {
82+
"is_pointing_device": true,
83+
"product_id": 50475,
84+
"vendor_id": 1133
85+
},
86+
"ignore": false
87+
},
88+
{
89+
"identifiers": {
90+
"is_keyboard": true,
91+
"product_id": 50475,
92+
"vendor_id": 1133
93+
},
94+
"ignore": true,
95+
"manipulate_caps_lock_led": false
96+
},
97+
{
98+
"identifiers": {
99+
"is_keyboard": true,
100+
"is_pointing_device": true,
101+
"product_id": 45077,
102+
"vendor_id": 1133
103+
},
104+
"ignore": false,
105+
"manipulate_caps_lock_led": false
106+
},
107+
{
108+
"identifiers": {
109+
"is_keyboard": true,
110+
"product_id": 832,
111+
"vendor_id": 1452
112+
},
113+
"simple_modifications": [
114+
{
115+
"from": { "key_code": "caps_lock" },
116+
"to": [{ "key_code": "left_control" }]
117+
}
118+
]
119+
}
120+
],
121+
"fn_function_keys": [
122+
{
123+
"from": { "key_code": "f3" },
124+
"to": [{ "key_code": "mission_control" }]
125+
},
126+
{
127+
"from": { "key_code": "f4" },
128+
"to": [{ "key_code": "launchpad" }]
129+
},
130+
{
131+
"from": { "key_code": "f5" },
132+
"to": [{ "key_code": "illumination_decrement" }]
133+
},
134+
{
135+
"from": { "key_code": "f6" },
136+
"to": [{ "key_code": "illumination_increment" }]
137+
},
138+
{
139+
"from": { "key_code": "f9" },
140+
"to": [{ "consumer_key_code": "fastforward" }]
141+
}
142+
],
143+
"name": "Default Norton",
144+
"selected": true,
145+
"simple_modifications": [
146+
{
147+
"from": { "key_code": "caps_lock" },
148+
"to": [{ "key_code": "left_control" }]
149+
},
150+
{
151+
"from": { "pointing_button": "button4" },
152+
"to": [{ "key_code": "mission_control" }]
153+
},
154+
{
155+
"from": { "pointing_button": "button5" },
156+
"to": [{ "key_code": "f11" }]
157+
}
158+
],
159+
"virtual_hid_keyboard": {
160+
"country_code": 0,
161+
"keyboard_type_v2": "ansi"
162+
}
163+
}
164+
]
165+
}

karabiner/karabiner.json

Lines changed: 22 additions & 28 deletions
Original file line numberDiff line numberDiff line change
@@ -120,42 +120,36 @@
120120
{
121121
"identifiers": {
122122
"is_keyboard": true,
123-
"product_id": 36,
124-
"vendor_id": 1241
123+
"product_id": 49299,
124+
"vendor_id": 1133
125125
},
126-
"simple_modifications": [
127-
{
128-
"from": { "key_code": "left_command" },
129-
"to": [{ "key_code": "left_option" }]
130-
},
131-
{
132-
"from": { "key_code": "left_option" },
133-
"to": [{ "key_code": "left_command" }]
134-
}
135-
]
126+
"ignore": true
136127
},
137128
{
138129
"identifiers": {
139-
"is_keyboard": true,
140-
"product_id": 270,
141-
"vendor_id": 2131
130+
"is_pointing_device": true,
131+
"product_id": 49299,
132+
"vendor_id": 1133
142133
},
134+
"ignore": false,
143135
"simple_modifications": [
144136
{
145-
"from": { "key_code": "left_command" },
146-
"to": [{ "key_code": "left_option" }]
147-
},
148-
{
149-
"from": { "key_code": "left_option" },
150-
"to": [{ "key_code": "left_command" }]
151-
},
152-
{
153-
"from": { "key_code": "right_option" },
154-
"to": [{ "key_code": "right_command" }]
137+
"from": { "pointing_button": "button4" },
138+
"to": [
139+
{
140+
"software_function": {
141+
"set_mouse_cursor_position": {
142+
"screen": 0,
143+
"x": "50%",
144+
"y": "50%"
145+
}
146+
}
147+
}
148+
]
155149
},
156150
{
157-
"from": { "key_code": "application" },
158-
"to": [{ "key_code": "right_option" }]
151+
"from": { "pointing_button": "button5" },
152+
"to": [{ "key_code": "mission_control" }]
159153
}
160154
]
161155
}
@@ -204,4 +198,4 @@
204198
}
205199
}
206200
]
207-
}
201+
}

0 commit comments

Comments
 (0)