Added new functions g_strstr_len, g_strrstr and g_strrstr_len

2001-06-08  Alex Larsson  <alexl@redhat.com>

	* gstrfuncs.[ch]:
	Added new functions g_strstr_len, g_strrstr and g_strrstr_len

	* tests/strfunc-test.c:
	Add some tests for the new functions.

	* gunicode.h:
	* gutf8.c:
	Add length argument to g_utf8_strchr and g_utf8_strrchr.
This commit is contained in:
Alex Larsson
2001-06-08 23:14:03 +00:00
committed by Alexander Larsson
parent 6858b5342f
commit 106fb627f1
17 changed files with 449 additions and 27 deletions

View File

@@ -60,6 +60,15 @@ gsize g_strlcpy (gchar *dest,
gsize g_strlcat (gchar *dest,
const gchar *src,
gsize dest_size);
gchar * g_strstr_len (const gchar *haystack,
gint haystack_len,
const gchar *needle);
gchar * g_strrstr (const gchar *haystack,
const gchar *needle);
gchar * g_strrstr_len (const gchar *haystack,
gint haystack_len,
const gchar *needle);
/* removes leading spaces */
gchar* g_strchug (gchar *string);
/* removes trailing spaces */