Re: view cant' show special characters (at least not with gtk_text_buffer_set_text() so far)



You have to UTF8 encode the characters. E.g. to input the characters
you mention below you have to insert the following char* buf:

    "\327\224 \327\226 \327\252 \327\224 \327\232 \327\233\n"

This buffer was created by doing:

 echo ä  æ ú ä ê ë | iconv -f iso8859-8 -t utf8 | od -c
 
and reformatting the output a bit.

Regards,
Dov

On Wed, May 15, 2002 at 03:12:42PM +0200, calmar wrote:
> hi, 
> 
> my problem is actually:
> 
> i have a gtk_text_view_new() in my program
> and i want to put there some text with this function:
> gtk_text_buffer_set_text ();
> 
> as long as i have normal characters in the buffer, it's works properly.
> when there are any special letters (which tend to be everywhere unless
> in
> english i guess (something like this: ä  æ ú ä ê ë ), it won't put the
> buffer to the text view anymore..it's just empty.
> 
> Maybe someone could give me some hints ..
> thanks a lot!
> calmar
> 
> 
> 
> 
> 
> 
> 
> 
> 
> 
> 
> 
> 
> 
> 
> 
> 
>  



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