diff options
author | martin_r <martin_r@b9310e46-f624-0410-8ea1-cfbb3a30dc96> | 2008-08-30 15:03:30 +0000 |
---|---|---|
committer | martin_r <martin_r@b9310e46-f624-0410-8ea1-cfbb3a30dc96> | 2008-08-30 15:03:30 +0000 |
commit | bed114b5561ee8228b8f469aee88fe022da517ae (patch) | |
tree | 920200a360d76fe679b9f0309400809dbc3c29c3 /windows/autohotkey/Source/Methods-Other.ahk | |
parent | 5b16e03383a209783c65e7bde046f8ef0c9a5722 (diff) |
Cokos: ›‼‹, ›⁇‹ über ♫?2/♫!2.
Blinde Compose jetzt auch bei SendUnicodeChar().
SendUnicodeChar belegt CompKey mit dem Argument.
Nicht-blinde Compose wiederhergestellt.
Vorbereitungen zur Aufnahme weiterer Cokos.
Begrenzung der (blinden) Compose auf 2 Zeichen, wenn keine Übereinstimmung mit Coko vorliegt.
»ẗ« zu den Tokos hinzugefügt.
"DeadKey :=" in die dead*-Methoden verschoben.
OutputChar in OutputChar12 umbenannt, OutputChar hat nur noch ein Argument.
Code zusammengefasst, Formatierungen angepasst.
git-svn-id: https://svn.neo-layout.org@833 b9310e46-f624-0410-8ea1-cfbb3a30dc96
Diffstat (limited to '')
-rw-r--r-- | windows/autohotkey/Source/Methods-Other.ahk | 60 |
1 files changed, 55 insertions, 5 deletions
diff --git a/windows/autohotkey/Source/Methods-Other.ahk b/windows/autohotkey/Source/Methods-Other.ahk index b603a8b..a330c9a 100644 --- a/windows/autohotkey/Source/Methods-Other.ahk +++ b/windows/autohotkey/Source/Methods-Other.ahk @@ -1,13 +1,15 @@ -deadAsc(val) {
+deadAsc(val, a) {
global
if !DeadSilence
send % val
+ DeadKey := a
}
-deadUni(val) {
+deadUni(val, a) {
global
if !DeadSilence
SendUnicodeChar(val)
+ DeadKey := a
}
undeadAsc(val) {
@@ -70,7 +72,10 @@ CheckDeadUni12(d,val1,val2) { CheckCompAsc(d,val) {
global
if (PriorCompKey == d) {
+ if !DeadCompose
+ send {bs}
send % val
+ isSecondCompKey = 0
return 1
}
}
@@ -79,10 +84,16 @@ CheckCompAsc12(d,val1,val2) { global
if (PriorCompKey == d)
if (Ebene = 1) and (val1 != "") {
+ if !DeadCompose
+ send {bs}
send % val1
+ isSecondCompKey = 0
return 1
} else if (Ebene = 2) and (val2 != "") {
+ if !DeadCompose
+ send {bs}
send % val2
+ isSecondCompKey = 0
return 1
}
}
@@ -90,7 +101,11 @@ CheckCompAsc12(d,val1,val2) { CheckCompUni(d,val) {
global
if (PriorCompKey == d) {
+ PriorCompKey =
+ if !DeadCompose
+ send {bs}
SendUnicodeChar(val)
+ isSecondCompKey = 0
return 1
}
}
@@ -99,10 +114,18 @@ CheckCompUni12(d,val1,val2){ global
if (PriorCompKey == d) {
if (Ebene = 1) and (val1 != "") {
+ PriorCompKey =
+ if !DeadCompose
+ send {bs}
SendUnicodeChar(val1)
+ isSecondCompKey = 0
return 1
} else if (Ebene = 2) and (val2 != "") {
+ PriorCompKey =
+ if !DeadCompose
+ send {bs}
SendUnicodeChar(val2)
+ isSecondCompKey = 0
return 1
}
}
@@ -111,7 +134,11 @@ CheckCompUni12(d,val1,val2){ CheckComp3Uni(d,val) {
global
if (PriorCompKey == d) {
+ PriorCompKey =
+ if !DeadCompose
+ send {bs}{bs}
SendUnicodeChar(val)
+ isSecondCompKey = 0
return 1
}
}
@@ -120,30 +147,53 @@ CheckComp3Uni12(d,val1,val2) { global
if (PriorCompKey == d) {
if (Ebene = 1) and (val1 != "") {
+ PriorCompKey =
+ if !DeadCompose
+ send {bs}{bs}
SendUnicodeChar(val1)
+ isSecondCompKey = 0
return 1
} else if (Ebene = 2) and (val2 != "") {
+ PriorCompKey =
+ if !DeadCompose
+ send {bs}{bs}
SendUnicodeChar(val2)
+ isSecondCompKey = 0
return 1
}
}
}
-outputChar(val1,val2) {
+OutputChar(val) {
+ global
+ if !((CheckComp(val) or PriorCompKey) and DeadCompose)
+ send % "{blind}" . val
+}
+
+OutputChar12(val1,val2) {
global
if (Ebene = 1)
c := val1
else c := val2
- if !(CheckComp(c) and DeadCompose or PriorCompKey)
+ if !((CheckComp(c) or PriorCompKey) and DeadCompose)
if GetKeyState("Shift","P") and isMod2Locked
send % "{blind}{Shift Up}" . c . "{Shift Down}"
else send % "{blind}" . c
}
-checkComp(d) {
+CheckComp(d) {
global
if (PriorDeadKey = "comp") {
CompKey := d
return 1
+ } else if isSecondCompKey {
+ isSecondCompKey = 0
+ CompKey =
+ PriorCompKey =
+ ;goto neo_%lastHook%
+ } else if PriorCompKey {
+ CompKey := PriorCompKey . "_" . d
+ isSecondCompKey = 1
+ return 1
}
}
|