altgr for string input

This commit is contained in:
minjaesong
2021-11-09 20:58:30 +09:00
parent d5bf27aa93
commit dc0de876d5
6 changed files with 129 additions and 108 deletions

View File

@@ -170,6 +170,7 @@ class UIItemTextLineInput(
fboUpdateLatch = true
forceLitCursor()
val ime = getIME()
val lowLayer = IME.getLowLayerByName(App.getConfigString("basekeyboardlayout"))
if (keycodes.contains(App.getConfigInt("control_key_toggleime")) && repeatCount == 1) {
toggleIME()
@@ -182,7 +183,7 @@ class UIItemTextLineInput(
endComposing()
copyToClipboard()
}
else if (keycodes.contains(Input.Keys.BACKSPACE)) {
else if (keycodes.contains(Input.Keys.BACKSPACE) || (keycodes.contains(Input.Keys.CAPS_LOCK) && lowLayer.capsMode == TerrarumKeyCapsMode.BACK)) {
if (ime != null && ime.composing()) {
candidates = ime.backspace().map { CodepointSequence(it.toCodePoints()) }
}