diff options
author | James Booth <boothj5@gmail.com> | 2012-08-16 01:39:19 +0100 |
---|---|---|
committer | James Booth <boothj5@gmail.com> | 2012-08-16 01:39:19 +0100 |
commit | 84bd88ea92aa93d509de5784e82b3b6752979d94 (patch) | |
tree | dc1c8b5b33d8f47c2f335ce178964aaf1faa384f /src | |
parent | 41daf094323a1a35565b8fdcfd1e9897529b39ad (diff) | |
download | profani-tty-84bd88ea92aa93d509de5784e82b3b6752979d94.tar.gz |
Show basic help on startup
Diffstat (limited to 'src')
-rw-r--r-- | src/command.c | 2 | ||||
-rw-r--r-- | src/windows.c | 36 |
2 files changed, 18 insertions, 20 deletions
diff --git a/src/command.c b/src/command.c index 3334548b..66c00805 100644 --- a/src/command.c +++ b/src/command.c @@ -82,7 +82,7 @@ static struct cmd_t main_commands[] = { { "/help", _cmd_help, - { "/help [command]", "This help, or help on a specific command", + { "/help [command]", "Show help summary, or help on a specific command", { "/help [command]", "---------------", "List all commands with short help on what they do.", diff --git a/src/windows.c b/src/windows.c index 90f97e73..29665838 100644 --- a/src/windows.c +++ b/src/windows.c @@ -58,6 +58,7 @@ static int max_cols = 0; static void _create_windows(void); static void _print_splash_logo(WINDOW *win); +static void _cons_show_basic_help(void); static int _find_prof_win_index(const char * const contact); static int _new_prof_win(const char * const contact); static void _current_window_refresh(void); @@ -450,8 +451,8 @@ cons_prefs(void) dirty = TRUE; } -void -cons_help(void) +static void +_cons_show_basic_help(void) { cons_show(""); cons_show("Basic Commands:"); @@ -467,6 +468,13 @@ cons_help(void) } cons_show(""); +} + +void +cons_help(void) +{ + _cons_show_basic_help(); + cons_show("Settings:"); cons_show(""); @@ -479,14 +487,6 @@ cons_help(void) settings_helpers = g_slist_next(settings_helpers); } -/* - cons_show("/beep <on/off> : Enable/disable sound notification"); - cons_show("/notify <on/off> : Enable/disable desktop notifications"); - cons_show("/flash <on/off> : Enable/disable screen flash notification"); - cons_show("/showsplash <on/off> : Enable/disable splash logo on startup"); - cons_show("/chlog <on/off> : Enable/disable chat logging"); -*/ - cons_show(""); cons_show("Status changes:"); cons_show(""); @@ -500,14 +500,6 @@ cons_help(void) status_helpers = g_slist_next(status_helpers); } -/* - cons_show("/away <msg> : Set status to away."); - cons_show("/online <msg> : Set status to online."); - cons_show("/dnd <msg> : Set status to dnd (do not disturb)."); - cons_show("/chat <msg> : Set status to chat (available for chat)."); - cons_show("/xa <msg> : Set status to xa (extended away)."); -*/ - cons_show(""); cons_show("Navigation:"); cons_show(""); @@ -643,7 +635,13 @@ _create_windows(void) _win_show_time(_cons_win); wprintw(_cons_win, "\n"); _win_show_time(_cons_win); - wprintw(_cons_win, "Type '/help' to get started.\n"); + wprintw(_cons_win, "Type '/help' to show all commands.\n"); + _win_show_time(_cons_win); + wprintw(_cons_win, "Use page up and down keys to view.\n"); + _win_show_time(_cons_win); + wprintw(_cons_win, "Use tab to autocomplete commands, logins, or usernames.\n"); + + _cons_show_basic_help(); } prefresh(_cons_win, 0, 0, 1, 0, rows-3, cols-1); |