Skip to content

Instantly share code, notes, and snippets.

@aekapop
Created September 7, 2018 12:09
Show Gist options
  • Save aekapop/3b1ae95ff7502b28b4b94c6f1895aebb to your computer and use it in GitHub Desktop.
Save aekapop/3b1ae95ff7502b28b4b94c6f1895aebb to your computer and use it in GitHub Desktop.
Change EN-TH language with Left Option-Left Shift in Karabiner
{
"title": "Language Toggler",
"rules": [
{
"description": "Switch between TH <-> EN (Left Option + Left Shift)",
"manipulators": [
{
"conditions": [
{
"input_sources": [
{
"language": "en"
}
],
"type": "input_source_if"
}
],
"from": {
"key_code": "left_shift",
"modifiers": {
"mandatory": ["left_option"]
}
},
"to": [
{
"key_code": "left_shift",
"modifiers": ["left_option"]
}
],
"to_if_alone": [
{
"select_input_source": {
"language": "th"
}
}
],
"type": "basic"
},
{
"conditions": [
{
"input_sources": [
{
"language": "th"
}
],
"type": "input_source_if"
}
],
"from": {
"key_code": "left_shift",
"modifiers": {
"mandatory": ["left_option"]
}
},
"to": [
{
"key_code": "left_shift",
"modifiers": ["left_option"]
}
],
"to_if_alone": [
{
"select_input_source": {
"language": "en"
}
}
],
"type": "basic"
}
]
}
]
}
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment