aboutsummaryrefslogtreecommitdiffstats
path: root/feature-tests/internal_signals.pl
diff options
context:
space:
mode:
authorTom Feist <shabble@metavore.org>2010-10-06 20:57:20 +0000
committerTom Feist <shabble@metavore.org>2010-10-06 20:57:20 +0000
commit66534b6e8f98144f2e773db627939044891323cb (patch)
tree8e87ac553e67d84bd6750dccf3e6c72772a3b3de /feature-tests/internal_signals.pl
parentremoved useless include of Term::Size (diff)
downloadirssi-scripts-66534b6e8f98144f2e773db627939044891323cb.tar.gz
irssi-scripts-66534b6e8f98144f2e773db627939044891323cb.zip
moved a handy snippet into my feature-tests dir for querying internal signals.
Diffstat (limited to 'feature-tests/internal_signals.pl')
-rw-r--r--feature-tests/internal_signals.pl14
1 files changed, 14 insertions, 0 deletions
diff --git a/feature-tests/internal_signals.pl b/feature-tests/internal_signals.pl
new file mode 100644
index 0000000..e40587f
--- /dev/null
+++ b/feature-tests/internal_signals.pl
@@ -0,0 +1,14 @@
+# not a complete script, just a useful snippet
+Irssi::signal_register({'complete command set'
+ => ["glistptr_char*", "Irssi::UI::Window",
+ "string", "string", "intptr"]});
+
+my @res = ();
+my $num;
+Irssi::signal_emit('complete command set', \@res, Irssi::active_win(),
+ '', '', \$num);
+
+print "results: @res";
+
+# will return all the possible completions for the /set command. you can filter
+# it by changing the 2 empty strings (word-fragment, and line context)