NathanaelA / nativescript-zxing

ZXing for NativeScript
Other
15 stars 22 forks source link

does not supporting Persian text(unicode not supported) #11

Closed davidjonz2005 closed 6 years ago

davidjonz2005 commented 7 years ago

Hi @NathanaelA
i created a qrcode and my text is Persian but i see just a string of ? when decoding in my phone. do i need to add something to my code to support Persian?

davidjonz2005 commented 7 years ago

thanks to this link i just add this lines to your code and everything solved

add it to zxing.android.js at line 39 clean

var hints = null;

and put

var hints = new java.util.Hashtable();
    var characterset = com.google.zxing.EncodeHintType.CHARACTER_SET;
    hints.put(characterset, "utf-8");

instead for ios currently i dont know maybe @NathanaelA helps.

kalininskiy commented 6 years ago

same problem with Cyrillic fonts @NathanaelA please add hints solution with UTF-8 to project

NathanaelA commented 6 years ago

The pull request was accepted and the latest version on NPM has this change...