Skip to content
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
12 changes: 12 additions & 0 deletions README.md
Original file line number Diff line number Diff line change
Expand Up @@ -6,10 +6,22 @@ Currently it only supports 2 layouts (the ones I use)

#### Layout supported

- US Qwerty
- US ALT INT
- US Colemak-DH
- IT
- ES
- FR
- PL
- PT-BR
- DE
- JP
- HEB
- RU
- SE
- SLV
- CH
- ALB
- BLR
- DK
- NL
6 changes: 5 additions & 1 deletion main.py
Original file line number Diff line number Diff line change
Expand Up @@ -19,6 +19,8 @@ def on_event(self, event, extension):
query = event.get_query().strip()
if query == extension.preferences['kus']:
subprocess.Popen(['setxkbmap', 'us', '-variant', 'alt-intl'])
if query == extension.preferences['kusa']:
subprocess.Popen(['setxkbmap', 'us'])
elif query == extension.preferences['kit']:
subprocess.Popen(['setxkbmap', 'it'])
elif query == extension.preferences['kes']:
Expand Down Expand Up @@ -53,8 +55,10 @@ def on_event(self, event, extension):
subprocess.Popen(['setxkbmap', 'da'])
elif query == extension.preferences['nl']:
subprocess.Popen(['setxkbmap', 'nl'])
elif query == extension.preferences['kbr']:
subprocess.Popen(['setxkbmap', 'br'])
return HideWindowAction()


if __name__ == '__main__':
KeyboardLayoutChange().run()
16 changes: 15 additions & 1 deletion manifest.json
Original file line number Diff line number Diff line change
Expand Up @@ -96,7 +96,7 @@
"id": "ch",
"type": "keyword",
"name": "ch",
"description": "Switch to ch iso keyboard layout",
"description": "Switch to Switzerland iso keyboard layout",
"default_value": "ch"
},
{
Expand Down Expand Up @@ -126,6 +126,20 @@
"name": "nl",
"description": "Switch to Dutch iso keyboard layout",
"default_value": "nl"
},
{
"id": "kusa",
"type": "keyword",
"name": "kusa",
"description": "Switch to Qwerty US iso keyboard layout",
"default_value": "kusa"
},
{
"id": "kbr",
"type": "keyword",
"name": "kbr",
"description": "Switch to Qwerty Brazillian iso keyboard layout",
"default_value": "kbr"
}
]
}