diff options
author | Sébastien Helleu <flashcode@flashtux.org> | 2024-04-29 19:22:57 +0200 |
---|---|---|
committer | Sébastien Helleu <flashcode@flashtux.org> | 2024-04-29 19:22:57 +0200 |
commit | ded599b272e94763a3f5477e43ec32bec7080f0d (patch) | |
tree | af3c98f2f4a0c5eaae8e5503a3b6cfd1334f398e /doc/sr | |
parent | 6c706caa5064b0f8af78483c4203b2f9aab1e00e (diff) | |
download | weechat-ded599b272e94763a3f5477e43ec32bec7080f0d.zip |
api: allow search by group and nick id in functions nicklist_search_group and nicklist_search_nick (issue #2081)
Diffstat (limited to 'doc/sr')
-rw-r--r-- | doc/sr/weechat_plugin_api.sr.adoc | 36 |
1 files changed, 26 insertions, 10 deletions
diff --git a/doc/sr/weechat_plugin_api.sr.adoc b/doc/sr/weechat_plugin_api.sr.adoc index 8edefa060..3d1fb9bc9 100644 --- a/doc/sr/weechat_plugin_api.sr.adoc +++ b/doc/sr/weechat_plugin_api.sr.adoc @@ -15085,7 +15085,10 @@ group = weechat.nicklist_add_group(my_buffer, my_parent_group, "test_group", ==== nicklist_search_group -Тражи групу у листи надимака. +_Ажурирано у верзији 4.3.0._ + +// TRANSLATION MISSING +Search a group in a nicklist by name or unique identifier (`id`). Прототип: @@ -15100,7 +15103,9 @@ struct t_gui_nick_group *weechat_nicklist_search_group (struct t_gui_buffer *buf * _buffer_: показивач на бафер * _from_group_: тражи само од ове групе, ако је NULL, онда се претражује цела листа надимака -* _name_: име групе која се тражи +// TRANSLATION MISSING +* _name_: group name to search; with WeeChat ≥ 4.3.0, a unique identifier can + be given with the format: `==id:xxx` (where `xxx` is the identifier) Повратна вредност: @@ -15110,8 +15115,10 @@ C пример: [source,c] ---- -struct t_gui_nick_group *ptr_group = weechat_nicklist_search_group (my_buffer, - NULL, "test_group"); +struct t_gui_nick_group *ptr_group1 = weechat_nicklist_search_group (my_buffer, + NULL, "test_group"); +struct t_gui_nick_group *ptr_group2 = weechat_nicklist_search_group (my_buffer, + NULL, "==id:1714382231198764"); ---- Скрипта (Python): @@ -15122,7 +15129,8 @@ struct t_gui_nick_group *ptr_group = weechat_nicklist_search_group (my_buffer, def nicklist_search_group(buffer: str, from_group: str, name: str) -> str: ... # пример -group = weechat.nicklist_search_group(my_buffer, "", "test_group") +group1 = weechat.nicklist_search_group(my_buffer, "", "test_group") +group2 = weechat.nicklist_search_group(my_buffer, "", "==id:1714382231198764") ---- ==== nicklist_add_nick @@ -15199,7 +15207,10 @@ nick = weechat.nicklist_add_nick(my_buffer, my_group, "test_nick", color, "@", " ==== nicklist_search_nick -Тражи надимак у листи надимака. +_Ажурирано у верзији 4.3.0._ + +// TRANSLATION MISSING +Search a nick in a nicklist by name or unique identifier (`id`). Прототип: @@ -15214,7 +15225,9 @@ struct t_gui_nick *weechat_nicklist_search_nick (struct t_gui_buffer *buffer, * _buffer_: показивач на бафер * _from_group_: тражи само од ове групе, ако је NULL, онда се претражује цела листа надимака -* _name_: име надимка који се тражи +// TRANSLATION MISSING +* _name_: nick name to search; with WeeChat ≥ 4.3.0, a unique identifier can + be given with the format: `==id:xxx` (where `xxx` is the identifier) Повратна вредност: @@ -15224,8 +15237,10 @@ C пример: [source,c] ---- -struct t_gui_nick *ptr_nick = weechat_nicklist_search_nick (my_buffer, - NULL, "test_nick"); +struct t_gui_nick *ptr_nick1 = weechat_nicklist_search_nick (my_buffer, + NULL, "test_nick"); +struct t_gui_nick *ptr_nick2 = weechat_nicklist_search_nick (my_buffer, + NULL, "==id:1714382252187496"); ---- Скрипта (Python): @@ -15236,7 +15251,8 @@ struct t_gui_nick *ptr_nick = weechat_nicklist_search_nick (my_buffer, def nicklist_search_nick(buffer: str, from_group: str, name: str) -> str: ... # пример -nick = weechat.nicklist_search_nick(my_buffer, "", "test_nick") +nick1 = weechat.nicklist_search_nick(my_buffer, "", "test_nick") +nick2 = weechat.nicklist_search_nick(my_buffer, "", "==id:1714382252187496") ---- ==== nicklist_remove_group |