![]() |
![]() |
![]() |
Evolution-Data-Server Manual: Utilities (libedataserver) | ![]() |
---|---|---|---|---|
Top | Description |
struct tm; gchar * e_util_strstrcase (const gchar *haystack
,const gchar *needle
); gchar * e_util_unicode_get_utf8 (const gchar *text
,gunichar *out
); const gchar * e_util_utf8_strstrcase (const gchar *haystack
,const gchar *needle
); const gchar * e_util_utf8_strstrcasedecomp (const gchar *haystack
,const gchar *needle
); gint e_util_utf8_strcasecmp (const gchar *s1
,const gchar *s2
); gchar * e_util_utf8_remove_accents (const gchar *str
); void e_filename_make_safe (gchar *string
); gsize e_utf8_strftime (gchar *s
,gsize max
,const gchar *fmt
,const struct tm *tm
); gsize e_strftime (gchar *s
,gsize max
,const gchar *fmt
,const struct tm *tm
); const gchar * e_util_get_prefix (void
); const gchar * e_util_get_cp_prefix (void
); const gchar * e_util_get_localedir (void
); gchar * e_util_replace_prefix (const gchar *configure_time_prefix
,const gchar *runtime_prefix
,const gchar *configure_time_path
);
gchar * e_util_strstrcase (const gchar *haystack
,const gchar *needle
);
Find the first instance of needle
in haystack
, ignoring case for
bytes that are ASCII characters.
|
The string to search in. |
|
The string to search for. |
Returns : |
A pointer to the start of needle in haystack , or NULL if
needle is not found.
|
gchar * e_util_unicode_get_utf8 (const gchar *text
,gunichar *out
);
Get a UTF-8 character from the beginning of text
.
|
The string to take the UTF-8 character from. |
|
The location to store the UTF-8 character in. |
Returns : |
A pointer to the next character in text after out .
|
const gchar * e_util_utf8_strstrcase (const gchar *haystack
,const gchar *needle
);
Find the first instance of needle
in haystack
, ignoring case. (No
proper case folding or decomposing is done.) Both needle
and
haystack
are UTF-8 strings.
|
The string to search in. |
|
The string to search for. |
Returns : |
A pointer to the first instance of needle in haystack , or
NULL if no match is found, or if either of the strings are
not legal UTF-8 strings.
|
const gchar * e_util_utf8_strstrcasedecomp (const gchar *haystack
,const gchar *needle
);
Find the first instance of needle
in haystack
, where both needle
and haystack
are UTF-8 strings. Both strings are stripped and
decomposed for comparison, and case is ignored.
|
The string to search in. |
|
The string to search for. |
Returns : |
A pointer to the first instance of needle in haystack , or
NULL if either of the strings are not legal UTF-8 strings.
|
gint e_util_utf8_strcasecmp (const gchar *s1
,const gchar *s2
);
|
|
|
|
Returns : |
gchar * e_util_utf8_remove_accents (const gchar *str
);
|
|
Returns : |
newly allocates string, copy of 'str', without accents. |
Since 2.28
gsize e_utf8_strftime (gchar *s
,gsize max
,const gchar *fmt
,const struct tm *tm
);
The UTF-8 equivalent of e_strftime()
.
|
The string array to store the result in. |
|
The size of array s .
|
|
The formatting to use on tm .
|
|
The time value to format. |
Returns : |
The number of characters placed in s .
|
gsize e_strftime (gchar *s
,gsize max
,const gchar *fmt
,const struct tm *tm
);
This function is a wrapper around the strftime(3) function, which converts the %l and %k (12h and 24h) format variables if necessary.
|
The string array to store the result in. |
|
The size of array s .
|
|
The formatting to use on tm .
|
|
The time value to format. |
Returns : |
The number of characters placed in s .
|