bug-ncurses
[Top][All Lists]
Advanced

[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index]

Re: form_driver and non-ASCII-characters


From: Thomas Dickey
Subject: Re: form_driver and non-ASCII-characters
Date: Sat, 23 Apr 2005 18:35:37 -0400
User-agent: Mutt/1.5.6+20040907i

On Sun, Apr 24, 2005 at 12:10:14AM +0200, Moritz Beller wrote:
> Hi Thomas,
> 
> first of all, I want to thank you for your support so far.
> 
> Well, I have set every possible (and thinkable) combination of locales
> (I even tried a Linux live cd!), but none worked.
> As it turns out, ncurses actually is able to display and handle umlauts,
> as program init_func_example.c shows. 
> 
> The only problem arises with this form_driver-function: I'm not able to
> display one with form_driver(my_form, ch);

There are two problems:  it doesn't call setlocale().  The other is that
the ch variable in selectCommunication() should be an int rather than a
char.  That's causing it to be passed to form_driver() as -19 rather than
237 (sign-extension).  g++ warns about this because the case statement
cannot be properly matched either:

compiling demo (obj_s)
../c++/demo.cc: In function `void selectCommunication()':
../c++/demo.cc:92: warning: overflow in implicit constant conversion
../c++/demo.cc:100: warning: overflow in implicit constant conversion
../c++/demo.cc:109: warning: overflow in implicit constant conversion

-- 
Thomas E. Dickey <address@hidden>
http://invisible-island.net
ftp://invisible-island.net




reply via email to

[Prev in Thread] Current Thread [Next in Thread]