Use GetACP to get the current ANSI codepage.

2000-12-17  Tor Lillqvist  <tml@iki.fi>

	* gutf8.c (g_utf8_get_charset_internal): (Win32) Use GetACP to get
	the current ANSI codepage.

	* gunicode.h: Add comment that the static string g_get_charset
	sets the parameter to point to should be copied in case the
	charset might be changed later in the program.
This commit is contained in:
Tor Lillqvist
2000-12-17 18:43:57 +00:00
committed by Tor Lillqvist
parent a5f18bb9ba
commit 4f9e04c1d7
13 changed files with 112 additions and 4 deletions

View File

@@ -105,7 +105,9 @@ typedef enum
/* Returns TRUE if current locale uses UTF-8 charset. If CHARSET is
* not null, sets *CHARSET to the name of the current locale's
* charset. This value is statically allocated.
* charset. This value is statically allocated, and should be copied
* in case the locale's charset will be changed later using setlocale()
* or in some other way.
*/
gboolean g_get_charset (char **charset);