diff options
-rw-r--r-- | ChangeLog | 4 | ||||
-rw-r--r-- | doc/en/weechat_plugin_api.en.txt | 6 | ||||
-rw-r--r-- | doc/fr/weechat_plugin_api.fr.txt | 6 | ||||
-rw-r--r-- | doc/it/weechat_plugin_api.it.txt | 7 | ||||
-rw-r--r-- | src/gui/gui-buffer.c | 4 | ||||
-rw-r--r-- | src/gui/gui-completion.c | 4 | ||||
-rw-r--r-- | src/gui/gui-completion.h | 4 | ||||
-rw-r--r-- | src/gui/gui-input.c | 2 |
8 files changed, 35 insertions, 2 deletions
@@ -1,7 +1,7 @@ WeeChat ChangeLog ================= Sébastien Helleu <flashcode@flashtux.org> -v0.4.1-dev, 2013-04-12 +v0.4.1-dev, 2013-04-18 This document lists all changes for each version. @@ -33,6 +33,8 @@ Version 0.4.1 (under dev!) weechat.history.max_buffer_lines_minutes is set (bug #38197) * core: use default hash/comparison callback for keys of type integer/pointer/time in hashtable +* api: add property "completion_freeze" for function buffer_set: do not stop + completion when command line is updated * api: fix connection to servers with hook_connect on OS X (bug #38496) * api: fix bug in string_match when mask begins and ends with "*" * api: allow hashtable with keys that are not strings in function diff --git a/doc/en/weechat_plugin_api.en.txt b/doc/en/weechat_plugin_api.en.txt index 4f97c02fe..6a9342478 100644 --- a/doc/en/weechat_plugin_api.en.txt +++ b/doc/en/weechat_plugin_api.en.txt @@ -10202,6 +10202,12 @@ Arguments: "-": disable hotlist (global setting, buffer pointer is not used) + priority: add buffer to hotlist with this priority +| completion_freeze | "0", "1" | + "0": no freeze of completion (default value) + (global setting, buffer pointer is not used) + + "1": do not stop completion when command line is updated + (global setting, buffer pointer is not used) + | unread | - | set unread marker after last line of buffer diff --git a/doc/fr/weechat_plugin_api.fr.txt b/doc/fr/weechat_plugin_api.fr.txt index acb60ea9c..ed0e3603f 100644 --- a/doc/fr/weechat_plugin_api.fr.txt +++ b/doc/fr/weechat_plugin_api.fr.txt @@ -10371,6 +10371,12 @@ Paramètres : pas utilisé) + priorité : ajouter ce tampon dans la hotlist avec cette priorité +| completion_freeze | "0", "1" | + "0" : pas de gel de la complétion (valeur par défaut) + (option globale, le pointeur vers le tampon n'est pas utilisé) + + "1" : ne pas arrêter la complétion lorsque la ligne de commande est mise à jour + (option globale, le pointeur vers le tampon n'est pas utilisé) + | unread | - | définit le marqueur de données non lues après la dernière ligne du tampon diff --git a/doc/it/weechat_plugin_api.it.txt b/doc/it/weechat_plugin_api.it.txt index 2e73c967c..953efab7d 100644 --- a/doc/it/weechat_plugin_api.it.txt +++ b/doc/it/weechat_plugin_api.it.txt @@ -10345,6 +10345,13 @@ Argomenti: utilizzato) + priorità: aggiunge il buffer alla hotlist con questa proprietà +// TRANSLATION MISSING +| completion_freeze | "0", "1" | + "0": no freeze of completion (default value) + (impostazione globale, il puntatore al buffer non è utilizzato) + + "1": do not stop completion when command line is updated + (impostazione globale, il puntatore al buffer non è utilizzato) + | unread | - | imposta l'evidenziatore di lettura dopo l'ultima riga del buffer diff --git a/src/gui/gui-buffer.c b/src/gui/gui-buffer.c index bb62d3d01..2f8352eb4 100644 --- a/src/gui/gui-buffer.c +++ b/src/gui/gui-buffer.c @@ -1501,6 +1501,10 @@ gui_buffer_set (struct t_gui_buffer *buffer, const char *property, (void) gui_hotlist_add (buffer, number, NULL); } } + else if (string_strcasecmp (property, "completion_freeze") == 0) + { + gui_completion_freeze = (strcmp (value, "1") == 0) ? 1 : 0; + } if (!buffer) return; diff --git a/src/gui/gui-completion.c b/src/gui/gui-completion.c index 455b9b87c..293f403f7 100644 --- a/src/gui/gui-completion.c +++ b/src/gui/gui-completion.c @@ -47,6 +47,10 @@ #include "gui-buffer.h" +int gui_completion_freeze = 0; /* 1 to freeze completions (do not */ + /* stop partial completion on key) */ + + /* * Initializes completion for a buffer. */ diff --git a/src/gui/gui-completion.h b/src/gui/gui-completion.h index 1ab6740a6..9dff66399 100644 --- a/src/gui/gui-completion.h +++ b/src/gui/gui-completion.h @@ -63,6 +63,10 @@ struct t_gui_completion struct t_gui_completion_partial *last_partial_completion; }; +/* completion variables */ + +extern int gui_completion_freeze; + /* completion functions */ extern void gui_completion_buffer_init (struct t_gui_completion *completion, diff --git a/src/gui/gui-input.c b/src/gui/gui-input.c index 82453093e..37afcb8e4 100644 --- a/src/gui/gui-input.c +++ b/src/gui/gui-input.c @@ -162,7 +162,7 @@ gui_input_text_changed_modifier_and_signal (struct t_gui_buffer *buffer, } } - if (stop_completion) + if (stop_completion && !gui_completion_freeze) gui_completion_stop (buffer->completion); /* send signal */ |