public static Chr UnicodeCharByCode(string text) { int ch = (Chr.Hex(text[1]) << 12) + (Chr.Hex(text[2]) << 8) + (Chr.Hex(text[3]) << 4) + Chr.Hex(text[4]) ; return(new Chr((char)ch)); }
public static QStr UnicodeSurrogateByCode(string text) { int value = (Chr.Hex(text[1]) << 28) + (Chr.Hex(text[2]) << 24) + (Chr.Hex(text[3]) << 20) + (Chr.Hex(text[4]) << 16) + (Chr.Hex(text[5]) << 12) + (Chr.Hex(text[6]) << 8) + (Chr.Hex(text[7]) << 4) + Chr.Hex(text[8]) ; return(new QStr(char.ConvertFromUtf32(value))); }