- Unicode chr
- Char list generator
Code: Select all
;PB 4.4+
;// you must enable the following option : Create UNICODE executable
CompilerIf #PB_Compiler_Unicode
Procedure.s UnicodeCharList(first.U, last.U)
If first>=0 And first<=last
Protected len.i=last-first+1
Protected charlist.s=Space(len)
Protected i.i
For i=0 To len-1
PokeU(@charlist+i*SizeOf(Character), first+i)
Next
ProcedureReturn charlist
EndIf
EndProcedure
Procedure.s UChr(code.U)
If code>=0 And code<65536
Protected unicodeChar.s=" "
PokeU(@unicodeChar, code)
ProcedureReturn unicodeChar
EndIf
EndProcedure
CompilerElse
MessageRequester("Warning", "You didn't compile an UNICODE executable!", #PB_MessageRequester_Ok)
End
CompilerEndIf
MessageRequester("UNICODE STRING GENERATOR "+UChr(200), UnicodeCharList(31, 1024))