mercredi 8 août 2018

Using both precomposed and combining diacritics in Keyman 10?

I'm trying to make a keyboard that can add a large variety of diacritics.

I'd like it to produce precomposed characters when it can, but otherwise add a combining diacritic as best it can.

Structures I've attempted: 1.

store(BaseVowels) 'aeiouAEIOU'
store(Breve) 'ăĕĭŏŭĂĔĬŎŬ'

+ [ CTRL K_9 ] > context use(BreveAbove)

group (BreveAbove)
any(BaseVowels) > index(Breve, 1)
'g' > 'ğ'
'G' > 'Ğ'
NOMATCH > U+0306 

2.

store(BaseVowels) 'aeiouAEIOU'
store(Breve) 'ăĕĭŏŭĂĔĬŎŬ'

+ [ CTRL K_9 ] > context use(BreveAbove)

group (BreveAbove)
context > U+0306    
any(BaseVowels) > index(Breve, 1)
U+0306 'g' > 'ğ'
U+0306 'G' > 'Ğ'

3.

store(BaseVowels) 'aeiouAEIOU'
store(Breve) 'ăĕĭŏŭĂĔĬŎŬ'
store(VirtualKeys) 'Has Virtual Key Combinations'
store(Combining) 'Has Combing Diacritics'

+ [ CTRL K_9 ] > context use(BreveAbove)

group (BreveAbove)
any(BaseVowels) > index(Breve, 1)
'g' > 'ğ'
'G' > 'Ğ'
NOMATCH > context use(CombiningDiacritics)

group (CombiningDiacritics)
any(VirtualKeys) > index(Combining, 1)

Obviously, they don't work. 'nomatch' isn't designed for output, and doesn't transfer context. 'Context' can't be used in that way. And the virtual key wouldn't be the first character in the context, so no. 3 doesn't work in multiple ways.

But ARE there commands I could use? Or a different structure? 'If' statements are only for variable constants in Keyman.

I'm lost.

Aucun commentaire:

Enregistrer un commentaire