mirror of
https://github.com/weechat/weechat.git
synced 2026-07-06 17:53:13 +02:00
api: rename char comparison functions "utf8_char*" to "string_char*"
This commit is contained in:
@@ -605,6 +605,8 @@ plugin_load (const char *filename, int init_plugin, int argc, char **argv)
|
||||
new_plugin->string_cut = &string_cut;
|
||||
new_plugin->string_tolower = &string_tolower;
|
||||
new_plugin->string_toupper = &string_toupper;
|
||||
new_plugin->string_charcmp = &string_charcmp;
|
||||
new_plugin->string_charcasecmp = &string_charcasecmp;
|
||||
new_plugin->strcasecmp = &string_strcasecmp;
|
||||
new_plugin->strcasecmp_range = &string_strcasecmp_range;
|
||||
new_plugin->strncasecmp = &string_strncasecmp;
|
||||
@@ -658,8 +660,6 @@ plugin_load (const char *filename, int init_plugin, int argc, char **argv)
|
||||
new_plugin->utf8_strlen = &utf8_strlen;
|
||||
new_plugin->utf8_strnlen = &utf8_strnlen;
|
||||
new_plugin->utf8_strlen_screen = &utf8_strlen_screen;
|
||||
new_plugin->utf8_charcmp = &utf8_charcmp;
|
||||
new_plugin->utf8_charcasecmp = &utf8_charcasecmp;
|
||||
new_plugin->utf8_char_size_screen = &utf8_char_size_screen;
|
||||
new_plugin->utf8_add_offset = &utf8_add_offset;
|
||||
new_plugin->utf8_real_pos = &utf8_real_pos;
|
||||
|
||||
@@ -701,7 +701,7 @@ trigger_regex_split (const char *str_regex,
|
||||
|
||||
/* search the delimiter (which can be more than one char) */
|
||||
pos = weechat_utf8_next_char (ptr_regex);
|
||||
while (pos[0] && (weechat_utf8_charcmp (ptr_regex, pos) == 0))
|
||||
while (pos[0] && (weechat_string_charcmp (ptr_regex, pos) == 0))
|
||||
{
|
||||
pos = weechat_utf8_next_char (pos);
|
||||
}
|
||||
|
||||
@@ -68,7 +68,7 @@ struct timeval;
|
||||
* please change the date with current one; for a second change at same
|
||||
* date, increment the 01, otherwise please keep 01.
|
||||
*/
|
||||
#define WEECHAT_PLUGIN_API_VERSION "20221218-01"
|
||||
#define WEECHAT_PLUGIN_API_VERSION "20221224-01"
|
||||
|
||||
/* macros for defining plugin infos */
|
||||
#define WEECHAT_PLUGIN_NAME(__name) \
|
||||
@@ -289,6 +289,8 @@ struct t_weechat_plugin
|
||||
int screen, const char *cut_suffix);
|
||||
char *(*string_tolower) (const char *string);
|
||||
char *(*string_toupper) (const char *string);
|
||||
int (*string_charcmp) (const char *string1, const char *string2);
|
||||
int (*string_charcasecmp) (const char *string1, const char *string2);
|
||||
int (*strcasecmp) (const char *string1, const char *string2);
|
||||
int (*strcasecmp_range) (const char *string1, const char *string2,
|
||||
int range);
|
||||
@@ -372,8 +374,6 @@ struct t_weechat_plugin
|
||||
int (*utf8_strlen) (const char *string);
|
||||
int (*utf8_strnlen) (const char *string, int bytes);
|
||||
int (*utf8_strlen_screen) (const char *string);
|
||||
int (*utf8_charcmp) (const char *string1, const char *string2);
|
||||
int (*utf8_charcasecmp) (const char *string1, const char *string2);
|
||||
int (*utf8_char_size_screen) (const char *string);
|
||||
const char *(*utf8_add_offset) (const char *string, int offset);
|
||||
int (*utf8_real_pos) (const char *string, int pos);
|
||||
@@ -1229,6 +1229,10 @@ extern int weechat_plugin_end (struct t_weechat_plugin *plugin);
|
||||
(weechat_plugin->string_tolower)(__string)
|
||||
#define weechat_string_toupper(__string) \
|
||||
(weechat_plugin->string_toupper)(__string)
|
||||
#define weechat_string_charcmp(__string1, __string2) \
|
||||
(weechat_plugin->string_charcmp)(__string1, __string2)
|
||||
#define weechat_string_charcasecmp(__string1, __string2) \
|
||||
(weechat_plugin->string_charcasecmp)(__string1, __string2)
|
||||
#define weechat_strcasecmp(__string1, __string2) \
|
||||
(weechat_plugin->strcasecmp)(__string1, __string2)
|
||||
#define weechat_strcasecmp_range(__string1, __string2, __range) \
|
||||
@@ -1365,10 +1369,6 @@ extern int weechat_plugin_end (struct t_weechat_plugin *plugin);
|
||||
(weechat_plugin->utf8_strnlen)(__string, __bytes)
|
||||
#define weechat_utf8_strlen_screen(__string) \
|
||||
(weechat_plugin->utf8_strlen_screen)(__string)
|
||||
#define weechat_utf8_charcmp(__string1, __string2) \
|
||||
(weechat_plugin->utf8_charcmp)(__string1, __string2)
|
||||
#define weechat_utf8_charcasecmp(__string1, __string2) \
|
||||
(weechat_plugin->utf8_charcasecmp)(__string1, __string2)
|
||||
#define weechat_utf8_char_size_screen(__string) \
|
||||
(weechat_plugin->utf8_char_size_screen)(__string)
|
||||
#define weechat_utf8_add_offset(__string, __offset) \
|
||||
|
||||
Reference in New Issue
Block a user