diff options
-rw-r--r-- | ChangeLog.adoc | 1 | ||||
-rw-r--r-- | doc/de/autogen/plugin_api/hdata.adoc | 9 | ||||
-rw-r--r-- | doc/en/autogen/plugin_api/hdata.adoc | 9 | ||||
-rw-r--r-- | doc/fr/autogen/plugin_api/hdata.adoc | 9 | ||||
-rw-r--r-- | doc/it/autogen/plugin_api/hdata.adoc | 9 | ||||
-rw-r--r-- | doc/ja/autogen/plugin_api/hdata.adoc | 9 | ||||
-rw-r--r-- | doc/pl/autogen/plugin_api/hdata.adoc | 9 | ||||
-rw-r--r-- | po/cs.po | 6 | ||||
-rw-r--r-- | po/de.po | 6 | ||||
-rw-r--r-- | po/es.po | 6 | ||||
-rw-r--r-- | po/fr.po | 7 | ||||
-rw-r--r-- | po/hu.po | 6 | ||||
-rw-r--r-- | po/it.po | 6 | ||||
-rw-r--r-- | po/ja.po | 6 | ||||
-rw-r--r-- | po/pl.po | 6 | ||||
-rw-r--r-- | po/pt.po | 6 | ||||
-rw-r--r-- | po/pt_BR.po | 6 | ||||
-rw-r--r-- | po/ru.po | 6 | ||||
-rw-r--r-- | po/tr.po | 5 | ||||
-rw-r--r-- | po/weechat.pot | 5 | ||||
-rw-r--r-- | src/gui/gui-completion.c | 24 | ||||
-rw-r--r-- | src/gui/gui-completion.h | 3 | ||||
-rw-r--r-- | src/plugins/plugin-api.c | 3 |
23 files changed, 148 insertions, 14 deletions
diff --git a/ChangeLog.adoc b/ChangeLog.adoc index af1dbd3fa..c9836a574 100644 --- a/ChangeLog.adoc +++ b/ChangeLog.adoc @@ -24,6 +24,7 @@ New features:: * core: add command line option "--stdout" in weechat-headless binary to log to stdout rather than ~/.weechat/weechat.log (issue #1475, issue #1477) * core: reload configuration files on SIGHUP (issue #1476) * api: add functions completion_new, completion_search and completion_free + * api: add hdata "completion_word" * buflist: add default key kbd:[Alt+Shift+B] to toggle buflist * buflist: add options enable/disable/toggle in command /buflist * buflist: evaluate option buflist.look.sort so that sort can be customized for each of the three buflist bar items (issue #1465) diff --git a/doc/de/autogen/plugin_api/hdata.adoc b/doc/de/autogen/plugin_api/hdata.adoc index cfb992f04..65429fdc0 100644 --- a/doc/de/autogen/plugin_api/hdata.adoc +++ b/doc/de/autogen/plugin_api/hdata.adoc @@ -671,6 +671,15 @@ _next_completion_ (pointer, hdata: "completion") + | weechat +| [[hdata_completion_word]]<<hdata_completion_word,completion_word>> +| structure with word found for a completion +| - +| _word_ (string) + +_nick_completion_ (char) + +_count_ (integer) + + + +| weechat | [[hdata_config_file]]<<hdata_config_file,config_file>> | Konfigurationsdatei | _config_files_ + diff --git a/doc/en/autogen/plugin_api/hdata.adoc b/doc/en/autogen/plugin_api/hdata.adoc index f3b9338e5..7477f63c9 100644 --- a/doc/en/autogen/plugin_api/hdata.adoc +++ b/doc/en/autogen/plugin_api/hdata.adoc @@ -671,6 +671,15 @@ _next_completion_ (pointer, hdata: "completion") + | weechat +| [[hdata_completion_word]]<<hdata_completion_word,completion_word>> +| structure with word found for a completion +| - +| _word_ (string) + +_nick_completion_ (char) + +_count_ (integer) + + + +| weechat | [[hdata_config_file]]<<hdata_config_file,config_file>> | config file | _config_files_ + diff --git a/doc/fr/autogen/plugin_api/hdata.adoc b/doc/fr/autogen/plugin_api/hdata.adoc index 38839bff2..8cfa33bac 100644 --- a/doc/fr/autogen/plugin_api/hdata.adoc +++ b/doc/fr/autogen/plugin_api/hdata.adoc @@ -671,6 +671,15 @@ _next_completion_ (pointer, hdata: "completion") + | weechat +| [[hdata_completion_word]]<<hdata_completion_word,completion_word>> +| structure avec un mot trouvé pour une complétion +| - +| _word_ (string) + +_nick_completion_ (char) + +_count_ (integer) + + + +| weechat | [[hdata_config_file]]<<hdata_config_file,config_file>> | fichier de configuration | _config_files_ + diff --git a/doc/it/autogen/plugin_api/hdata.adoc b/doc/it/autogen/plugin_api/hdata.adoc index feab3455d..8df7e4ea7 100644 --- a/doc/it/autogen/plugin_api/hdata.adoc +++ b/doc/it/autogen/plugin_api/hdata.adoc @@ -671,6 +671,15 @@ _next_completion_ (pointer, hdata: "completion") + | weechat +| [[hdata_completion_word]]<<hdata_completion_word,completion_word>> +| structure with word found for a completion +| - +| _word_ (string) + +_nick_completion_ (char) + +_count_ (integer) + + + +| weechat | [[hdata_config_file]]<<hdata_config_file,config_file>> | file di configurazione | _config_files_ + diff --git a/doc/ja/autogen/plugin_api/hdata.adoc b/doc/ja/autogen/plugin_api/hdata.adoc index 4dce7fd19..049b7a7d1 100644 --- a/doc/ja/autogen/plugin_api/hdata.adoc +++ b/doc/ja/autogen/plugin_api/hdata.adoc @@ -671,6 +671,15 @@ _next_completion_ (pointer, hdata: "completion") + | weechat +| [[hdata_completion_word]]<<hdata_completion_word,completion_word>> +| structure with word found for a completion +| - +| _word_ (string) + +_nick_completion_ (char) + +_count_ (integer) + + + +| weechat | [[hdata_config_file]]<<hdata_config_file,config_file>> | 設定ファイル | _config_files_ + diff --git a/doc/pl/autogen/plugin_api/hdata.adoc b/doc/pl/autogen/plugin_api/hdata.adoc index 14dc7f1ca..1f986f1bd 100644 --- a/doc/pl/autogen/plugin_api/hdata.adoc +++ b/doc/pl/autogen/plugin_api/hdata.adoc @@ -671,6 +671,15 @@ _next_completion_ (pointer, hdata: "completion") + | weechat +| [[hdata_completion_word]]<<hdata_completion_word,completion_word>> +| structure with word found for a completion +| - +| _word_ (string) + +_nick_completion_ (char) + +_count_ (integer) + + + +| weechat | [[hdata_config_file]]<<hdata_config_file,config_file>> | plik konfiguracyjne | _config_files_ + @@ -21,7 +21,7 @@ msgid "" msgstr "" "Project-Id-Version: WeeChat\n" "Report-Msgid-Bugs-To: flashcode@flashtux.org\n" -"POT-Creation-Date: 2020-04-26 09:14+0200\n" +"POT-Creation-Date: 2020-04-27 22:15+0200\n" "PO-Revision-Date: 2020-04-18 11:34+0200\n" "Last-Translator: Ondřej Súkup <mimi.vx@gmail.com>\n" "Language-Team: weechat-dev <weechat-dev@nongnu.org>\n" @@ -10079,6 +10079,10 @@ msgstr "navštívený buffer" msgid "structure with completion" msgstr "struktura s dokončením" +#, fuzzy +msgid "structure with word found for a completion" +msgstr "struktura s dokončením" + msgid "config file" msgstr "konfigurační soubor" @@ -24,7 +24,7 @@ msgid "" msgstr "" "Project-Id-Version: WeeChat\n" "Report-Msgid-Bugs-To: flashcode@flashtux.org\n" -"POT-Creation-Date: 2020-04-26 09:14+0200\n" +"POT-Creation-Date: 2020-04-27 22:15+0200\n" "PO-Revision-Date: 2020-04-19 12:01+0200\n" "Last-Translator: Nils Görs <weechatter@arcor.de>\n" "Language-Team: German <kde-i18n-de@kde.org>\n" @@ -11961,6 +11961,10 @@ msgstr "besuchte Buffer" msgid "structure with completion" msgstr "Struktur mit Vervollständigung" +#, fuzzy +msgid "structure with word found for a completion" +msgstr "Struktur mit Vervollständigung" + msgid "config file" msgstr "Konfigurationsdatei" @@ -22,7 +22,7 @@ msgid "" msgstr "" "Project-Id-Version: WeeChat\n" "Report-Msgid-Bugs-To: flashcode@flashtux.org\n" -"POT-Creation-Date: 2020-04-26 09:14+0200\n" +"POT-Creation-Date: 2020-04-27 22:15+0200\n" "PO-Revision-Date: 2020-04-18 11:34+0200\n" "Last-Translator: Elián Hanisch <lambdae2@gmail.com>\n" "Language-Team: weechat-dev <weechat-dev@nongnu.org>\n" @@ -10394,6 +10394,10 @@ msgstr "lista de buffers" msgid "structure with completion" msgstr "estructura con auto-completador" +#, fuzzy +msgid "structure with word found for a completion" +msgstr "estructura con auto-completador" + msgid "config file" msgstr "archivo de configuración" @@ -21,8 +21,8 @@ msgid "" msgstr "" "Project-Id-Version: WeeChat\n" "Report-Msgid-Bugs-To: flashcode@flashtux.org\n" -"POT-Creation-Date: 2020-04-26 09:14+0200\n" -"PO-Revision-Date: 2020-04-26 09:15+0200\n" +"POT-Creation-Date: 2020-04-27 22:15+0200\n" +"PO-Revision-Date: 2020-04-27 22:16+0200\n" "Last-Translator: Sébastien Helleu <flashcode@flashtux.org>\n" "Language-Team: weechat-dev <weechat-dev@nongnu.org>\n" "Language: fr\n" @@ -11690,6 +11690,9 @@ msgstr "tampon visité" msgid "structure with completion" msgstr "structure avec une complétion" +msgid "structure with word found for a completion" +msgstr "structure avec un mot trouvé pour une complétion" + msgid "config file" msgstr "fichier de configuration" @@ -20,7 +20,7 @@ msgid "" msgstr "" "Project-Id-Version: WeeChat\n" "Report-Msgid-Bugs-To: flashcode@flashtux.org\n" -"POT-Creation-Date: 2020-04-26 09:14+0200\n" +"POT-Creation-Date: 2020-04-27 22:15+0200\n" "PO-Revision-Date: 2020-04-18 11:34+0200\n" "Last-Translator: Andras Voroskoi <voroskoi@frugalware.org>\n" "Language-Team: weechat-dev <weechat-dev@nongnu.org>\n" @@ -9421,6 +9421,10 @@ msgid "structure with completion" msgstr "szöveg beillesztése a parancssorba" #, fuzzy +msgid "structure with word found for a completion" +msgstr "szöveg beillesztése a parancssorba" + +#, fuzzy msgid "config file" msgstr "szerver konfigurációs fájljának újraolvastatása" @@ -20,7 +20,7 @@ msgid "" msgstr "" "Project-Id-Version: WeeChat\n" "Report-Msgid-Bugs-To: flashcode@flashtux.org\n" -"POT-Creation-Date: 2020-04-26 09:14+0200\n" +"POT-Creation-Date: 2020-04-27 22:15+0200\n" "PO-Revision-Date: 2020-04-18 11:34+0200\n" "Last-Translator: Esteban I. Ruiz Moreno <exio4.com@gmail.com>\n" "Language-Team: weechat-dev <weechat-dev@nongnu.org>\n" @@ -10580,6 +10580,10 @@ msgstr "elenco dei buffer" msgid "structure with completion" msgstr "struttura con completamento" +#, fuzzy +msgid "structure with word found for a completion" +msgstr "struttura con completamento" + msgid "config file" msgstr "file di configurazione" @@ -20,7 +20,7 @@ msgid "" msgstr "" "Project-Id-Version: WeeChat\n" "Report-Msgid-Bugs-To: flashcode@flashtux.org\n" -"POT-Creation-Date: 2020-04-26 09:14+0200\n" +"POT-Creation-Date: 2020-04-27 22:15+0200\n" "PO-Revision-Date: 2020-04-18 11:34+0200\n" "Last-Translator: AYANOKOUZI, Ryuunosuke <i38w7i3@yahoo.co.jp>\n" "Language-Team: Japanese <https://github.com/l/weechat/tree/master/" @@ -11211,6 +11211,10 @@ msgstr "訪問済みバッファ" msgid "structure with completion" msgstr "補完する構造" +#, fuzzy +msgid "structure with word found for a completion" +msgstr "補完する構造" + msgid "config file" msgstr "設定ファイル" @@ -22,7 +22,7 @@ msgid "" msgstr "" "Project-Id-Version: WeeChat\n" "Report-Msgid-Bugs-To: flashcode@flashtux.org\n" -"POT-Creation-Date: 2020-04-26 09:14+0200\n" +"POT-Creation-Date: 2020-04-27 22:15+0200\n" "PO-Revision-Date: 2020-04-18 11:34+0200\n" "Last-Translator: Krzysztof Korościk <soltys@soltys.info>\n" "Language-Team: Polish <kde-i18n-doc@kde.org>\n" @@ -11423,6 +11423,10 @@ msgstr "odwiedzony bufor" msgid "structure with completion" msgstr "struktura z uzupełnianiem" +#, fuzzy +msgid "structure with word found for a completion" +msgstr "struktura z uzupełnianiem" + msgid "config file" msgstr "plik konfiguracyjne" @@ -20,7 +20,7 @@ msgid "" msgstr "" "Project-Id-Version: WeeChat\n" "Report-Msgid-Bugs-To: flashcode@flashtux.org\n" -"POT-Creation-Date: 2020-04-26 09:14+0200\n" +"POT-Creation-Date: 2020-04-27 22:15+0200\n" "PO-Revision-Date: 2020-04-18 11:34+0200\n" "Last-Translator: Vasco Almeida <vascomalmeida@sapo.pt>\n" "Language-Team: Portuguese <>\n" @@ -11042,6 +11042,10 @@ msgstr "buffer visitado" msgid "structure with completion" msgstr "estrutura com completação" +#, fuzzy +msgid "structure with word found for a completion" +msgstr "estrutura com completação" + msgid "config file" msgstr "ficheiro de configuração" diff --git a/po/pt_BR.po b/po/pt_BR.po index 4dd85de5a..0fea1ef5b 100644 --- a/po/pt_BR.po +++ b/po/pt_BR.po @@ -21,7 +21,7 @@ msgid "" msgstr "" "Project-Id-Version: WeeChat\n" "Report-Msgid-Bugs-To: flashcode@flashtux.org\n" -"POT-Creation-Date: 2020-04-26 09:14+0200\n" +"POT-Creation-Date: 2020-04-27 22:15+0200\n" "PO-Revision-Date: 2020-04-18 11:34+0200\n" "Last-Translator: Eduardo Elias <camponez@gmail.com>\n" "Language-Team: weechat-dev <weechat-dev@nongnu.org>\n" @@ -9881,6 +9881,10 @@ msgstr "lista de buffers" msgid "structure with completion" msgstr "estrutura com completação" +#, fuzzy +msgid "structure with word found for a completion" +msgstr "estrutura com completação" + msgid "config file" msgstr "arquivo de configuração" @@ -21,7 +21,7 @@ msgid "" msgstr "" "Project-Id-Version: WeeChat\n" "Report-Msgid-Bugs-To: flashcode@flashtux.org\n" -"POT-Creation-Date: 2020-04-26 09:14+0200\n" +"POT-Creation-Date: 2020-04-27 22:15+0200\n" "PO-Revision-Date: 2020-04-18 11:34+0200\n" "Last-Translator: Aleksey V Zapparov AKA ixti <ixti@member.fsf.org>\n" "Language-Team: weechat-dev <weechat-dev@nongnu.org>\n" @@ -9457,6 +9457,10 @@ msgid "structure with completion" msgstr "вставить строку в поле ввода" #, fuzzy +msgid "structure with word found for a completion" +msgstr "вставить строку в поле ввода" + +#, fuzzy msgid "config file" msgstr "перезагрузить конфигурационный файл сервера" @@ -20,7 +20,7 @@ msgid "" msgstr "" "Project-Id-Version: WeeChat\n" "Report-Msgid-Bugs-To: flashcode@flashtux.org\n" -"POT-Creation-Date: 2020-04-26 09:14+0200\n" +"POT-Creation-Date: 2020-04-27 22:15+0200\n" "PO-Revision-Date: 2019-11-03 08:38+0100\n" "Last-Translator: Hasan Kiran <sunder67@hotmail.com>\n" "Language-Team: weechat-dev <weechat-dev@nongnu.org>\n" @@ -8609,6 +8609,9 @@ msgstr "" msgid "structure with completion" msgstr "" +msgid "structure with word found for a completion" +msgstr "" + msgid "config file" msgstr "" diff --git a/po/weechat.pot b/po/weechat.pot index 7e9141ffa..8160556b0 100644 --- a/po/weechat.pot +++ b/po/weechat.pot @@ -21,7 +21,7 @@ msgid "" msgstr "" "Project-Id-Version: WeeChat\n" "Report-Msgid-Bugs-To: flashcode@flashtux.org\n" -"POT-Creation-Date: 2020-04-26 09:14+0200\n" +"POT-Creation-Date: 2020-04-27 22:15+0200\n" "PO-Revision-Date: 2014-08-16 10:27+0200\n" "Last-Translator: Sébastien Helleu <flashcode@flashtux.org>\n" "Language-Team: weechat-dev <weechat-dev@nongnu.org>\n" @@ -8470,6 +8470,9 @@ msgstr "" msgid "structure with completion" msgstr "" +msgid "structure with word found for a completion" +msgstr "" + msgid "config file" msgstr "" diff --git a/src/gui/gui-completion.c b/src/gui/gui-completion.c index 615785eea..c36ab940a 100644 --- a/src/gui/gui-completion.c +++ b/src/gui/gui-completion.c @@ -1510,6 +1510,30 @@ gui_completion_hdata_completion_cb (const void *pointer, void *data, } /* + * Returns hdata for completion word. + */ + +struct t_hdata * +gui_completion_hdata_completion_word_cb (const void *pointer, void *data, + const char *hdata_name) +{ + struct t_hdata *hdata; + + /* make C compiler happy */ + (void) pointer; + (void) data; + + hdata = hdata_new (NULL, hdata_name, NULL, NULL, 0, 0, NULL, NULL); + if (hdata) + { + HDATA_VAR(struct t_gui_completion_word, word, STRING, 0, NULL, NULL); + HDATA_VAR(struct t_gui_completion_word, nick_completion, CHAR, 0, NULL, NULL); + HDATA_VAR(struct t_gui_completion_word, count, INTEGER, 0, NULL, NULL); + } + return hdata; +} + +/* * Prints list of completion words in WeeChat log file (usually for crash dump). */ diff --git a/src/gui/gui-completion.h b/src/gui/gui-completion.h index 6f5d85ae0..8056d1bf8 100644 --- a/src/gui/gui-completion.h +++ b/src/gui/gui-completion.h @@ -96,6 +96,9 @@ extern const char *gui_completion_get_string (struct t_gui_completion *completio extern struct t_hdata *gui_completion_hdata_completion_cb (const void *pointer, void *data, const char *hdata_name); +extern struct t_hdata *gui_completion_hdata_completion_word_cb (const void *pointer, + void *data, + const char *hdata_name); extern void gui_completion_print_log (); #endif /* WEECHAT_GUI_COMPLETION_H */ diff --git a/src/plugins/plugin-api.c b/src/plugins/plugin-api.c index 0d862e251..d4cd2fca6 100644 --- a/src/plugins/plugin-api.c +++ b/src/plugins/plugin-api.c @@ -649,6 +649,9 @@ plugin_api_init () &gui_buffer_hdata_buffer_visited_cb, NULL, NULL); hook_hdata (NULL, "completion", N_("structure with completion"), &gui_completion_hdata_completion_cb, NULL, NULL); + hook_hdata (NULL, "completion_word", + N_("structure with word found for a completion"), + &gui_completion_hdata_completion_word_cb, NULL, NULL); hook_hdata (NULL, "config_file", N_("config file"), &config_file_hdata_config_file_cb, NULL, NULL); hook_hdata (NULL, "config_section", N_("config section"), |