summaryrefslogtreecommitdiff
diff options
context:
space:
mode:
authorSebastien Helleu <flashcode@flashtux.org>2012-08-15 20:20:40 +0200
committerSebastien Helleu <flashcode@flashtux.org>2012-08-15 20:20:40 +0200
commit2ae292e6848cf1cea9efb1f418b7d4ffc534f20c (patch)
tree5752ffb7037d3b8ea4a4174d61c8f8b8929f7765
parent6a6f45e0433e750bdff28a22039108ca6d577ab8 (diff)
downloadweechat-2ae292e6848cf1cea9efb1f418b7d4ffc534f20c.zip
core: fix alignment of command arguments for scripts (in /help command)
-rw-r--r--src/core/wee-command.c1
1 files changed, 1 insertions, 0 deletions
diff --git a/src/core/wee-command.c b/src/core/wee-command.c
index 03d6dbdd0..d9ef42458 100644
--- a/src/core/wee-command.c
+++ b/src/core/wee-command.c
@@ -1946,6 +1946,7 @@ COMMAND_CALLBACK(help)
command_found = 1;
gui_chat_printf (NULL, "");
length = utf8_strlen_screen (plugin_get_name (ptr_hook->plugin)) +
+ ((ptr_hook->subplugin && ptr_hook->subplugin[0]) ? utf8_strlen_screen (ptr_hook->subplugin) + 1 : 0) +
utf8_strlen_screen (HOOK_COMMAND(ptr_hook, command)) + 7;
snprintf (str_format, sizeof (str_format),
"%%-%ds%%s", length);