diff options
-rw-r--r-- | docs/perl.txt | 8 | ||||
-rw-r--r-- | src/perl/xs/Irssi-window.xs | 12 |
2 files changed, 16 insertions, 4 deletions
diff --git a/docs/perl.txt b/docs/perl.txt index dfe9d4e4..8183dc65 100644 --- a/docs/perl.txt +++ b/docs/perl.txt @@ -103,8 +103,12 @@ commands() - return list of all commands dccs() - return list of all dcc connections logs() - return list of all log files -print(str) - Print `str' to current window as "Irssi notice". +print(str, [level]) + Print `str' to some window (status/current probably), default level is + "Irssi notice". + +print_window(str, [level]) + Print `str' to current window, default level is "Irssi notice". command(cmd, [Server server, [Channel channel]]) Send a command `cmd' (in current channel). This will work just as if you diff --git a/src/perl/xs/Irssi-window.xs b/src/perl/xs/Irssi-window.xs index a7304d49..f1766ffa 100644 --- a/src/perl/xs/Irssi-window.xs +++ b/src/perl/xs/Irssi-window.xs @@ -23,10 +23,18 @@ OUTPUT: RETVAL void -print(str) +print(str, level=MSGLEVEL_CLIENTNOTICE) char *str + int level; CODE: - printtext(NULL, NULL, MSGLEVEL_CLIENTNOTICE, str); + printtext(NULL, NULL, level, str); + +void +print_window(str, level=MSGLEVEL_CLIENTNOTICE) + char *str + int level; +CODE: + printtext_window(active_win, level, str); #******************************* |