Not a member of Pastebin yet?
Sign Up,
it unlocks many cool features!
- #singleInstance force
- MsgBox IPA Mode Activated.
- ;BeginRegion beginnings
- lastKey =
- toggleMode = 0
- symbol = a
- symbolName = aaa
- GUI +LastFound +AlwaysOnTop +owner
- GUI Font, s30, code2000
- GUI Add, Text, vSymb h50 w300 center, %symbol%
- GUI Font, s10, Arial
- GUI Add, Text, vDesc w300 center, %symbolName%
- GUI Add, Text, vNext w300 center,
- ;EndRegion beginnings
- ;BeginRegion Engine
- typeLetter(ByRef string, ByRef description = "") {
- global lastKey
- global toggleMode
- global allSymbolNames
- global Desc
- global Symb
- global Next
- invokeKey := SubStr(string, 0, 1)
- if (invokeKey <> lastKey) {
- gosub resetValue
- }
- toggleMode += 1
- if (toggleMode <> 0) {
- SendInput {backspace}
- }
- order := Mod(toggleMode, StrLen(string)) + 1
- symbol := SubStr(string, order, 1)
- StringSplit allSymbolNames, description, |, %A_Space%
- allSymbolNames := ""
- symbolName := allSymbolNames%order%
- SendInput %symbol%
- if symbolName
- {
- GUIControl,, Desc, %symbolName%
- GUIControl,, Symb, %symbol%
- GUIControl,, Next, %string%
- GUI show, X0 Y800 NoActivate, IPA Symbol Inserted
- }
- lastKey := invokeKey
- SetTimer, resetValue, 750
- }
- resetValue:
- toggleMode = -1
- lastKey =
- GUI hide
- return
- ;EndRegion
- ;BeginRegion symbol list
- ;BeginRegion A-M and 3 but not F or K
- +a::typeLetter("aɑæɐ", "Open Front Vowel | Open Back Vowel | Near-Open Front Vowel | Near-Open Central Vowel")
- +b::typeLetter("bβɓʙ", "Voiced Bilabial Plosive | Voiced Bilabial Fricative | Voiced Bilabial Implosive | Bilabial Trill")
- +c::typeLetter("cɕç", "Voiceless Palatal Plosive | Voiceless Alveo-Palatal Fricative | Voiceless Palatal Fricative")
- +d::typeLetter("dðɖɗ", "Voiced Alveolar Plosive | Voiced Dental Fricative | Voiced Retroflex Plosive | Voiced Alveolar Implosive")
- +e::typeLetter("eəɚɵɘ", "Close-Mid Front Vowel | Mid Central Vowel | Rhoticized Mid Central Vowl | Close-Mid Central Rounded Vowel | Close-Mid Central Vowel")
- +3::typeLetter("3ɛɜɝɞ", "Three (Not an IPA Character) | Open-Mid Front Vowel | Open-Mid Central Vowel | Rhoticized Open-Mid Central Vowel | Open-Mid Central Rounded Vowel")
- +g::typeLetter("gɠɢʛ", "Voiced Velar Plosive | Voiced Velar Implosive | Voiced Uvular Plosive | Voiced Uvular Implosive")
- +h::typeLetter("hɥɦħɧʜ", "Voiceless Glottal Transition | Labial-Palatal Approximant | Voiced Glottal Fricative | Voiceless Pharangeal Fricative | Sje-sound | Voiceless Epiglottal Fricative")
- +i::typeLetter("iɪɨ", "Close Front Vowel | Near-Close Near-Front Vowel | Close Central Vowel")
- +j::typeLetter("jʝɟʄ", "Palatal Approximant | Voiced Palatal Fricative | Voiced Palatal Plosive | Voiced Palatal Implosive")
- +l::typeLetter("lɫɬʟɭɮ", "Alveolar Lateral Approximant | Velarized Alveolar Lateral Approximant, Voiced Alveolar Lateral Fricative | Velar Lateral Approximant | Retroflex Lateral Approximant | Voiced Alveolar Lateral Fricative")
- +m::typeLetter("mɱ", "Bilabial Nasal | Labiodental Nasal")
- ;EndRegion A-M
- ;BeginRegion N-Z and \
- +n::typeLetter("nŋɲɴɳ", "Alveolar Nasal | Velar Nasal | Palatal Nasal | Uvular Nasal | Retroflex Nasal")
- +o::typeLetter("oɔœøɒɶ", "Close-Mid Back Rounded Vowel | Open-Mid Back Rounded Vowel | Open-Mid Front Rounded Vowel | Close-Mid Front Rounded Vowel | Open Back Rounded Vowel | Open Front Rounded Vowel")
- +p::typeLetter("pɸ", "Voiceless Bilabial Plosive | Voiceless Bilabial Fricative")
- +q::typeLetter("qʔʕʢʡ", "Voiceless Uvular Plosive | Glottal Stop | Voiced Pharyngeal Fricative | Voiced Epiglottal Fricative | Epiglottal Plosive")
- +r::typeLetter("rɾʁɹɻʀɽɺ", "Alveolar Trill | Alveolar Tap | Voiced Uvular Fricative | Alveolar Approximant | Retroflex Approximant | Uvular Trill | Retroflex Flap | Alveolar Lateral Flap")
- +s::typeLetter("sʃʂ", "Voiceless Alveolar Sibliant | Voiceless Post-Alveolar Fricative | Voiceless Retroflex Fricative")
- +t::typeLetter("tθʈ", "Voiceless Alveolar Plosive | Voiceless Dental Fricative | Voiceless Retroflex Plosive")
- +u::typeLetter("uʊʉ", "Close Back Rounded Vowel | Near-Close Near-Back Vowel | Close Central Rounded Vowel")
- +v::typeLetter("vʌʋⱱ", "Voiced Labio-Dental Fricative | Open-Back Mid Unrounded Vowel | Labiodental Approximant | Labiodental Flap")
- +w::typeLetter("wʍɯɰ", "Labio-Velar Approximant | Voiceless Labio-Velar Approximant | Close Back Unrounded Vowel | Velar Approximant")
- +x::typeLetter("xχ", "Voiceless Velar Fricative | Voiceless Uvular Fricative")
- +y::typeLetter("yʎɣʏɤ", "Close Front Rounded Vowel | Palatal Lateral Approximant | Voiced Velar Fricative | Near-Close Near-Front Rounded Vowel | Close-Mid Back Vowel")
- +z::typeLetter("zʒʐʑ", "Voiced Dental Fricative | Voiced Post-Alveolar Fricative | Voiced Retroflex Fricative | Voiced Alveo-Palatal Fricative")
- \::typeLetter("ʘǀǃǂǁ", "Bilabial Click | Dental Click | Retroflex Click | Palatal-Alveolar Click | Alveolar Lateral Click")
- ;EndRegion N-Z and \
- ;BeginRegion non-combining diacritics
- ;BeginRegion tones and intonation
- !t:: typeLetter("˥˦˧˨˩", "Tone Level 5 | Tone Level 4 | Tone Level 3 | Tone Level 2 | Tone Level 1")
- !+t:: typeLetter("↓↑↗↘", "Upstep | Downstep | Global Rise | Global Fall")
- ;EndRegion tones and intonation
- ;BeginRegion letter modifiers
- <^>!h::typeLetter("ʰʱ", "Aspirated | Breathy-Voiced Aspirated")
- <^>!e::typeLetter("ᵊ", "Syllabic/Schwa")
- <^>!r::typeLetter("ʳ˞", "Optional R | Rhoticized")
- <^>!w::typeLetter("ʷ", "Labialized")
- <^>!j::typeLetter("ʲ", "Palatalized")
- <^>!y::typeletter("ˠ", "Velarized")
- <^>!q::typeLetter("ˤ", "Pharyngealized")
- <^>!n::typeLetter("ⁿ", "Nasalized")
- <^>!l::typeLetter("ˡ", "Lateral Release")
- ;EndRegion letter modifiers
- ;BeginRegion Phoneme Modifiers
- +Enter::
- +Space::typeLetter("→", "Becomes…")
- +,::typeLetter("'ˈˌʼ", "Apostrophe | Primary Stress | Secondary Stress | Ejective")
- ;EndRegion phoneme modifiers
- +;::
- typeLetter("ːˑ̆", "Long | Half-Long | Short")
- ;EndRegion non-combining diacritics
- ;BeginRegion combining diacritics (warning: zalgo ahead)
- ;BeginRegion tones and intonation
- #t::typeLetter("̋́̄̀̏", "Tone Level 5 | Tone Level 4 | Tone Level 3 | Tone Level 2 | Tone Level 1")
- #+t::typeLetter("̌̂᷄᷅᷈", "Rising | Falling | High Rising | Low Rising | Rising-Falling")
- ;EndRegion tones and intonation
- ;BeginRegion tongue placement modifiers
- <^>!+r::typeLetter("̹̜̘̚", "More Rounded | Less Rounded | Advanced Tongue Root | Retracted Tongue Root | No Audible Release")
- <^>!d::typeLetter("̪", "Dental")
- <^>!a::typeLetter("̺", "Apical")
- <^>!m::typeLetter("̽", "Mid-Centralized")
- <^>!+l::typeLetter("̻", "Laminal")
- +right::typeLetter("̠̙", "Retracted | Retracted Tongue Root")
- +left::typeLetter("̟̘", "Advanced | Advanced Tongue Root")
- ;EndRegion tongue placement modifiers
- ;BeginRegion breath output modifiers
- <^>!b::typeLetter("̯̤̰̼̥̩̬̊̈", "Non-Syllabic | Breathy | Creaky | Linguolabial | Voiceless | Voiceless | Syllabic | Voiced | Centralized")
- ;EndRegion breath output modifiers
- ;BeginRegion letter modifiers
- <^>!+n::typeLetter("̴̃", "Nasalized | Velarized")
- +up::typeLetter("̝", "Raised")
- +down:: typeLetter("̞", "Lowered")
- ;EndRegion letter modifiers
- ;BeginRegion double diacritics
- +6:: typeLetter("͜͡‿", "Tie Bar | Tie Bar Below | Linking")
- ;EndRegion double diacritics
- ;EndRegion combining diacritics
- ;EndRegion
- ;BeginRegion Stop IPA Mode
- Esc::
- endMode:
- MsgBox IPA Mode deactivated.
- GUI destroy
- ExitApp
- ;EndRegion
Advertisement
Add Comment
Please, Sign In to add comment