Mercurial > pidgin
comparison plugins/PERL-HOWTO @ 806:67bdecdecbb7
[gaim-migrate @ 816]
yay, i think perl is finally working well
committer: Tailor Script <tailor@pidgin.im>
| author | Eric Warmenhoven <eric@warmenhoven.org> |
|---|---|
| date | Thu, 31 Aug 2000 01:40:58 +0000 |
| parents | 1afe98d2461e |
| children | 0ef4386edc29 |
comparison
equal
deleted
inserted
replaced
| 805:2f0655e185b8 | 806:67bdecdecbb7 |
|---|---|
| 13 Plugins are more powerful as they can directly access gaim's functions and | 13 Plugins are more powerful as they can directly access gaim's functions and |
| 14 variables; as such they should be used for things like modifying the UI or | 14 variables; as such they should be used for things like modifying the UI or |
| 15 when something takes quite a bit of trickery not offered by perl. But for | 15 when something takes quite a bit of trickery not offered by perl. But for |
| 16 the most part things should be written in Perl. It's more stable than | 16 the most part things should be written in Perl. It's more stable than |
| 17 plugins. | 17 plugins. |
| 18 | |
| 19 There's a really quick simple perl script in this directory, gaim.pl, that | |
| 20 should show most of the functions. Most things should be self-explanatory. | |
| 18 | 21 |
| 19 Everything available in normal perl scripts should be available in gaim's | 22 Everything available in normal perl scripts should be available in gaim's |
| 20 perl interface, so I'm not going to bother describing that. The important | 23 perl interface, so I'm not going to bother describing that. The important |
| 21 things are the functions provided by gaim's internal AIM module, which is | 24 things are the functions provided by gaim's internal AIM module, which is |
| 22 what most of this document is about. So, onto the functions. | 25 what most of this document is about. So, onto the functions. |
| 105 plugins have had their way with them. Perl scripts cannot modify the values | 108 plugins have had their way with them. Perl scripts cannot modify the values |
| 106 so that gaim knows what the changes are. Unlike X-Chat, perl scripts cannot | 109 so that gaim knows what the changes are. Unlike X-Chat, perl scripts cannot |
| 107 short-circut gaim (that is, your script will be called in order it was added, | 110 short-circut gaim (that is, your script will be called in order it was added, |
| 108 despite what other scripts do, and afterwards, execution will continue as | 111 despite what other scripts do, and afterwards, execution will continue as |
| 109 normal). Names of buddies and chat rooms will be in quotes, and all other | 112 normal). Names of buddies and chat rooms will be in quotes, and all other |
| 110 values (like text messages) will not be. | 113 values (like text messages) will not be. (Watch the debug window to get a |
| 114 better feel for this, or better yet, look at the bottom of plugins.c.) | |
| 111 | 115 |
| 112 AIM::add_timeout_handler(integer, function) | 116 AIM::add_timeout_handler(integer, function) |
| 113 This calls function after integer number of seconds. It only calls function | 117 This calls function after integer number of seconds. It only calls function |
| 114 once, so if you want to keep calling function, keep reading the handler. | 118 once, so if you want to keep calling function, keep readding the handler. |
