Mercurial > pidgin
diff src/util.h @ 8341:fec4c1fb2ac8
[gaim-migrate @ 9065]
Alright, I had to lay down a little bit of smack. Here goes:
-Work around the rate-limit problem caused by Gaim auto-requesting
away messages too quickly. Basically there is now a 1.2sec gap
between each request. The downside is that it takes a bit longer
for Gaim to get everyone's away message initially. Adium shouldn't
need to do anything to take advantage of this. Fire (they use
libfaim, right?) will need to add a callback for
AIM_CB_LOC_REQUESTINFOTIMEOUT. Just search oscar.c for
gaim_reqinfo_timeout() and copy what that thing does.
-Attempt to do a better job showing away messages in tooltips.
Hopefully & and greater than and less than will show up correctly
now. I don't think there should be any side effects, but if you
mouse over someone and it crashes or you get a pango error let me know.
-Remove/combine some silly functions in util.c that few things use.
committer: Tailor Script <tailor@pidgin.im>
author | Mark Doliner <mark@kingant.net> |
---|---|
date | Thu, 26 Feb 2004 08:29:32 +0000 |
parents | da57fb60680a |
children | 33cc36f5a7a6 |
line wrap: on
line diff
--- a/src/util.h Thu Feb 26 07:22:47 2004 +0000 +++ b/src/util.h Thu Feb 26 08:29:32 2004 +0000 @@ -409,41 +409,14 @@ const char *gaim_str_sub_away_formatters(const char *str, const char *name); /** - * Copies a string and replaces all HTML linebreaks with newline characters. - * - * @param dest The destination string. - * @param src The source string. - * @param dest_len The destination string length. - * - * @see gaim_strncpy_withhtml() - * @see gaim_strdup_withhtml() - */ -void gaim_strncpy_nohtml(char *dest, const char *src, size_t dest_len); - -/** - * Copies a string and replaces all newline characters with HTML linebreaks. - * - * @param dest The destination string. - * @param src The source string. - * @param dest_len The destination string length. - * - * @see gaim_strncpy_nohtml() - * @see gaim_strdup_withhtml() - */ -void gaim_strncpy_withhtml(gchar *dest, const gchar *src, size_t dest_len); - -/** * Duplicates a string and replaces all newline characters from the * source string with HTML linebreaks. * * @param src The source string. * - * @return The new string. - * - * @see gaim_strncpy_nohtml() - * @see gaim_strncpy_withhtml() + * @return The new string. Must be g_free'd by the caller. */ -char *gaim_strdup_withhtml(const char *src); +gchar *gaim_strdup_withhtml(const gchar *src); /** * Ensures that all linefeeds have a matching carriage return. @@ -470,8 +443,20 @@ * @param replacement The substring you want inserted in place * of the delimiting substring. */ -char *gaim_strreplace(const char *string, const char *delimiter, - const char *replacement); +gchar *gaim_strreplace(const char *string, const char *delimiter, + const char *replacement); + +/** + * Given a string, this replaces one substring with another + * ignoring case and returns a newly allocated string. + * + * @param string The string from which to replace stuff. + * @param delimiter The substring you want replaced. + * @param replacement The substring you want inserted in place + * of the delimiting substring. + */ +gchar *gaim_strcasereplace(const char *string, const char *delimiter, + const char *replacement); /** * This is like strstr, except that it ignores ASCII case in