nodes7 icon indicating copy to clipboard operation
nodes7 copied to clipboard

Problem with encoding on accessing STRING and CHAR

Open pmamod opened this issue 3 years ago • 0 comments

In v1.0.1 you have implemented the fixed encoding 'ascii' which unfortunately only use 7 bits per character. So any char code above 0x7f will be read as an ascii code and the information of bit 7 is lost. My proposal is to integrate a support for more encodings: The default encoding for STRING and CHAR should be 'latin1' (equal to 'binary') which handles all 8 bits. For unicode I think the use of other keywords could be a solution: for example USTRING and UCHAR with 'utf8' encoding, WSTRING and WCHAR with 'ucs2' encoding (which meens WideString & WideChar like defined in MS Windows) What do you think about this? If you like I could modify the code of s7items.js an send you as a proposal. Looking forward to your answer.

pmamod avatar Jan 26 '21 12:01 pmamod