mscdex / node-ncurses

An ncurses binding for node.js
MIT License
385 stars 25 forks source link

printing special chars does not work #52

Closed calledit closed 10 years ago

calledit commented 10 years ago

Example: console.log("It’s free and always will be.");

that works fine i get the exact same stuff in the console.

w.print("It’s free and always will be.");

Prints like this: It�~@~Ys free and always will be.

So ncurses or something in the bindings are somehow altering the bytes in the text. How can i disable that.

calledit commented 10 years ago

OK so adding: the folowing to the js files makes it work sl = require('setlocale'); sl.setlocale(sl.LC_ALL, '');