Not a member of Pastebin yet?
Sign Up,
it unlocks many cool features!
- >!\::
- thisPage = -1
- loop
- {
- thisPage := Mod(thisPage + (keyPressed = "q" ? allPages - 1 : 1), allPages)
- keyLabels := "w: " . (diacriticsList[thisPage * 4 + 1] = "" ? "-" : diacriticsList[thisPage * 4 + 1])
- . "`na: " . (diacriticsList[thisPage * 4 + 2] = "" ? "-" : diacriticsList[thisPage * 4 + 2])
- . "`ns: " . (diacriticsList[thisPage * 4 + 3] = "" ? "-" : diacriticsList[thisPage * 4 + 3])
- . "`nd: " . (diacriticsList[thisPage * 4 + 4] = "" ? "-" : diacriticsList[thisPage * 4 + 4])
- nil := thisPage + 1
- IfWinNotExist AHK Dead Keys
- SplashTextOn, 300, 200, AHK Dead Keys (Page %nil% of %allPages%), %keyLabels% `n`ne: next page`nq: last page`nx: quit`n
- else {
- WinSetTitle,,, AHK Dead Keys (Page %nil% of %allPages%)
- ControlSetText, Static1, %keyLabels% `n`ne: next page`nq: last page`nx: quit`n
- }
- Input nil, , wasdeqx
- nil = ; we can discard the rest
- StringRight keyPressed, ErrorLevel, 1
- } until not (keyPressed = "e" or keyPressed = "q")
- SplashTextOff
- if (keyPressed = "x" or diacriticsList[thisPage * 4 + DiacriticsOffset[keyPressed]] = "")
- return
- else
- DeadKey(diacriticsList[thisPage * 4 + DiacriticsOffset[keyPressed]])
- return
Advertisement
Add Comment
Please, Sign In to add comment