--- src/fe-common/core/chat-completion.c 2009-10-07 14:29:00.000000000 +0000 +++ src/fe-common/core/chat-completion.c 2009-10-07 14:48:33.000000000 +0000 @@ -43,6 +43,7 @@ static const char *completion_char, *cmdchars; static GSList *global_lastmsgs; static int completion_auto, completion_strict; +static int complation_empty_line; #define SERVER_LAST_MSG_ADD(server, nick) \ last_msg_add(&((MODULE_SERVER_REC *) MODULE_DATA(server))->lastmsgs, \ @@ -641,12 +642,14 @@ return; if (*linestart == '\0' && *word == '\0') { - /* pressed TAB at the start of line - add /MSG */ - prefix = g_strdup_printf("%cmsg", *cmdchars); - *list = completion_msg(server, NULL, "", prefix); - if (*list == NULL) - *list = g_list_append(*list, g_strdup(prefix)); - g_free(prefix); + if (completion_empty_line) { + /* pressed TAB at the start of line - add /MSG */ + prefix = g_strdup_printf("%cmsg", *cmdchars); + *list = completion_msg(server, NULL, "", prefix); + if (*list == NULL) + *list = g_list_append(*list, g_strdup(prefix)); + g_free(prefix); + } signal_stop(); return; @@ -1130,6 +1133,7 @@ cmdchars = settings_get_str("cmdchars"); completion_auto = settings_get_bool("completion_auto"); completion_strict = settings_get_bool("completion_strict"); + completion_empty_line = settings_get_bool("completion_empty_line"); if (*completion_char == '\0') { /* this would break.. */ @@ -1145,6 +1149,7 @@ settings_add_int("completion", "completion_keep_privates", 10); settings_add_bool("completion", "completion_nicks_lowercase", FALSE); settings_add_bool("completion", "completion_strict", FALSE); + settings_add_bool("completion", "completion_empty_line", TRUE); settings_add_bool("lookandfeel", "expand_escapes", FALSE);