Reading UTF-8 encoded text file



hi all,
 
I have a file that is an UTF-8 encoded text file. I would like to read
it line by line and place the lines in GString.
My idea was using standard library calls (such us fgets) for file
manipulation and reading the lines to a char* buffer, and then some glib
API calls to place these strings into a GString (e.g I've tried
g_string_new). Unfortunately there is something wrong as I'm unable to
have the correct UTF-8 strings in the GStrings, it seems that the data
is converted somewhere.
 
I would really appreciate any suggestions about which API calls should I
use.
 
thanks,
mami
 
 



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