mirror of
https://github.com/chylex/IntelliJ-AceJump.git
synced 2025-04-09 17:15:43 +02:00
Add QWERTZ (CZ) layout that remaps top row to digits
This commit is contained in:
parent
2681d9901f
commit
48bcf9f284
src/main/kotlin/org/acejump
@ -4,13 +4,25 @@ package org.acejump.input
|
||||
* Defines common keyboard layouts. Each layout has a key priority order, based on each key's distance from the home row and how
|
||||
* ergonomically difficult they are to press.
|
||||
*/
|
||||
@Suppress("unused")
|
||||
enum class KeyLayout(internal val rows: Array<String>, priority: String) {
|
||||
@Suppress("unused", "SpellCheckingInspection")
|
||||
enum class KeyLayout(internal val rows: Array<String>, priority: String, internal val characterRemapping: Map<Char, Char> = emptyMap()) {
|
||||
COLEMK(arrayOf("1234567890", "qwfpgjluy", "arstdhneio", "zxcvbkm"), priority = "tndhseriaovkcmbxzgjplfuwyq5849673210"),
|
||||
WORKMN(arrayOf("1234567890", "qdrwbjfup", "ashtgyneoi", "zxmcvkl"), priority = "tnhegysoaiclvkmxzwfrubjdpq5849673210"),
|
||||
DVORAK(arrayOf("1234567890", "pyfgcrl", "aoeuidhtns", "qjkxbmwvz"), priority = "uhetidonasxkbjmqwvzgfycprl5849673210"),
|
||||
QWERTY(arrayOf("1234567890", "qwertyuiop", "asdfghjkl", "zxcvbnm"), priority = "fjghdkslavncmbxzrutyeiwoqp5849673210"),
|
||||
QWERTZ(arrayOf("1234567890", "qwertzuiop", "asdfghjkl", "yxcvbnm"), priority = "fjghdkslavncmbxyrutzeiwoqp5849673210"),
|
||||
QWERTZ_CZ(arrayOf("1234567890", "qwertzuiop", "asdfghjkl", "yxcvbnm"), priority = "fjghdkslavncmbxyrutzeiwoqp5849673210", characterRemapping = mapOf(
|
||||
'+' to '1',
|
||||
'ě' to '2',
|
||||
'š' to '3',
|
||||
'č' to '4',
|
||||
'ř' to '5',
|
||||
'ž' to '6',
|
||||
'ý' to '7',
|
||||
'á' to '8',
|
||||
'í' to '9',
|
||||
'é' to '0'
|
||||
)),
|
||||
QGMLWY(arrayOf("1234567890", "qgmlwyfub", "dstnriaeoh", "zxcvjkp"), priority = "naterisodhvkcpjxzlfmuwygbq5849673210"),
|
||||
QGMLWB(arrayOf("1234567890", "qgmlwbyuv", "dstnriaeoh", "zxcfjkp"), priority = "naterisodhfkcpjxzlymuwbgvq5849673210"),
|
||||
NORMAN(arrayOf("1234567890", "qwdfkjurl", "asetgynioh", "zxcvbpm"), priority = "tneigysoahbvpcmxzjkufrdlwq5849673210");
|
||||
|
@ -75,7 +75,7 @@ class Session(private val mainEditor: Editor, private val jumpEditors: List<Edit
|
||||
val state = state ?: return
|
||||
|
||||
editorSettings.startEditing(editor)
|
||||
val result = mode.type(state, charTyped, acceptedTag)
|
||||
val result = mode.type(state, AceConfig.layout.characterRemapping.getOrDefault(charTyped, charTyped), acceptedTag)
|
||||
editorSettings.stopEditing(editor)
|
||||
|
||||
when (result) {
|
||||
|
Loading…
Reference in New Issue
Block a user