summaryrefslogtreecommitdiff
diff options
context:
space:
mode:
-rw-r--r--doc/de/autogen/weechat_options.xml10
-rw-r--r--doc/en/autogen/weechat_options.xml10
-rw-r--r--doc/fr/autogen/weechat_options.xml10
-rw-r--r--po/cs.po6
-rw-r--r--po/de.po6
-rw-r--r--po/es.po6
-rw-r--r--po/fr.po10
-rw-r--r--po/hu.po6
-rw-r--r--po/ru.po6
-rw-r--r--po/weechat.pot6
-rw-r--r--src/core/wee-config.c7
-rw-r--r--src/core/wee-config.h1
-rw-r--r--src/gui/gui-completion.c5
13 files changed, 81 insertions, 8 deletions
diff --git a/doc/de/autogen/weechat_options.xml b/doc/de/autogen/weechat_options.xml
index e9cf2b6f1..ead661fea 100644
--- a/doc/de/autogen/weechat_options.xml
+++ b/doc/de/autogen/weechat_options.xml
@@ -576,6 +576,16 @@
</listitem>
</itemizedlist>
+<command>weechat.completion.nick_add_space</command>: add space after nick completion (when nick is not first word on command line)
+<itemizedlist>
+ <listitem>
+ <para>type: boolean</para>
+ </listitem>
+ <listitem>
+ <para>values: on, off (default value: on)</para>
+ </listitem>
+</itemizedlist>
+
<command>weechat.completion.nick_completor</command>: string inserted after nick completion
<itemizedlist>
<listitem>
diff --git a/doc/en/autogen/weechat_options.xml b/doc/en/autogen/weechat_options.xml
index d4461a48d..0015063b2 100644
--- a/doc/en/autogen/weechat_options.xml
+++ b/doc/en/autogen/weechat_options.xml
@@ -576,6 +576,16 @@
</listitem>
</itemizedlist>
+<command>weechat.completion.nick_add_space</command>: add space after nick completion (when nick is not first word on command line)
+<itemizedlist>
+ <listitem>
+ <para>type: boolean</para>
+ </listitem>
+ <listitem>
+ <para>values: on, off (default value: on)</para>
+ </listitem>
+</itemizedlist>
+
<command>weechat.completion.nick_completor</command>: string inserted after nick completion
<itemizedlist>
<listitem>
diff --git a/doc/fr/autogen/weechat_options.xml b/doc/fr/autogen/weechat_options.xml
index 364ae3c18..89ecdfebd 100644
--- a/doc/fr/autogen/weechat_options.xml
+++ b/doc/fr/autogen/weechat_options.xml
@@ -576,6 +576,16 @@
</listitem>
</itemizedlist>
+<command>weechat.completion.nick_add_space</command>: ajouter un espace après la complétion du pseudo (quand le pseudo n'est pas le premier mot sur la ligne de commande)
+<itemizedlist>
+ <listitem>
+ <para>type: booléen</para>
+ </listitem>
+ <listitem>
+ <para>valeurs: on, off (valeur par défaut: on)</para>
+ </listitem>
+</itemizedlist>
+
<command>weechat.completion.nick_completor</command>: chaîne affichée après la complétion des pseudos
<itemizedlist>
<listitem>
diff --git a/po/cs.po b/po/cs.po
index 54c87c334..2c7a3940a 100644
--- a/po/cs.po
+++ b/po/cs.po
@@ -6,7 +6,7 @@ msgid ""
msgstr ""
"Project-Id-Version: WeeChat 0.2.7-dev\n"
"Report-Msgid-Bugs-To: flashcode@flashtux.org\n"
-"POT-Creation-Date: 2009-04-03 15:08+0200\n"
+"POT-Creation-Date: 2009-04-03 17:50+0200\n"
"PO-Revision-Date: 2009-01-03 00:42+0100\n"
"Last-Translator: Jiri Golembiovsky <golemj@gmail.com>\n"
"Language-Team: weechat-dev <weechat-dev@nongnu.org>\n"
@@ -1624,6 +1624,10 @@ msgid ""
"values)"
msgstr ""
+msgid ""
+"add space after nick completion (when nick is not first word on command line)"
+msgstr ""
+
#, fuzzy
msgid "string inserted after nick completion"
msgstr "řetězec vložený za doplňování přezdívky"
diff --git a/po/de.po b/po/de.po
index 0732a5a07..0c339f86f 100644
--- a/po/de.po
+++ b/po/de.po
@@ -9,7 +9,7 @@ msgid ""
msgstr ""
"Project-Id-Version: WeeChat 0.2.7-dev\n"
"Report-Msgid-Bugs-To: flashcode@flashtux.org\n"
-"POT-Creation-Date: 2009-04-03 15:08+0200\n"
+"POT-Creation-Date: 2009-04-03 17:50+0200\n"
"PO-Revision-Date: 2009-01-03 00:42+0100\n"
"Last-Translator: Thomas Schuetz <i18n@internet-villa.de>\n"
"Language-Team: weechat-dev <weechat-dev@nongnu.org>\n"
@@ -1650,6 +1650,10 @@ msgid ""
"values)"
msgstr ""
+msgid ""
+"add space after nick completion (when nick is not first word on command line)"
+msgstr ""
+
#, fuzzy
msgid "string inserted after nick completion"
msgstr "Nach Nickvervollständigung anzufügende Zeichenfolge"
diff --git a/po/es.po b/po/es.po
index 0a13abc19..035c4f2b1 100644
--- a/po/es.po
+++ b/po/es.po
@@ -6,7 +6,7 @@ msgid ""
msgstr ""
"Project-Id-Version: WeeChat 0.2.7-dev\n"
"Report-Msgid-Bugs-To: flashcode@flashtux.org\n"
-"POT-Creation-Date: 2009-04-03 15:08+0200\n"
+"POT-Creation-Date: 2009-04-03 17:50+0200\n"
"PO-Revision-Date: 2009-01-03 00:42+0100\n"
"Last-Translator: Roberto González Cardenete <robert.glez@gmail.com>\n"
"Language-Team: weechat-dev <weechat-dev@nongnu.org>\n"
@@ -1631,6 +1631,10 @@ msgid ""
"values)"
msgstr ""
+msgid ""
+"add space after nick completion (when nick is not first word on command line)"
+msgstr ""
+
#, fuzzy
msgid "string inserted after nick completion"
msgstr "la cadena mostrada tras la finalización de los nombres de usuario"
diff --git a/po/fr.po b/po/fr.po
index 758cb56e1..5464f6b35 100644
--- a/po/fr.po
+++ b/po/fr.po
@@ -6,8 +6,8 @@ msgid ""
msgstr ""
"Project-Id-Version: WeeChat 0.2.7-dev\n"
"Report-Msgid-Bugs-To: flashcode@flashtux.org\n"
-"POT-Creation-Date: 2009-04-03 15:08+0200\n"
-"PO-Revision-Date: 2009-04-03 15:08+0200\n"
+"POT-Creation-Date: 2009-04-03 17:50+0200\n"
+"PO-Revision-Date: 2009-04-03 17:50+0200\n"
"Last-Translator: FlashCode <flashcode@flashtux.org>\n"
"Language-Team: weechat-dev <weechat-dev@nongnu.org>\n"
"MIME-Version: 1.0\n"
@@ -1718,6 +1718,12 @@ msgstr ""
"modèle de complétion par défaut (merci de consulter la documentation pour "
"les codes et valeurs du modèle)"
+msgid ""
+"add space after nick completion (when nick is not first word on command line)"
+msgstr ""
+"ajouter un espace après la complétion du pseudo (quand le pseudo n'est pas "
+"le premier mot sur la ligne de commande)"
+
msgid "string inserted after nick completion"
msgstr "chaîne affichée après la complétion des pseudos"
diff --git a/po/hu.po b/po/hu.po
index e7bfebd06..a804db56d 100644
--- a/po/hu.po
+++ b/po/hu.po
@@ -12,7 +12,7 @@ msgid ""
msgstr ""
"Project-Id-Version: WeeChat 0.2.7-dev\n"
"Report-Msgid-Bugs-To: flashcode@flashtux.org\n"
-"POT-Creation-Date: 2009-04-03 15:08+0200\n"
+"POT-Creation-Date: 2009-04-03 17:50+0200\n"
"PO-Revision-Date: 2009-01-03 00:42+0100\n"
"Last-Translator: Andras Voroskoi <voroskoi@frugalware.org>\n"
"Language-Team: weechat-dev <weechat-dev@nongnu.org>\n"
@@ -1659,6 +1659,10 @@ msgid ""
"values)"
msgstr ""
+msgid ""
+"add space after nick completion (when nick is not first word on command line)"
+msgstr ""
+
#, fuzzy
msgid "string inserted after nick completion"
msgstr "névkiegészítés után beszúrt szöveg"
diff --git a/po/ru.po b/po/ru.po
index b3c1c3ccd..a604cefa4 100644
--- a/po/ru.po
+++ b/po/ru.po
@@ -6,7 +6,7 @@ msgid ""
msgstr ""
"Project-Id-Version: WeeChat 0.2.7-dev\n"
"Report-Msgid-Bugs-To: flashcode@flashtux.org\n"
-"POT-Creation-Date: 2009-04-03 15:08+0200\n"
+"POT-Creation-Date: 2009-04-03 17:50+0200\n"
"PO-Revision-Date: 2009-01-03 00:42+0100\n"
"Last-Translator: Pavel Shevchuk <stlwrt@gmail.com>\n"
"Language-Team: weechat-dev <weechat-dev@nongnu.org>\n"
@@ -1662,6 +1662,10 @@ msgid ""
"values)"
msgstr ""
+msgid ""
+"add space after nick completion (when nick is not first word on command line)"
+msgstr ""
+
#, fuzzy
msgid "string inserted after nick completion"
msgstr "строка, вставляемая после автодополнения ника"
diff --git a/po/weechat.pot b/po/weechat.pot
index b9f9fa75d..a13eb72be 100644
--- a/po/weechat.pot
+++ b/po/weechat.pot
@@ -7,7 +7,7 @@ msgid ""
msgstr ""
"Project-Id-Version: PACKAGE VERSION\n"
"Report-Msgid-Bugs-To: flashcode@flashtux.org\n"
-"POT-Creation-Date: 2009-04-03 15:08+0200\n"
+"POT-Creation-Date: 2009-04-03 17:50+0200\n"
"PO-Revision-Date: YEAR-MO-DA HO:MI+ZONE\n"
"Last-Translator: FULL NAME <EMAIL@ADDRESS>\n"
"Language-Team: LANGUAGE <LL@li.org>\n"
@@ -1390,6 +1390,10 @@ msgid ""
"values)"
msgstr ""
+msgid ""
+"add space after nick completion (when nick is not first word on command line)"
+msgstr ""
+
msgid "string inserted after nick completion"
msgstr ""
diff --git a/src/core/wee-config.c b/src/core/wee-config.c
index 239c26167..38c549663 100644
--- a/src/core/wee-config.c
+++ b/src/core/wee-config.c
@@ -145,6 +145,7 @@ struct t_config_option *config_color_nicklist_separator;
/* config, completion section */
struct t_config_option *config_completion_default_template;
+struct t_config_option *config_completion_nick_add_space;
struct t_config_option *config_completion_nick_completor;
struct t_config_option *config_completion_nick_first_only;
struct t_config_option *config_completion_nick_ignore_chars;
@@ -1605,6 +1606,12 @@ config_weechat_init_options ()
"codes and values)"),
NULL, 0, 0, "%n|%(irc_channels)", NULL, 0,
NULL, NULL, NULL, NULL, NULL, NULL);
+ config_completion_nick_add_space = config_file_new_option (
+ weechat_config_file, ptr_section,
+ "nick_add_space", "boolean",
+ N_("add space after nick completion (when nick is not first word on "
+ "command line)"),
+ NULL, 0, 0, "on", NULL, 0, NULL, NULL, NULL, NULL, NULL, NULL);
config_completion_nick_completor = config_file_new_option (
weechat_config_file, ptr_section,
"nick_completor", "string",
diff --git a/src/core/wee-config.h b/src/core/wee-config.h
index 1ef819e14..f8754ae2e 100644
--- a/src/core/wee-config.h
+++ b/src/core/wee-config.h
@@ -147,6 +147,7 @@ extern struct t_config_option *config_color_nicklist_more;
extern struct t_config_option *config_color_nicklist_separator;
extern struct t_config_option *config_completion_default_template;
+extern struct t_config_option *config_completion_nick_add_space;
extern struct t_config_option *config_completion_nick_completor;
extern struct t_config_option *config_completion_nick_first_only;
extern struct t_config_option *config_completion_nick_ignore_chars;
diff --git a/src/gui/gui-completion.c b/src/gui/gui-completion.c
index a1ec06246..482c55fd2 100644
--- a/src/gui/gui-completion.c
+++ b/src/gui/gui-completion.c
@@ -1501,6 +1501,11 @@ gui_completion_complete (struct t_gui_completion *completion)
free (completion->word_found);
completion->word_found = strdup (ptr_item->data);
completion->word_found_is_nick = item_is_nick;
+ if (item_is_nick && (completion->base_word_pos > 0)
+ && !CONFIG_BOOLEAN(config_completion_nick_add_space))
+ {
+ completion->add_space = 0;
+ }
/* stop after first nick if user asked that */
if (item_is_nick