fix case conversion for non-ASCII characters

Fixes #42
It's a workaround for scintilla bug.
See details in the comment in source code.