Commit 1bfc515a authored by Owen Taylor's avatar Owen Taylor Committed by Owen Taylor

Change ERROR_OTHER to ERROR_FAILED, add some dummy marking with _().

Mon Sep 11 10:03:24 2000  Owen Taylor  <otaylor@redhat.com>

	* glib.h convert.c (g_convert_with_fallback): Change
	ERROR_OTHER to ERROR_FAILED, add some dummy marking with _().

	* docs/reference/glib/glib-sections.txt
	docs/reference/glib/glib-docs.sgml Update for g_convert,
	g_unicode_validate.
parent e9360931
Mon Sep 11 10:03:24 2000 Owen Taylor <otaylor@redhat.com>
* glib.h convert.c (g_convert_with_fallback): Change
ERROR_OTHER to ERROR_FAILED, add some dummy marking with _().
* docs/reference/glib/glib-sections.txt
docs/reference/glib/glib-docs.sgml Update for g_convert,
g_unicode_validate.
2000-10-16 Tor Lillqvist <tml@iki.fi>
* glibconfig.h.win32.in: Remove alloca stuff from here. galloca.h
......
Mon Sep 11 10:03:24 2000 Owen Taylor <otaylor@redhat.com>
* glib.h convert.c (g_convert_with_fallback): Change
ERROR_OTHER to ERROR_FAILED, add some dummy marking with _().
* docs/reference/glib/glib-sections.txt
docs/reference/glib/glib-docs.sgml Update for g_convert,
g_unicode_validate.
2000-10-16 Tor Lillqvist <tml@iki.fi>
* glibconfig.h.win32.in: Remove alloca stuff from here. galloca.h
......
Mon Sep 11 10:03:24 2000 Owen Taylor <otaylor@redhat.com>
* glib.h convert.c (g_convert_with_fallback): Change
ERROR_OTHER to ERROR_FAILED, add some dummy marking with _().
* docs/reference/glib/glib-sections.txt
docs/reference/glib/glib-docs.sgml Update for g_convert,
g_unicode_validate.
2000-10-16 Tor Lillqvist <tml@iki.fi>
* glibconfig.h.win32.in: Remove alloca stuff from here. galloca.h
......
Mon Sep 11 10:03:24 2000 Owen Taylor <otaylor@redhat.com>
* glib.h convert.c (g_convert_with_fallback): Change
ERROR_OTHER to ERROR_FAILED, add some dummy marking with _().
* docs/reference/glib/glib-sections.txt
docs/reference/glib/glib-docs.sgml Update for g_convert,
g_unicode_validate.
2000-10-16 Tor Lillqvist <tml@iki.fi>
* glibconfig.h.win32.in: Remove alloca stuff from here. galloca.h
......
Mon Sep 11 10:03:24 2000 Owen Taylor <otaylor@redhat.com>
* glib.h convert.c (g_convert_with_fallback): Change
ERROR_OTHER to ERROR_FAILED, add some dummy marking with _().
* docs/reference/glib/glib-sections.txt
docs/reference/glib/glib-docs.sgml Update for g_convert,
g_unicode_validate.
2000-10-16 Tor Lillqvist <tml@iki.fi>
* glibconfig.h.win32.in: Remove alloca stuff from here. galloca.h
......
Mon Sep 11 10:03:24 2000 Owen Taylor <otaylor@redhat.com>
* glib.h convert.c (g_convert_with_fallback): Change
ERROR_OTHER to ERROR_FAILED, add some dummy marking with _().
* docs/reference/glib/glib-sections.txt
docs/reference/glib/glib-docs.sgml Update for g_convert,
g_unicode_validate.
2000-10-16 Tor Lillqvist <tml@iki.fi>
* glibconfig.h.win32.in: Remove alloca stuff from here. galloca.h
......
Mon Sep 11 10:03:24 2000 Owen Taylor <otaylor@redhat.com>
* glib.h convert.c (g_convert_with_fallback): Change
ERROR_OTHER to ERROR_FAILED, add some dummy marking with _().
* docs/reference/glib/glib-sections.txt
docs/reference/glib/glib-docs.sgml Update for g_convert,
g_unicode_validate.
2000-10-16 Tor Lillqvist <tml@iki.fi>
* glibconfig.h.win32.in: Remove alloca stuff from here. galloca.h
......
Mon Sep 11 10:03:24 2000 Owen Taylor <otaylor@redhat.com>
* glib.h convert.c (g_convert_with_fallback): Change
ERROR_OTHER to ERROR_FAILED, add some dummy marking with _().
* docs/reference/glib/glib-sections.txt
docs/reference/glib/glib-docs.sgml Update for g_convert,
g_unicode_validate.
2000-10-16 Tor Lillqvist <tml@iki.fi>
* glibconfig.h.win32.in: Remove alloca stuff from here. galloca.h
......
......@@ -12,6 +12,7 @@
<!entity glib-Message-Logging SYSTEM "sgml/messages.sgml">
<!entity glib-Timers SYSTEM "sgml/timers.sgml">
<!entity glib-String-Utility-Functions SYSTEM "sgml/string_utils.sgml">
<!entity glib-Character-Set-Conversion SYSTEM "sgml/conversions.sgml">
<!entity glib-Unicode-Manipulation SYSTEM "sgml/unicode.sgml">
<!entity glib-Random-Numbers SYSTEM "sgml/random_numbers.sgml">
<!entity glib-Miscellaneous-Utility-Functions SYSTEM "sgml/misc_utils.sgml">
......@@ -79,6 +80,7 @@
<chapter id="glib-utilities">
<title>GLib Utilities</title>
&glib-String-Utility-Functions;
&glib-Character-Set-Conversion;
&glib-Unicode-Manipulation;
&glib-Date-and-Time-Functions;
&glib-Random-Numbers;
......
......@@ -1521,6 +1521,17 @@ g_random_double
g_random_double_range
</SECTION>
<SECTION>
<TITLE>Character Set Conversion</TITLE>
<FILE>conversions</FILE>
g_convert
g_convert_with_fallback
G_CONVERT_ERROR
GConvertError
<SUBSECTION Private>
g_convert_error_quark
</SECTION>
<SECTION>
<TITLE>Unicode Manipulation</TITLE>
<FILE>unicode</FILE>
......@@ -1567,6 +1578,7 @@ g_utf8_strlen
g_utf8_strncpy
g_utf8_strchr
g_utf8_strrchr
g_utf8_validate
<SUBSECTION>
g_utf8_to_utf16
......
<!-- ##### SECTION Title ##### -->
Character Set Conversion
<!-- ##### SECTION Short_Description ##### -->
<!-- ##### SECTION Long_Description ##### -->
<para>
</para>
<!-- ##### SECTION See_Also ##### -->
<para>
</para>
<!-- ##### FUNCTION g_convert ##### -->
<para>
</para>
@str:
@len:
@to_codeset:
@from_codeset:
@bytes_read:
@bytes_written:
@error:
@Returns:
<!-- ##### FUNCTION g_convert_with_fallback ##### -->
<para>
</para>
@str:
@len:
@to_codeset:
@from_codeset:
@fallback:
@bytes_read:
@bytes_written:
@error:
@Returns:
<!-- ##### MACRO G_CONVERT_ERROR ##### -->
<para>
</para>
<!-- ##### ENUM GConvertError ##### -->
<para>
</para>
@G_CONVERT_ERROR_NO_CONVERSION:
@G_CONVERT_ERROR_ILLEGAL_SEQUENCE:
@G_CONVERT_ERROR_FAILED:
......@@ -15,6 +15,24 @@ Specifies the type of function passed to g_tree_search().
desired key comes before @key in the sort order of the #GTree, or a positive
value if the desired key comes after @key.
<!-- ##### FUNCTION g_node_insert_after ##### -->
<para>
Inserts a #GNode beneath the parent after the given sibling.
</para>
@parent: the #GNode to place @node under.
@sibling: the sibling #GNode to place @node after. If sibling is NULL,
the node is inserted as the first child of @parent.
@node: the #GNode to insert.
@Returns: the inserted #GNode.
<!-- ##### FUNCTION g_convert_error_quark ##### -->
<para>
</para>
@Returns:
<!-- ##### MACRO write ##### -->
<para>
......
......@@ -113,18 +113,6 @@ the node is inserted as the last child of @parent.
@Returns: the inserted #GNode.
<!-- ##### FUNCTION g_node_insert_after ##### -->
<para>
Inserts a #GNode beneath the parent after the given sibling.
</para>
@parent: the #GNode to place @node under.
@sibling: the sibling #GNode to place @node after. If sibling is NULL,
the node is inserted as the first child of @parent.
@node: the #GNode to insert.
@Returns: the inserted #GNode.
<!-- ##### MACRO g_node_append ##### -->
<para>
Inserts a #GNode as the last child of the given parent.
......
......@@ -383,6 +383,19 @@ Unicode Manipulation
@ch:
<!-- ##### FUNCTION g_utf8_validate ##### -->
<para>
</para>
@str:
@max_len:
@end:
@Returns:
<!-- # Unused Parameters # -->
@len:
<!-- ##### FUNCTION g_utf8_to_utf16 ##### -->
<para>
......
......@@ -26,6 +26,8 @@
#include "glib.h"
#define _(s) (s)
GQuark
g_convert_error_quark()
{
......@@ -47,11 +49,11 @@ open_converter (const gchar *to_codeset,
/* Something went wrong. */
if (errno == EINVAL)
g_set_error (error, G_CONVERT_ERROR, G_CONVERT_ERROR_NO_CONVERSION,
"Conversion from character set `%s' to `%s' is not supported",
_("Conversion from character set `%s' to `%s' is not supported"),
from_codeset, to_codeset);
else
g_set_error (error, G_CONVERT_ERROR, G_CONVERT_ERROR_FAILED,
"Could not open converter from `%s' to `%s': %s",
_("Could not open converter from `%s' to `%s': %s"),
from_codeset, to_codeset, strerror (errno));
}
......@@ -73,6 +75,8 @@ open_converter (const gchar *to_codeset,
* G_CONVERT_ERROR_ILLEGAL_SEQUENCE occurs, the value
* stored will the byte fofset after the last valid
* input sequence.
* @bytes_written: the stored in the output buffer (not including the
* terminating nul.
* @error: location to store the error occuring, or %NULL to ignore
* errors. Any of the errors in #GConvertError may occur.
*
......@@ -151,12 +155,12 @@ g_convert (const gchar *str,
}
case EILSEQ:
g_set_error (error, G_CONVERT_ERROR, G_CONVERT_ERROR_ILLEGAL_SEQUENCE,
"Invalid byte sequence in conversion input");
_("Invalid byte sequence in conversion input"));
have_error = TRUE;
break;
default:
g_set_error (error, G_CONVERT_ERROR, G_CONVERT_ERROR_FAILED,
"Error during conversion: %s",
_("Error during conversion: %s"),
strerror (errno));
have_error = TRUE;
break;
......@@ -201,6 +205,8 @@ g_convert (const gchar *str,
* G_CONVERT_ERROR_ILLEGAL_SEQUENCE occurs, the value
* stored will the byte fofset after the last valid
* input sequence.
* @bytes_written: the stored in the output buffer (not including the
* terminating nul.
* @error: location to store the error occuring, or %NULL to ignore
* errors. Any of the errors in #GConvertError may occur.
*
......@@ -329,7 +335,7 @@ g_convert_with_fallback (const gchar *str,
/* Error converting fallback string - fatal
*/
g_set_error (error, G_CONVERT_ERROR, G_CONVERT_ERROR_ILLEGAL_SEQUENCE,
"Cannot convert fallback '%s' to codeset '%s'",
_("Cannot convert fallback '%s' to codeset '%s'"),
insert_str, to_codeset);
have_error = TRUE;
break;
......@@ -354,7 +360,7 @@ g_convert_with_fallback (const gchar *str,
break;
default:
g_set_error (error, G_CONVERT_ERROR, G_CONVERT_ERROR_FAILED,
"Error during conversion: %s",
_("Error during conversion: %s"),
strerror (errno));
have_error = TRUE;
break;
......
......@@ -26,6 +26,8 @@
#include "glib.h"
#define _(s) (s)
GQuark
g_convert_error_quark()
{
......@@ -47,11 +49,11 @@ open_converter (const gchar *to_codeset,
/* Something went wrong. */
if (errno == EINVAL)
g_set_error (error, G_CONVERT_ERROR, G_CONVERT_ERROR_NO_CONVERSION,
"Conversion from character set `%s' to `%s' is not supported",
_("Conversion from character set `%s' to `%s' is not supported"),
from_codeset, to_codeset);
else
g_set_error (error, G_CONVERT_ERROR, G_CONVERT_ERROR_FAILED,
"Could not open converter from `%s' to `%s': %s",
_("Could not open converter from `%s' to `%s': %s"),
from_codeset, to_codeset, strerror (errno));
}
......@@ -73,6 +75,8 @@ open_converter (const gchar *to_codeset,
* G_CONVERT_ERROR_ILLEGAL_SEQUENCE occurs, the value
* stored will the byte fofset after the last valid
* input sequence.
* @bytes_written: the stored in the output buffer (not including the
* terminating nul.
* @error: location to store the error occuring, or %NULL to ignore
* errors. Any of the errors in #GConvertError may occur.
*
......@@ -151,12 +155,12 @@ g_convert (const gchar *str,
}
case EILSEQ:
g_set_error (error, G_CONVERT_ERROR, G_CONVERT_ERROR_ILLEGAL_SEQUENCE,
"Invalid byte sequence in conversion input");
_("Invalid byte sequence in conversion input"));
have_error = TRUE;
break;
default:
g_set_error (error, G_CONVERT_ERROR, G_CONVERT_ERROR_FAILED,
"Error during conversion: %s",
_("Error during conversion: %s"),
strerror (errno));
have_error = TRUE;
break;
......@@ -201,6 +205,8 @@ g_convert (const gchar *str,
* G_CONVERT_ERROR_ILLEGAL_SEQUENCE occurs, the value
* stored will the byte fofset after the last valid
* input sequence.
* @bytes_written: the stored in the output buffer (not including the
* terminating nul.
* @error: location to store the error occuring, or %NULL to ignore
* errors. Any of the errors in #GConvertError may occur.
*
......@@ -329,7 +335,7 @@ g_convert_with_fallback (const gchar *str,
/* Error converting fallback string - fatal
*/
g_set_error (error, G_CONVERT_ERROR, G_CONVERT_ERROR_ILLEGAL_SEQUENCE,
"Cannot convert fallback '%s' to codeset '%s'",
_("Cannot convert fallback '%s' to codeset '%s'"),
insert_str, to_codeset);
have_error = TRUE;
break;
......@@ -354,7 +360,7 @@ g_convert_with_fallback (const gchar *str,
break;
default:
g_set_error (error, G_CONVERT_ERROR, G_CONVERT_ERROR_FAILED,
"Error during conversion: %s",
_("Error during conversion: %s"),
strerror (errno));
have_error = TRUE;
break;
......
......@@ -188,7 +188,7 @@ gint g_unichar_to_utf8 (gunichar c,
*/
gboolean g_utf8_validate (const gchar *str,
gint len,
gint max_len,
const gchar **end);
G_END_DECLS
......
......@@ -188,7 +188,7 @@ gint g_unichar_to_utf8 (gunichar c,
*/
gboolean g_utf8_validate (const gchar *str,
gint len,
gint max_len,
const gchar **end);
G_END_DECLS
......
Markdown is supported
0% or
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment