GetChar bug on Linux

Archives Forums/BlitzMax Bug Reports/GetChar bug on Linux

SLotman(Posted 2009) [#1]
Example code:
Graphics 640,480,0

Local key:Int
Local char:String
Repeat
	Cls
	key=GetChar()
	If key>32 Then char=Chr$(key)
	DrawText char,10,10
	Flip
Until KeyHit(KEY_ESCAPE)


This on Windows returns correctly chars like "ç", "Ç", "á", "É", etc - commonly used in Brazilian names/words.

But on Linux, pressing those keys on the keyboard shows nothing at all (only on Blitzmax, on other programs it works normally).

I really need a fix for this, since I need to read players names on my game.

Have anyone experienced such thing? Is there a work-around?

I just saw on pub.stdc that it just redirects to C "getchar"... this one will be a tough one to fix :(


SLotman(Posted 2009) [#2]
Just found one thing: "ç" is returning a negative number...! -25 instead of 231.

Fixing the byte-int problem just got me "ç" working. But accented characters aren't.