SPBytes Posted March 5, 2021 Report Share Posted March 5, 2021 Is there a way to make this tool compatible with Arabic? Quote Link to comment Share on other sites More sharing options...
Jim Kring Posted March 5, 2021 Report Share Posted March 5, 2021 I haven't tried, but I would assume that it already is compatible with Arabic. There's a documentation guide here to help you out: https://github.com/JKISoftware/JKI-Simple-Localization/wiki Please let us know how this works for you. Quote Link to comment Share on other sites More sharing options...
SPBytes Posted March 5, 2021 Author Report Share Posted March 5, 2021 I have had success with Chinese and Russian. I am applying the same method for Arabic that is outlined in the documentation that you linked. The Windows locale setting for Chinese(Simplified) works for both Russian and Chinese. When I apply any Arabic setting I get the screenshot above. I have tried different Unicode file encoding methods and applied them directly to the Read Unicode File vi but always got the same strings for Arabic. I attached my vi and json file. Dictionary.JSON Language Selection.vi Quote Link to comment Share on other sites More sharing options...
Jim Kring Posted March 6, 2021 Report Share Posted March 6, 2021 Thanks for clarifying all the different things you’ve tried. I’m sorry that the instructions aren’t working correctly for Arabic. I don’t have any experience getting this tool working for Arabic, so I haven’t run up against this problem. I’ll ask some of my colleagues if they know anything about it Quote Link to comment Share on other sites More sharing options...
SPBytes Posted March 9, 2021 Author Report Share Posted March 9, 2021 As an update, I have been applying the file directly to the unicodeStringtoASCIIJKI_Simple_Localization.vi. Arabic gets translated to ASCII correctly as shown in the screenshots. Maybe a kernel32.dll function needs to be updated. Hopefully I find something and I will post it on this thread. 2 Quote Link to comment Share on other sites More sharing options...
Jim Kring Posted March 15, 2021 Report Share Posted March 15, 2021 Thanks for the update. I haven't looked into it deeply, but I found a couple links that seem informative: https://stackoverflow.com/questions/10715001/bstr-to-cstring-conversion-for-arabic-text http://www.delphigroups.info/2/f5/481372.html If you're able to figure this out, it would be a great improvement to the library. Quote Link to comment Share on other sites More sharing options...
SPBytes Posted March 16, 2021 Author Report Share Posted March 16, 2021 One thing I didn't notice before, the library will only accept UTF-8 without signature. When a file is ran through with this encoding the file is accepted as an ASCII string through 'readUnicodeFileJKI_Simple_Localization.vi'. This works for Chinese and Russian, not for Arabic. If I try any other form of Unicode file encoding on the json file, the file will go through 'unicodeStringtoASCIIJKI_Simple_Localization.vi' that uses the WideCharToMultiByte function. It will however fail at 'JKI JSON Serilization.lvlib:Unflatten From String.vi' which is the subsequent vi. Basically, I have found that anytime that 'unicodeStringtoASCIIJKI_Simple_Localization.vi' conditions are met, the 'JKI JSON Serilization.lvlib:Unflatten From String.vi' generates an error. 1 Quote Link to comment Share on other sites More sharing options...
Jim Kring Posted March 18, 2021 Report Share Posted March 18, 2021 Thanks for that info. Just to be clear: Is this a separate issue or does changing to "UTF-8 without signature" fix the original issue? Quote Link to comment Share on other sites More sharing options...
SPBytes Posted March 24, 2021 Author Report Share Posted March 24, 2021 This is a separate issue. The file passing as "UTF-8 without signature" gets recognized as ASCII but still works for Chinese and Russian, not for Arabic. 1 Quote Link to comment Share on other sites More sharing options...
Recommended Posts
Join the conversation
You can post now and register later. If you have an account, sign in now to post with your account.