added this function

2001-03-19  Havoc Pennington  <hp@redhat.com>

	* gutf8.c (g_unichar_validate): added this function
This commit is contained in:
Havoc Pennington 2001-03-20 00:55:44 +00:00 committed by Havoc Pennington
parent 3b2f870fdf
commit fad8693b76
12 changed files with 68 additions and 2 deletions

View File

@ -1,3 +1,7 @@
2001-03-19 Havoc Pennington <hp@redhat.com>
* gutf8.c (g_unichar_validate): added this function
2001-03-18 Tor Lillqvist <tml@iki.fi>
* gspawn-win32.c (SETUP_DEBUG): Add braces to silence gcc -Wall.

View File

@ -1,3 +1,7 @@
2001-03-19 Havoc Pennington <hp@redhat.com>
* gutf8.c (g_unichar_validate): added this function
2001-03-18 Tor Lillqvist <tml@iki.fi>
* gspawn-win32.c (SETUP_DEBUG): Add braces to silence gcc -Wall.

View File

@ -1,3 +1,7 @@
2001-03-19 Havoc Pennington <hp@redhat.com>
* gutf8.c (g_unichar_validate): added this function
2001-03-18 Tor Lillqvist <tml@iki.fi>
* gspawn-win32.c (SETUP_DEBUG): Add braces to silence gcc -Wall.

View File

@ -1,3 +1,7 @@
2001-03-19 Havoc Pennington <hp@redhat.com>
* gutf8.c (g_unichar_validate): added this function
2001-03-18 Tor Lillqvist <tml@iki.fi>
* gspawn-win32.c (SETUP_DEBUG): Add braces to silence gcc -Wall.

View File

@ -1,3 +1,7 @@
2001-03-19 Havoc Pennington <hp@redhat.com>
* gutf8.c (g_unichar_validate): added this function
2001-03-18 Tor Lillqvist <tml@iki.fi>
* gspawn-win32.c (SETUP_DEBUG): Add braces to silence gcc -Wall.

View File

@ -1,3 +1,7 @@
2001-03-19 Havoc Pennington <hp@redhat.com>
* gutf8.c (g_unichar_validate): added this function
2001-03-18 Tor Lillqvist <tml@iki.fi>
* gspawn-win32.c (SETUP_DEBUG): Add braces to silence gcc -Wall.

View File

@ -1,3 +1,7 @@
2001-03-19 Havoc Pennington <hp@redhat.com>
* gutf8.c (g_unichar_validate): added this function
2001-03-18 Tor Lillqvist <tml@iki.fi>
* gspawn-win32.c (SETUP_DEBUG): Add braces to silence gcc -Wall.

View File

@ -1,3 +1,7 @@
2001-03-19 Havoc Pennington <hp@redhat.com>
* gutf8.c (g_unichar_validate): added this function
2001-03-18 Tor Lillqvist <tml@iki.fi>
* gspawn-win32.c (SETUP_DEBUG): Add braces to silence gcc -Wall.

View File

@ -243,6 +243,9 @@ gboolean g_utf8_validate (const gchar *str,
gint max_len,
const gchar **end);
/* Validate a Unicode character */
gboolean g_unichar_validate (gunichar ch);
G_END_DECLS
#endif /* __G_UNICODE_H__ */

View File

@ -1414,4 +1414,18 @@ g_utf8_validate (const gchar *str,
return TRUE;
}
/**
* g_unichar_validate:
* @ch: a Unicode character
*
* Checks whether @ch is a valid Unicode character. Some possible
* integer values of @ch will not be valid. 0 is considered a valid
* character, though it's normally a string terminator.
*
* Return value: %TRUE if @ch is a valid Unicode character
**/
gboolean
g_unichar_validate (gunichar ch)
{
return UNICODE_VALID (ch);
}

View File

@ -243,6 +243,9 @@ gboolean g_utf8_validate (const gchar *str,
gint max_len,
const gchar **end);
/* Validate a Unicode character */
gboolean g_unichar_validate (gunichar ch);
G_END_DECLS
#endif /* __G_UNICODE_H__ */

16
gutf8.c
View File

@ -1414,4 +1414,18 @@ g_utf8_validate (const gchar *str,
return TRUE;
}
/**
* g_unichar_validate:
* @ch: a Unicode character
*
* Checks whether @ch is a valid Unicode character. Some possible
* integer values of @ch will not be valid. 0 is considered a valid
* character, though it's normally a string terminator.
*
* Return value: %TRUE if @ch is a valid Unicode character
**/
gboolean
g_unichar_validate (gunichar ch)
{
return UNICODE_VALID (ch);
}