Simple replacement might not work as dependent on order characters may be footers ... From Asian back might be easier.
just a sample:
akka : អក្ក
akaka: អកក
if | then |
a/A | អ |
ā/Ā | អា |
i/I | ឥ |
ī/Ī | ឦ |
u/U | ឧ |
...o/O | ...ឱ |
k/K | ក |
G/g | គ |
...ḷ/Ḷ | ...ឡ |
if "1" ក-ឡ and "2" k-ḷ | add footer value of "2" ្+ក-ឡ |
if "1" footer value of ក-ឡ and "2" k-ḷ | add footer value of "2" ្+ក-ឡ |
if "1" អ-ឱ and "2" k-ḷ | add ក-ឡ |
if "1" ក-ឡ or footer value, and "2" a | - |
if "1" ក-ឡ or footer value, and "2" ā,i,ī,u,ū,e,o | add ា ិិ ីី ុុ ូូ េ ោ |
if "1" ក-ឡ or footer value or ិិ ុុ ោ[1], and "2" ṃ/ṁ/ŋ | add ំ |
1. | not sure if used with ū yet, maybe good to ask Nyom Cheav Villa here, but Atma thinks it's used only with short vowels |
Aramika