I couldn't sleep this night, so I surfed some local sites. Yes, there
is a local PowerPro site, and I found that local AutoHotkey site also
exists. And I noticed some interesting post there, about sending keys
as unicode. This could be an invaluable option to the double-byte
character users. BTW, this option exists for ages in SendInput, so I
looked at the code although I know little about AutoHotkey. It seems
like a mess to me, it doesn't have struct to be used in DllCall.
Anyway, I thought it could be easily done in PP with dll plugin, and
indeed it took just half an hour including tests.
-------------------- SendUnicode.PowerPro -----------------------------
local sString,wString,nSize
sString=?"ÇÑ±Û test"
nSize=dll.call("MultiByteToWideChar|ui ui s i s i",0,0;;+
,"sString",-1,"wString",0)
dll.call("MultiByteToWideChar|ui ui s i s"++nSize*2++" i",0,0;;+
,"sString",-1,"wString",nSize)
nSize--
local ptr=dll.get_pointer("wString")
local ki=dll.create_array(7*2*nSize,"i")
for(local i=0;i<2*nSize;i++)
ki[1+7*i]=1
ki[3+7*i]=4+i%2*2
dll.call("RtlMoveMemory|ui ui ui",ki.get_pointer(2+7*i)+2,ptr+i/2*2,2)
endfor
dll.call("SendInput|ui a* i",2*nSize,ki,28)
quit
-----------------------------------------------------------------------
Sean