7496 lines
235 KiB
XML
7496 lines
235 KiB
XML
<?xml version="1.0" encoding="iso-8859-1"?>
|
|
|
|
<!--
|
|
|
|
WeeChat documentation (german version)
|
|
|
|
Copyright (c) 2003-2006 by FlashCode <flashcode@flashtux.org>
|
|
|
|
This manual is free software; you can redistribute it and/or modify
|
|
it under the terms of the GNU General Public License as published by
|
|
the Free Software Foundation; either version 2 of the License, or
|
|
(at your option) any later version.
|
|
|
|
This manual is distributed in the hope that it will be useful,
|
|
but WITHOUT ANY WARRANTY; without even the implied warranty of
|
|
MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the
|
|
GNU General Public License for more details.
|
|
|
|
You should have received a copy of the GNU General Public License
|
|
along with this program; if not, write to the Free Software
|
|
Foundation, Inc., 51 Franklin St, Fifth Floor, Boston, MA 02110-1301 USA
|
|
|
|
-->
|
|
|
|
<!DOCTYPE book PUBLIC "-//OASIS//DTD DocBook XML V4.2//EN"
|
|
"file:///usr/share/xml/docbook/schema/dtd/4.2/docbookx.dtd"
|
|
[
|
|
<!ENTITY date.xml SYSTEM "date.xml">
|
|
<!ENTITY config.xml SYSTEM "config.xml">
|
|
<!ENTITY weechat_commands.xml SYSTEM "weechat_commands.xml">
|
|
<!ENTITY irc_commands.xml SYSTEM "irc_commands.xml">
|
|
<!ENTITY key_functions.xml SYSTEM "key_functions.xml">
|
|
]>
|
|
|
|
<book lang="de">
|
|
|
|
<bookinfo>
|
|
|
|
<title>WeeChat 0.2.2-cvs - User guide</title>
|
|
<subtitle>Schneller, leichter und erweiterbarer IRC Client</subtitle>
|
|
|
|
<author>
|
|
<firstname>Sébastien</firstname>
|
|
<surname>Helleu</surname>
|
|
<email>flashcode AT flashtux.org</email>
|
|
</author>
|
|
|
|
&date.xml;
|
|
|
|
<copyright>
|
|
<year>2006</year>
|
|
<holder>Sébastien Helleu</holder>
|
|
</copyright>
|
|
|
|
<legalnotice>
|
|
<para>
|
|
Dieses Programm ist freie Software. Sie können es unter
|
|
den Bedingungen der GNU General Public License,
|
|
wie von der Free Software Foundation veröffentlicht,
|
|
weitergeben und/oder modifizieren, entweder gemäß Version 2
|
|
der Lizenz oder (nach Ihrer Option) jeder späteren Version.
|
|
</para>
|
|
<para>
|
|
Die Veröffentlichung dieses Programms erfolgt in der
|
|
Hoffnung, daß es Ihnen von Nutzen sein wird, aber OHNE
|
|
IRGENDEINE GARANTIE, sogar ohne die implizite Garantie der
|
|
MARKTREIFE oder der VERWENDBARKEIT FÜR EINEN BESTIMMTEN ZWECK.
|
|
Details finden Sie in der GNU General Public License.
|
|
</para>
|
|
<para>
|
|
Sie sollten ein Exemplar der GNU General Public License
|
|
zusammen mit diesem Programm erhalten haben. Falls nicht,
|
|
schreiben Sie an die Free Software Foundation, Inc.,
|
|
51 Franklin St, Fifth Floor, Boston, MA 02110, USA.
|
|
</para>
|
|
</legalnotice>
|
|
|
|
<abstract>
|
|
<para>
|
|
Dieses Dokument beschreibt den WeeChat IRC client, es ist ein Teil von WeeChat.
|
|
</para>
|
|
<para>
|
|
Deutsche version: Frank Zacharias
|
|
</para>
|
|
<para>
|
|
Die aktuellste Version ist auf dieser Seite zu finden:
|
|
<ulink url="http://weechat.flashtux.org/doc.php">
|
|
http://weechat.flashtux.org/doc.php
|
|
</ulink>
|
|
</para>
|
|
</abstract>
|
|
|
|
</bookinfo>
|
|
|
|
<!-- =========================== Introduction =========================== -->
|
|
|
|
<chapter id="chapIntroduction">
|
|
<title> Einführung </title>
|
|
|
|
<para>
|
|
Dieses Kapitel beschreibt WeeChat und die Vorraussetzungen für die Installation.
|
|
</para>
|
|
|
|
<section id="secDescription">
|
|
<title> Beschreibung </title>
|
|
|
|
<para>
|
|
WeeChat (Wee Enhanced Environment for Chat) ist ein freier
|
|
<acronym>IRC</acronym> Client, schnell und klein, entwickelt für viele
|
|
Betriebssysteme.
|
|
</para>
|
|
|
|
<para>
|
|
Hauptmerkmale:
|
|
<itemizedlist>
|
|
<listitem>
|
|
<para>
|
|
Mehrere Server gleichzeitig nutzbar (mit SSL, IPv6, Proxy)
|
|
</para>
|
|
</listitem>
|
|
<listitem>
|
|
<para>
|
|
viele unterschiedliche User-Interfaces: Curses, wxWidgets, Gtk und Qt
|
|
</para>
|
|
</listitem>
|
|
<listitem>
|
|
<para>
|
|
klein, schnell and leichtgewichtig
|
|
</para>
|
|
</listitem>
|
|
<listitem>
|
|
<para>
|
|
änderbar und erweiterbar mit Plugins und Skripten
|
|
</para>
|
|
</listitem>
|
|
<listitem>
|
|
<para>
|
|
entsprechend den folgenden <acronym>RFC</acronym>s
|
|
<ulink url="http://www.ietf.org/rfc/rfc1459.txt">1459</ulink>,
|
|
<ulink url="http://www.ietf.org/rfc/rfc2810.txt">2810</ulink>,
|
|
<ulink url="http://www.ietf.org/rfc/rfc2811.txt">2811</ulink>,
|
|
<ulink url="http://www.ietf.org/rfc/rfc2812.txt">2812</ulink> und
|
|
<ulink url="http://www.ietf.org/rfc/rfc2813.txt">2813</ulink>
|
|
</para>
|
|
</listitem>
|
|
<listitem>
|
|
<para>
|
|
Viele Plattformen (GNU/Linux, *BSD, MacOS X, Windows and other)
|
|
</para>
|
|
</listitem>
|
|
<listitem>
|
|
<para>
|
|
100% GPL, freie Software
|
|
</para>
|
|
</listitem>
|
|
</itemizedlist>
|
|
</para>
|
|
|
|
<para>
|
|
WeeChat Homepage:
|
|
<ulink url="http://weechat.flashtux.org">
|
|
http://weechat.flashtux.org
|
|
</ulink>
|
|
</para>
|
|
|
|
</section>
|
|
|
|
<section id="secPreRequis">
|
|
<title> Vorraussetzungen </title>
|
|
|
|
<para>
|
|
Um WeeChat zu installieren, werden <emphasis> gebraucht </emphasis>:
|
|
<itemizedlist>
|
|
<listitem>
|
|
<para>
|
|
ein laufendes GNU/Linux (Compiler für Quellcode-Pakete)
|
|
</para>
|
|
</listitem>
|
|
<listitem>
|
|
<para>
|
|
root-Rechte für die Installation
|
|
</para>
|
|
</listitem>
|
|
<listitem>
|
|
<para>
|
|
dem User-Interface entsprechend, eine der folgenden Bibliotheken:
|
|
<itemizedlist>
|
|
<listitem>
|
|
<para>
|
|
Curses: ncurses Bibliothek
|
|
</para>
|
|
</listitem>
|
|
<listitem>
|
|
<para>
|
|
Gtk: <emphasis>*** noch nicht implementiert ***</emphasis>
|
|
</para>
|
|
</listitem>
|
|
<listitem>
|
|
<para>
|
|
WxWidgets: <emphasis>*** noch nicht implementiert ***</emphasis>
|
|
</para>
|
|
</listitem>
|
|
<listitem>
|
|
<para>
|
|
Qt: <emphasis>*** noch nicht implementiert ***</emphasis>
|
|
</para>
|
|
</listitem>
|
|
</itemizedlist>
|
|
</para>
|
|
</listitem>
|
|
</itemizedlist>
|
|
</para>
|
|
|
|
</section>
|
|
</chapter>
|
|
|
|
<!-- =========================== Installation =========================== -->
|
|
|
|
<chapter id="chapInstallation">
|
|
<title>Installation</title>
|
|
|
|
<para>
|
|
Dieses Kapitel erklärt die Installation von WeeChat.
|
|
</para>
|
|
|
|
<section id="secBinaryPackages">
|
|
<title> Binäre Pakete </title>
|
|
|
|
<para>
|
|
Binäre Pakete sind für die folgenden Distributionen verfügbar:
|
|
<itemizedlist>
|
|
<listitem>
|
|
<para>
|
|
Debian (oder Debian-kompatible):
|
|
<userinput>apt-get install weechat</userinput>
|
|
</para>
|
|
</listitem>
|
|
<listitem>
|
|
<para>
|
|
Mandriva/RedHat (oder jede RPM-kompatible Distribution):
|
|
<userinput>
|
|
rpm -i /chemin/weechat-x.y.z-1.i386.rpm
|
|
</userinput>
|
|
</para>
|
|
</listitem>
|
|
<listitem>
|
|
<para>
|
|
Gentoo:
|
|
<userinput>emerge weechat</userinput>
|
|
</para>
|
|
</listitem>
|
|
</itemizedlist>
|
|
FÜr andere Distributionen: sehen sie in die Dokumentation
|
|
für Installationsanweisungen.
|
|
</para>
|
|
|
|
</section>
|
|
|
|
<section id="secSourcePackage">
|
|
<title> Quellcode-Pakete </title>
|
|
|
|
<para>
|
|
Alles was sie tun müssen, ist in einer Konsole oder einem Terminal aufzurufen:
|
|
<screen><prompt>$ </prompt><userinput>./configure</userinput>
|
|
<prompt>$ </prompt><userinput>make</userinput></screen>
|
|
</para>
|
|
<para>
|
|
Dann root werden und WeeChat installieren:
|
|
<screen><prompt>$ </prompt><userinput>su</userinput>
|
|
(root-Passwort eingeben)
|
|
<prompt># </prompt><userinput>make install</userinput></screen>
|
|
</para>
|
|
|
|
</section>
|
|
|
|
<section id="secCVSSources">
|
|
<title>CVS Quellen</title>
|
|
|
|
<para>
|
|
Warnung: CVS Quellen sind für fortgeschrittene Anwender, das Übersetzen könnte
|
|
fehlschlagen oder das Ergebnis nicht stabil sein. Sie wurden gewarnt!
|
|
</para>
|
|
|
|
<para>
|
|
Um die CVS Quellen zu bekommen, sind folgende Kommandos nötig:
|
|
<screen><prompt>$ </prompt><userinput>cvs -z3 -d:pserver:anonymous@cvs.savannah.nongnu.org:/sources/weechat co weechat</userinput></screen>
|
|
</para>
|
|
|
|
<para>
|
|
Ausführen des folgenden Skripts:
|
|
<userinput>./autogen.sh</userinput>
|
|
</para>
|
|
|
|
<para>
|
|
Dann folgen sie den Anweisungen zu den Quellpaketen
|
|
(siehe <xref linkend="secSourcePackage" />)
|
|
</para>
|
|
|
|
</section>
|
|
|
|
</chapter>
|
|
|
|
<!-- ============================== Usage =============================== -->
|
|
|
|
<chapter id="chapUsage">
|
|
<title> Nutzung </title>
|
|
|
|
<para>
|
|
Dieses Kapitel erklärt, wie Weechat zu starten ist, die zu verwendenden
|
|
Tastenkombinationen, interne und IRC-Kommandos, die Konfigurationsdatei
|
|
und die FIFO für die remote-Bedienung.
|
|
</para>
|
|
|
|
<section id="secRunningWeeChat">
|
|
<title>Starten von WeeChat</title>
|
|
|
|
<para>
|
|
Argumente der Kommandozeile:
|
|
<informaltable colsep="0" frame="none">
|
|
<tgroup cols="2">
|
|
<thead>
|
|
<row>
|
|
<entry>Parameter</entry>
|
|
<entry>Beschreibung</entry>
|
|
</row>
|
|
</thead>
|
|
<tbody>
|
|
<row>
|
|
<entry><literal>-a, --no-connect</literal></entry>
|
|
<entry>
|
|
Schaltet das auto-connect ab
|
|
</entry>
|
|
</row>
|
|
<row>
|
|
<entry><literal>-c, --config</literal></entry>
|
|
<entry>
|
|
Zeigt eine Hilfe zu den Konfigurationsmöglichkeiten (Liste der Optionen)
|
|
</entry>
|
|
</row>
|
|
<row>
|
|
<entry><literal>-d, --dir <path></literal></entry>
|
|
<entry>
|
|
Setzt den Pfad für das Verzeichnis, dass Weechat benutzen soll
|
|
(relevant für die Konfigurationsdateien, Logs, Plugins und Skripte).
|
|
Der Standardwert "<literal>~/.weechat</literal>".
|
|
Bitte beachten Sie: dieses Verzeichnis wird automatisch erzeugt, wenn es noch nicht
|
|
exitiert.
|
|
</entry>
|
|
</row>
|
|
<row>
|
|
<entry><literal>-f, --key-functions</literal></entry>
|
|
<entry>
|
|
Zeigt die intern verwendeten Funktionen von WeeChat für bestimmte Tastenkombinationen an
|
|
</entry>
|
|
</row>
|
|
<row>
|
|
<entry><literal>-h, --help</literal></entry>
|
|
<entry>
|
|
Zeigt eine zusammenfassende Hilfe an.
|
|
</entry>
|
|
</row>
|
|
<row>
|
|
<entry><literal>-i, --irc-commands</literal></entry>
|
|
<entry>
|
|
Zeigt die IRC-Kommandos an
|
|
</entry>
|
|
</row>
|
|
<row>
|
|
<entry><literal>-k, --keys</literal></entry>
|
|
<entry>
|
|
Zeigt die Standard-Tastenkombinationen an
|
|
</entry>
|
|
</row>
|
|
<row>
|
|
<entry><literal>-l, --license</literal></entry>
|
|
<entry>
|
|
Zeigt die Lizenz an
|
|
</entry>
|
|
</row>
|
|
<row>
|
|
<entry><literal>-p, --no-plugin</literal></entry>
|
|
<entry>
|
|
Schaltet das automatische Laden der Plugins ab
|
|
</entry>
|
|
</row>
|
|
<row>
|
|
<entry><literal>-v, --version</literal></entry>
|
|
<entry>
|
|
Zeigt die Programmversion an
|
|
</entry>
|
|
</row>
|
|
<row>
|
|
<entry><literal>-w, --weechat-commands</literal></entry>
|
|
<entry>
|
|
Zeigt die Weechat-eigenen Kommandos an
|
|
</entry>
|
|
</row>
|
|
</tbody>
|
|
</tgroup>
|
|
</informaltable>
|
|
</para>
|
|
|
|
<para>
|
|
Es ist auch möglich URLs für einen oder mehrere IRC-Server anzugeben, so wie:
|
|
<screen>irc[6][s]://[nick[:passwort]@]irc.example.org[:port][/channel][,channel[...]</screen>
|
|
Beispiel um die Channels #weechat and #toto zu betreten
|
|
"<literal>irc.freenode.net</literal>" server, default port (6667),
|
|
mit dem Nicknamen "nono":
|
|
<screen><prompt>$ </prompt><userinput>weechat-curses irc://nono@irc.freenode.net/#weechat,#toto</userinput></screen>
|
|
</para>
|
|
|
|
<para>
|
|
Um WeeChat zu starten, ist eins der folgenden Kommandos abzusetzen:
|
|
<itemizedlist>
|
|
<listitem>
|
|
<para>
|
|
für Curses GUI: <userinput>weechat-curses</userinput>
|
|
</para>
|
|
</listitem>
|
|
<listitem>
|
|
<para>
|
|
für Gtk GUI: <userinput>weechat-gtk</userinput>
|
|
</para>
|
|
</listitem>
|
|
<listitem>
|
|
<para>
|
|
für wxWidgets GUI: <userinput>weechat-wxwidgets</userinput>
|
|
</para>
|
|
</listitem>
|
|
<listitem>
|
|
<para>
|
|
für Qt GUI: <userinput>weechat-qt</userinput>
|
|
</para>
|
|
</listitem>
|
|
</itemizedlist>
|
|
</para>
|
|
|
|
<para>
|
|
Wenn Sie Weechat zum ersten Mal starten, wird eine Konfigurationsdatei
|
|
erzeugt, deren Optionen besitzen Standardwerte. Diese Datei ist:
|
|
"<literal>~/.weechat/weechat.rc</literal>"
|
|
</para>
|
|
|
|
<para>
|
|
Sie können diese Datei entsprechend ihren Bedürfnissen editieren,
|
|
um Weechat anzupassen (NUR wenn Weechat nicht läuft) oder Parameter
|
|
zu beeinflussen mit
|
|
"<literal>/set</literal>" Kommando in WeeChat
|
|
(siehe <xref linkend="secWeeChatCommands" />)
|
|
</para>
|
|
|
|
</section>
|
|
|
|
<section id="secKeyboardShortcuts">
|
|
<title> Tastenkombinationen </title>
|
|
|
|
<para>
|
|
<informaltable colsep="0" frame="none">
|
|
<tgroup cols="2">
|
|
<thead>
|
|
<row>
|
|
<entry> Tastenkombination </entry>
|
|
<entry> Wirkung </entry>
|
|
</row>
|
|
</thead>
|
|
<tbody>
|
|
<row>
|
|
<entry>Links</entry>
|
|
<entry>
|
|
Gehe zum vorherigen Zeichen in der Kommandozeile
|
|
</entry>
|
|
</row>
|
|
<row>
|
|
<entry>Rechts</entry>
|
|
<entry>
|
|
Gehe zum nächsten Zeichen in der Kommandozeile
|
|
</entry>
|
|
</row>
|
|
<row>
|
|
<entry>Strg + Links</entry>
|
|
<entry>
|
|
Gehe zum vorherigen Wort in der Kommandozeile
|
|
</entry>
|
|
</row>
|
|
<row>
|
|
<entry>Strg + Rechts</entry>
|
|
<entry>
|
|
Gehe zum nächsten Wort in der Kommandozeile
|
|
</entry>
|
|
</row>
|
|
<row>
|
|
<entry>Pos1 / Strg + A</entry>
|
|
<entry>
|
|
Gehe zum Anfang der Kommandozeile
|
|
</entry>
|
|
</row>
|
|
<row>
|
|
<entry>Ende / Strg + E</entry>
|
|
<entry>
|
|
Gehe zum Ende der Kommandozeile
|
|
</entry>
|
|
</row>
|
|
<row>
|
|
<entry>Strg + K</entry>
|
|
<entry>
|
|
Lösche vom Cursor bis zum Ende der Kommandozeile
|
|
</entry>
|
|
</row>
|
|
<row>
|
|
<entry>Strg + L</entry>
|
|
<entry>
|
|
Fenster neu aufbauen
|
|
</entry>
|
|
</row>
|
|
<row>
|
|
<entry>Strg + T</entry>
|
|
<entry>
|
|
<!-- TRANSLATION NEEDED -->
|
|
Transpose chars
|
|
</entry>
|
|
</row>
|
|
<row>
|
|
<entry>Strg + U</entry>
|
|
<entry>
|
|
Lösche vom Cursor bis zum Aanfang der Kommandozeile
|
|
</entry>
|
|
</row>
|
|
<row>
|
|
<entry>Strg + W</entry>
|
|
<entry>
|
|
Lösche das vorhergehende Wort in der Kommandozeile
|
|
</entry>
|
|
</row>
|
|
<row>
|
|
<entry>Strg + Y</entry>
|
|
<entry>
|
|
<!-- TRANSLATION NEEDED -->
|
|
Paste clipboard content
|
|
</entry>
|
|
</row>
|
|
<row>
|
|
<entry>Rückschritt / Strg + H</entry>
|
|
<entry>
|
|
Lösche das vorhergehende Zeichen in der Kommandozeile
|
|
</entry>
|
|
</row>
|
|
<row>
|
|
<entry>Entfernen</entry>
|
|
<entry>
|
|
Lösche das nächste Zeichen in der Kommandozeile
|
|
</entry>
|
|
</row>
|
|
<row>
|
|
<!-- TRANSLATION NEEDED -->
|
|
<entry>Tabulator / Shift + Tabulator</entry>
|
|
<entry>
|
|
Vervollständige ein Kommando oder Nick
|
|
(wiederhole: finde nächste Vervollständigung)
|
|
</entry>
|
|
</row>
|
|
<row>
|
|
<entry>Jedes Zeichen</entry>
|
|
<entry>
|
|
Setze das Zeichen beim Cursor in die Kommandozeile ein
|
|
</entry>
|
|
</row>
|
|
<row>
|
|
<entry>Eingabe / Strg + J / Strg + M</entry>
|
|
<entry>
|
|
Führe ein Kommando aus oder sende eine Nachricht
|
|
</entry>
|
|
</row>
|
|
<row>
|
|
<entry>Hoch / Runter</entry>
|
|
<entry>
|
|
Rufe das letzte Kommando/die letzte Nachricht wieder auf
|
|
</entry>
|
|
</row>
|
|
<row>
|
|
<entry>Strg + Hoch / Strg + Runter</entry>
|
|
<entry>
|
|
Rufe das letzte Kommando/die letzte Nachricht des globalen Buffers
|
|
wieder auf (für alle Buffer)
|
|
</entry>
|
|
</row>
|
|
<row>
|
|
<entry>Seite hoch / Seite runter</entry>
|
|
<entry>
|
|
Eine Seite hoch / runter im Verlauf des Buffers
|
|
</entry>
|
|
</row>
|
|
<row>
|
|
<entry>Alt + Seite hoch / Alt + Seite runter </entry>
|
|
<entry>
|
|
Ein paar Zeilen hoch / runter im Verlauf des Buffers
|
|
</entry>
|
|
</row>
|
|
<row>
|
|
<entry> Alt + Pos1 / Alt + Ende </entry>
|
|
<entry>
|
|
Gehe zum Anfang / Ende des Puffers
|
|
</entry>
|
|
</row>
|
|
<row>
|
|
<entry> F5 / Alt + Links </entry>
|
|
<entry>
|
|
Gehe zum vorherigen Puffer
|
|
</entry>
|
|
</row>
|
|
<row>
|
|
<entry>F6 / Alt + Rechts</entry>
|
|
<entry>
|
|
Gehe zum nächsten Puffer
|
|
</entry>
|
|
</row>
|
|
<row>
|
|
<entry>F7</entry>
|
|
<entry>
|
|
Schalte in das vorherige Fenster
|
|
</entry>
|
|
</row>
|
|
<row>
|
|
<entry>F8</entry>
|
|
<entry>
|
|
Schalte in das nächste Fenster
|
|
</entry>
|
|
</row>
|
|
<row>
|
|
<entry>F10</entry>
|
|
<entry>
|
|
Entferne den letzten Hinweis in der Infobar
|
|
</entry>
|
|
</row>
|
|
<row>
|
|
<entry>F11 / F12</entry>
|
|
<entry>
|
|
Blättere in der Nicklist
|
|
</entry>
|
|
</row>
|
|
<row>
|
|
<entry>Alt + F11 / Alt + F12</entry>
|
|
<entry>
|
|
Gehe zum Anfang / Ende der Nicklist
|
|
</entry>
|
|
</row>
|
|
<row>
|
|
<entry>Alt + A</entry>
|
|
<entry>
|
|
Schalte in den nächsten Puffer mit Aktivität
|
|
(mit der Priorität: highlight, message, other)
|
|
</entry>
|
|
</row>
|
|
<row>
|
|
<entry>Alt + B</entry>
|
|
<entry>
|
|
Gehe zum vorherigen Wort in der Kommandozeile
|
|
</entry>
|
|
</row>
|
|
<row>
|
|
<entry>Alt + D</entry>
|
|
<entry>
|
|
Lösche das nächste Wort in der Kommandozeile
|
|
</entry>
|
|
</row>
|
|
<row>
|
|
<entry>Alt + F</entry>
|
|
<entry>
|
|
Gehe zum nächsten Wort in der Kommandozeile
|
|
</entry>
|
|
</row>
|
|
<row>
|
|
<entry>Alt + H</entry>
|
|
<entry>
|
|
Lösche den Inhalt der Hotlist
|
|
(Aktivitätsanzeige für andere Puffer)
|
|
</entry>
|
|
</row>
|
|
<row>
|
|
<entry>Alt + J dann Alt + D</entry>
|
|
<entry>
|
|
Zeige den DCC-Puffer
|
|
</entry>
|
|
</row>
|
|
<row>
|
|
<entry>Alt + J dann Alt + L</entry>
|
|
<entry>
|
|
Schalte zum letzten Puffer
|
|
</entry>
|
|
</row>
|
|
<row>
|
|
<entry>Alt + J dann Alt + R</entry>
|
|
<entry>
|
|
Schalte in den reinen IRC-Daten Puffer
|
|
</entry>
|
|
</row>
|
|
<row>
|
|
<entry>Alt + J dann Alt + S</entry>
|
|
<entry>
|
|
Schalte in den Server-Puffer
|
|
</entry>
|
|
</row>
|
|
<row>
|
|
<entry>Alt + J dann Alt + X</entry>
|
|
<entry>
|
|
Schalte in den ersten Channel des nächsten Puffers
|
|
(oder in den Server-Puffer wenn keine Channel offen ist)
|
|
</entry>
|
|
</row>
|
|
<row>
|
|
<entry>Alt + Zahl (0-9)</entry>
|
|
<entry>
|
|
Schalte in den Puffer mit der Nummer (0 = 10)
|
|
</entry>
|
|
</row>
|
|
<row>
|
|
<entry>Alt + J dann eine Zahl (01-99)</entry>
|
|
<entry>
|
|
Schalte in den Puffer mit der Nummer
|
|
</entry>
|
|
</row>
|
|
<row>
|
|
<entry>Alt + K</entry>
|
|
<entry>
|
|
Setze den Keycode der nächsten Taste in der Kommandozeile
|
|
ein
|
|
</entry>
|
|
</row>
|
|
<row>
|
|
<entry>Alt + N</entry>
|
|
<entry>
|
|
Blättere zum nächsten Highlight
|
|
</entry>
|
|
</row>
|
|
<row>
|
|
<entry>Alt + P</entry>
|
|
<entry>
|
|
Blättere zum vorigen Highlight
|
|
</entry>
|
|
</row>
|
|
<row>
|
|
<entry>Alt + R</entry>
|
|
<entry>
|
|
Lösche die komplette Kommandozeile
|
|
</entry>
|
|
</row>
|
|
<row>
|
|
<entry>Alt + S</entry>
|
|
<entry>
|
|
Schalte zwischen den Servern im Server-Puffer hin und her
|
|
(wenn "look_one_server_buffer" angeschaltet ist)
|
|
</entry>
|
|
</row>
|
|
<row>
|
|
<entry>Alt + U</entry>
|
|
<entry>
|
|
Blättere zur ersten ungelesenen Zeile im Puffer
|
|
</entry>
|
|
</row>
|
|
<row>
|
|
<entry>Alt + W dann Alt + Pfeil</entry>
|
|
<entry>
|
|
Schalte zum Fenster in der entsprechenden Richtung
|
|
</entry>
|
|
</row>
|
|
</tbody>
|
|
</tgroup>
|
|
</informaltable>
|
|
</para>
|
|
|
|
</section>
|
|
|
|
<section id="secCommandLine">
|
|
<title> Kommandozeile </title>
|
|
|
|
<para>
|
|
Die WeeChat Kommandozeile (am Ende des Fensters) lässt sie Nachrichten an einen
|
|
Channel senden oder WeeChat- bzw. IRC-Kommandos ausführen
|
|
(siehe <xref linkend="secWeeChatIRCCommands" />).
|
|
</para>
|
|
|
|
<para>
|
|
Kommandos beginnen mit einem "/", gefolgt vom Namen des Kommandos.
|
|
Um zum Beispiel einen privaten Chat mit "<literal>toto</literal>" zu beginnen:
|
|
<screen><userinput>/query toto</userinput></screen>
|
|
</para>
|
|
|
|
<para>
|
|
Nachrichten an einen Channel sind jeder Text, der nicht mit einem "/" begint.
|
|
Um zum Beispiel den Text "<literal>hello</literal>" an den gegenwärtigen Channel
|
|
zu senden:
|
|
<screen><userinput>hello</userinput></screen>
|
|
</para>
|
|
|
|
<para>
|
|
Dennoch ist es möglich, eine Nachricht auch mit einem "/" zu beginnen, einfach
|
|
ein weiteres "/" voranstellen. Um zum Beispiel den Text "<literal>/query toto</literal>"
|
|
an den gegenwärtigen Channel zu senden:
|
|
<screen><userinput>//query toto</userinput></screen>
|
|
</para>
|
|
|
|
<para>
|
|
Wenn die Option IRC-Farben ("<literal>irc_colors_send</literal>") senden
|
|
angeschaltet ist, können sie Farbcodierung und Attribute wiefolgt verwenden:
|
|
<informaltable colsep="0" frame="none">
|
|
<tgroup cols="2">
|
|
<thead>
|
|
<row>
|
|
<entry>Code</entry>
|
|
<entry>Beschreibung</entry>
|
|
</row>
|
|
</thead>
|
|
<tbody>
|
|
<row>
|
|
<entry>%B</entry>
|
|
<entry>
|
|
Fett (bold)
|
|
</entry>
|
|
</row>
|
|
<row>
|
|
<entry>%Cxx</entry>
|
|
<entry>
|
|
Textfarbe "<literal>xx</literal>" (color)
|
|
(siehe Farbtabelle)
|
|
</entry>
|
|
</row>
|
|
<row>
|
|
<entry>%Cxx,yy</entry>
|
|
<entry>
|
|
Textfarbe "<literal>xx</literal>"
|
|
und Hintergrund "<literal>yy</literal>"
|
|
(siehe Farbtabelle)
|
|
</entry>
|
|
</row>
|
|
<row>
|
|
<entry>%O</entry>
|
|
<entry>
|
|
Schalte Farben und Attribute ab
|
|
</entry>
|
|
</row>
|
|
<row>
|
|
<entry>%R</entry>
|
|
<entry>
|
|
umgedrehte Farben (tausche Textfarbe mit Hintergrundfarbe)
|
|
</entry>
|
|
</row>
|
|
<row>
|
|
<entry>%U</entry>
|
|
<entry>
|
|
Unterstreiche Text
|
|
</entry>
|
|
</row>
|
|
<row>
|
|
<entry>%%</entry>
|
|
<entry>
|
|
Schreibe ein einzelnes "<literal>%</literal>"
|
|
</entry>
|
|
</row>
|
|
</tbody>
|
|
</tgroup>
|
|
</informaltable>
|
|
Hinweis: Der gleiche Farbcode (ohne die Nummer) kann zum Ausschalten
|
|
des Attributes verwendet werden.
|
|
</para>
|
|
|
|
<para>
|
|
Farbcodes für %C:
|
|
<informaltable colsep="0" frame="none">
|
|
<tgroup cols="2">
|
|
<thead>
|
|
<row>
|
|
<entry>Code</entry>
|
|
<entry>Farbe</entry>
|
|
</row>
|
|
</thead>
|
|
<tbody>
|
|
<row>
|
|
<entry>00</entry>
|
|
<entry>weiss</entry>
|
|
</row>
|
|
<row>
|
|
<entry>01</entry>
|
|
<entry>schwarz</entry>
|
|
</row>
|
|
<row>
|
|
<entry>02</entry>
|
|
<entry>dunkles Blau</entry>
|
|
</row>
|
|
<row>
|
|
<entry>03</entry>
|
|
<entry>dunkles Grün </entry>
|
|
</row>
|
|
<row>
|
|
<entry>04</entry>
|
|
<entry>helles Rot </entry>
|
|
</row>
|
|
<row>
|
|
<entry>05</entry>
|
|
<entry>dunkles Rot</entry>
|
|
</row>
|
|
<row>
|
|
<entry>06</entry>
|
|
<entry> Magenta </entry>
|
|
</row>
|
|
<row>
|
|
<entry>07</entry>
|
|
<entry> Orange </entry>
|
|
</row>
|
|
<row>
|
|
<entry>08</entry>
|
|
<entry> Gelb </entry>
|
|
</row>
|
|
<row>
|
|
<entry>09</entry>
|
|
<entry> helles Grün</entry>
|
|
</row>
|
|
<row>
|
|
<entry>10</entry>
|
|
<entry> Cyan </entry>
|
|
</row>
|
|
<row>
|
|
<entry>11</entry>
|
|
<entry> helles Cyan</entry>
|
|
</row>
|
|
<row>
|
|
<entry>12</entry>
|
|
<entry> helles Blau </entry>
|
|
</row>
|
|
<row>
|
|
<entry>13</entry>
|
|
<entry> helles Magenta </entry>
|
|
</row>
|
|
<row>
|
|
<entry>14</entry>
|
|
<entry> Grau </entry>
|
|
</row>
|
|
<row>
|
|
<entry>15</entry>
|
|
<entry> helles Grau (Weiss)</entry>
|
|
</row>
|
|
</tbody>
|
|
</tgroup>
|
|
</informaltable>
|
|
</para>
|
|
|
|
<para>
|
|
Beispiel: Anzeige von "<literal>hello everybody!</literal>" mit
|
|
"<literal>hello</literal>" fett in hellem Blau, und
|
|
"<literal>everybody</literal>" unterstrichen in hellem Rot:
|
|
<screen><userinput>%C12%Bhello%B%C04%U everybody%U%C!</userinput></screen>
|
|
</para>
|
|
|
|
</section>
|
|
|
|
<section id="secWeeChatIRCCommands">
|
|
<title>WeeChat / IRC Kommandos </title>
|
|
|
|
<para>
|
|
Dieses Kapitel listet alle WeeChat- und IRC-Kommandos auf.
|
|
</para>
|
|
|
|
<section id="secWeeChatCommands">
|
|
<title> WeeChat Kommandos </title>
|
|
|
|
<para>
|
|
&weechat_commands.xml;
|
|
</para>
|
|
|
|
</section>
|
|
|
|
<section id="secKeyFunctions">
|
|
<title> Funktionen </title>
|
|
|
|
<para>
|
|
<informaltable colsep="0" frame="none">
|
|
<tgroup cols="2">
|
|
<thead>
|
|
<row>
|
|
<entry> Funktion </entry>
|
|
<entry> Beschreibung </entry>
|
|
</row>
|
|
</thead>
|
|
<tbody>
|
|
|
|
&key_functions.xml;
|
|
|
|
</tbody>
|
|
</tgroup>
|
|
</informaltable>
|
|
</para>
|
|
|
|
</section>
|
|
|
|
<section id="secIRCCommands">
|
|
<title> IRC Kommandos </title>
|
|
|
|
<para>
|
|
&irc_commands.xml;
|
|
</para>
|
|
|
|
</section>
|
|
|
|
</section>
|
|
|
|
<section id="secConfigurationFile">
|
|
<title> Konfigurationsdatei </title>
|
|
|
|
<para>
|
|
Liste der Optionen für die Konfigurationsdatei:
|
|
<informaltable colsep="0" frame="none">
|
|
<tgroup cols="2">
|
|
<thead>
|
|
<row>
|
|
<entry> Option </entry>
|
|
<entry> Typ </entry>
|
|
<entry> Wert </entry>
|
|
<entry> Default </entry>
|
|
<entry> Beschreibung </entry>
|
|
</row>
|
|
</thead>
|
|
<tbody>
|
|
|
|
&config.xml;
|
|
|
|
</tbody>
|
|
</tgroup>
|
|
</informaltable>
|
|
</para>
|
|
|
|
<para>
|
|
Farben für die Curses GUI:
|
|
<informaltable colsep="0" frame="none">
|
|
<tgroup cols="2">
|
|
<thead>
|
|
<row>
|
|
<entry> Schlüsselwort </entry>
|
|
<entry> Farbe </entry>
|
|
</row>
|
|
</thead>
|
|
<tbody>
|
|
<row>
|
|
<entry><literal>default</literal></entry>
|
|
<entry>default Farbe (Transparent für den Hintergrund)</entry>
|
|
</row>
|
|
<row>
|
|
<entry><literal>black</literal></entry>
|
|
<entry> Schwarz </entry>
|
|
</row>
|
|
<row>
|
|
<entry><literal>red</literal></entry>
|
|
<entry> dunkles Rot </entry>
|
|
</row>
|
|
<row>
|
|
<entry><literal>lightred</literal></entry>
|
|
<entry> helles Rot </entry>
|
|
</row>
|
|
<row>
|
|
<entry><literal>green</literal></entry>
|
|
<entry> dunkles Grün </entry>
|
|
</row>
|
|
<row>
|
|
<entry><literal>lightgreen</literal></entry>
|
|
<entry> helles Grün </entry>
|
|
</row>
|
|
<row>
|
|
<entry><literal>brown</literal></entry>
|
|
<entry> Braun </entry>
|
|
</row>
|
|
<row>
|
|
<entry><literal>yellow</literal></entry>
|
|
<entry> Gelb </entry>
|
|
</row>
|
|
<row>
|
|
<entry><literal>blue</literal></entry>
|
|
<entry> dunkles Blau </entry>
|
|
</row>
|
|
<row>
|
|
<entry><literal>lightblue</literal></entry>
|
|
<entry> helles Blau </entry>
|
|
</row>
|
|
<row>
|
|
<entry><literal>magenta</literal></entry>
|
|
<entry> dunkles Magenta </entry>
|
|
</row>
|
|
<row>
|
|
<entry><literal>lightmagenta</literal></entry>
|
|
<entry> helles Magenta </entry>
|
|
</row>
|
|
<row>
|
|
<entry><literal>cyan</literal></entry>
|
|
<entry> dunkles Cyan </entry>
|
|
</row>
|
|
<row>
|
|
<entry><literal>lightcyan</literal></entry>
|
|
<entry> helles Cyan </entry>
|
|
</row>
|
|
<row>
|
|
<entry><literal>white</literal></entry>
|
|
<entry> Weiss </entry>
|
|
</row>
|
|
</tbody>
|
|
</tgroup>
|
|
</informaltable>
|
|
</para>
|
|
|
|
</section>
|
|
|
|
<section id="secFIFOpipe">
|
|
<title> Remote-Schnittstelle (FIFO pipe) </title>
|
|
|
|
<para>
|
|
Sie können WeeChat auch extern steuern, indem sie Kommandos oder Text
|
|
an eine sogen. pipe übergeben (sie müssen die Option "irc_fifo_pipe"
|
|
anschalten, die normalerweise abgeschaltet ist).
|
|
</para>
|
|
|
|
<para>
|
|
Diese pipe liegt in "<literal>~/.weechat/</literal>" und hat den Namen
|
|
"weechat_fifo_xxxxx" (das xxxxx ist die Prozess-ID (PID) eines laufenden WeeChat).
|
|
Wenn mehrere Instanzen von WeeChat laufen, sind mehrere pipes vorhanden, eine
|
|
für jede Instanz.
|
|
</para>
|
|
|
|
<para>
|
|
Der Syntax für ein pipe-Kommando ist:
|
|
<screen>server,channel *Text oder Kommando</screen>
|
|
wobei Server und Channel optional sind, aber wenn der Channel angegeben ist,
|
|
muss der Server auch angegeben werden.
|
|
</para>
|
|
|
|
<para>
|
|
Einige Beispiele:
|
|
<itemizedlist>
|
|
<listitem>
|
|
<para>
|
|
Ändern des Nicks auf freenode in "mynick|out" :
|
|
<screen><prompt>$ </prompt><userinput>echo 'freenode */nick mynick|out' >~/.weechat/weechat_fifo_12345</userinput></screen>
|
|
</para>
|
|
</listitem>
|
|
<listitem>
|
|
<para>
|
|
Senden einer Nachricht an #weechat:
|
|
<screen><prompt>$ </prompt><userinput>echo 'freenode,#weechat *hello everybody!' >~/.weechat/weechat_fifo_12345</userinput></screen>
|
|
</para>
|
|
</listitem>
|
|
<listitem>
|
|
<para>
|
|
Senden einer Nachricht an den gegenwärtigen Channel (Puffer, der in WeeChat angezeigt wird):
|
|
<screen><prompt>$ </prompt><userinput>echo '*hello!' >~/.weechat/weechat_fifo_12345</userinput></screen>
|
|
<emphasis>Warnung:</emphasis> Das ist gefährlich und sie sollten das nicht tun, ausgenommen sie wissen was sie tun!
|
|
</para>
|
|
</listitem>
|
|
<listitem>
|
|
<para>
|
|
Sende zwei Kommandos um (alle) Perl-Skripte abzuschalten/neu zu laden (getrennt durch ein "\n"):
|
|
<screen><prompt>$ </prompt><userinput>echo -e "freenode */perl unload\nfreenode */perl autoload" >~/.weechat/weechat_fifo_12345</userinput></screen>
|
|
</para>
|
|
</listitem>
|
|
</itemizedlist>
|
|
</para>
|
|
|
|
<para>
|
|
Sie können ein Skript schreiben, um ein Kommando an alle laufenden WeeChat-Instanzen zu senden,
|
|
zum Beispiel:
|
|
<screen>
|
|
#!/bin/sh
|
|
if [ $# -eq 1 ]; then
|
|
for fifo in $(/bin/ls ~/.weechat/weechat_fifo_* 2>/dev/null); do
|
|
echo -e "$1" >$fifo
|
|
done
|
|
fi
|
|
</screen>
|
|
Wenn das Skript "auto_weechat_command" heisst, können sie es folgendermassen aufrufen:
|
|
<screen><prompt>$ </prompt><userinput>./auto_weechat_command "freenode,#weechat *hello"</userinput></screen>
|
|
</para>
|
|
|
|
</section>
|
|
|
|
</chapter>
|
|
|
|
<!-- ============================ Extensions ============================ -->
|
|
|
|
<chapter id="chapPlugins">
|
|
<title>Plugins</title>
|
|
|
|
<para>
|
|
Dieses Kapitel beschreibt das Plugin-Interface (API) in WeeChat und die
|
|
Standard-Skriptplugins (Perl, Python, Ruby, Lua), die zu WeeChat gehören.
|
|
</para>
|
|
|
|
<section id="secPluginsInWeeChat">
|
|
<title>Plugins in WeeChat</title>
|
|
|
|
<para>
|
|
Ein Plugin ist ein C-Programm, dass WeeChat-Funktionen aufrufen kann,
|
|
die in einem Interface definiert sind.
|
|
</para>
|
|
|
|
<para>
|
|
Dieses C-Programm braucht nicht den Quellcode von WeeChat (aber die
|
|
API-Beschreibung) und kann dynamisch mit dem folgenden Kommando in
|
|
WeeChat geladen werden
|
|
<command>/plugin</command>.
|
|
</para>
|
|
|
|
<para>
|
|
Das Plugin muss in Form einer dynamischen Bibliothek vorliegen,
|
|
damit es das Betriebssystem dynamisch laden kann.
|
|
Unter GNU/Linux besitzt die Datei die Endung ".so", unter
|
|
Windows ".dll".
|
|
</para>
|
|
|
|
</section>
|
|
|
|
<section id="secWriteAPlugin">
|
|
<title> Ein Plugin schreiben </title>
|
|
|
|
<para>
|
|
Das Plugin muss die Datei "weechat-plugin.h" einbinden (verfügbar
|
|
im WeeChat-Quellcode).
|
|
Diese Datei definiert die Strukturen und Typen um mit WeeChat
|
|
zu kommunizieren.
|
|
</para>
|
|
|
|
<para>
|
|
Das Plugin muss einige Variablen und Funktionen besitzen
|
|
(nötig, sonst kann das Plugin nicht geladen werden):
|
|
<informaltable colsep="0" frame="none">
|
|
<tgroup cols="2">
|
|
<thead>
|
|
<row>
|
|
<entry>Variable</entry>
|
|
<entry> Beschreibung </entry>
|
|
</row>
|
|
</thead>
|
|
<tbody>
|
|
<row>
|
|
<entry><literal>char plugin_name[]</literal></entry>
|
|
<entry>Plugin Name</entry>
|
|
</row>
|
|
<row>
|
|
<entry><literal>char plugin_version[]</literal></entry>
|
|
<entry>Plugin Version</entry>
|
|
</row>
|
|
<row>
|
|
<entry><literal>char plugin_description[]</literal></entry>
|
|
<entry>kurze Beschreibung des Plugins</entry>
|
|
</row>
|
|
</tbody>
|
|
</tgroup>
|
|
</informaltable>
|
|
|
|
<informaltable colsep="0" frame="none">
|
|
<tgroup cols="2">
|
|
<thead>
|
|
<row>
|
|
<entry>Funktion</entry>
|
|
<entry>Beschreibung</entry>
|
|
</row>
|
|
</thead>
|
|
<tbody>
|
|
<row>
|
|
<entry><literal>int weechat_plugin_init (t_weechat_plugin *plugin)</literal></entry>
|
|
<entry>
|
|
Die Funktion wird aufgerufen, wenn das Plugin geladen wird.
|
|
Sie muss bei Erfolg PLUGIN_RC_OK, bei Fehlschlag PLUGIN_RC_KO
|
|
zurückgeben. (Bei einem Fehler wird das Plugin nicht geladen)
|
|
</entry>
|
|
</row>
|
|
<row>
|
|
<entry><literal>void weechat_plugin_end (t_weechat_plugin *plugin)</literal></entry>
|
|
<entry>Funktion wird beim Abschalten aufgerufen</entry>
|
|
</row>
|
|
</tbody>
|
|
</tgroup>
|
|
</informaltable>
|
|
</para>
|
|
|
|
<section id="secAPIFunctions">
|
|
<title>API Funktionen</title>
|
|
|
|
<!-- TRANSLATION NEEDED -->
|
|
<section id="secAPI_set_charset">
|
|
<title>set_charset</title>
|
|
|
|
<para>
|
|
Prototype:
|
|
<command>
|
|
void set_charset (t_weechat_plugin *plugin, char *charset)
|
|
</command>
|
|
</para>
|
|
<para>
|
|
Set new plugin charset.
|
|
</para>
|
|
<para>
|
|
Arguments:
|
|
<itemizedlist>
|
|
<listitem>
|
|
<para>
|
|
<option>plugin</option>: pointer to plugin structure
|
|
</para>
|
|
</listitem>
|
|
<listitem>
|
|
<para>
|
|
<option>charset</option>: new charset to use
|
|
</para>
|
|
</listitem>
|
|
</itemizedlist>
|
|
</para>
|
|
<para>
|
|
Example:
|
|
<screen>plugin->set_charset (plugin, "ISO-8859-1");</screen>
|
|
</para>
|
|
</section>
|
|
|
|
<!-- TRANSLATION NEEDED -->
|
|
<section id="secAPI_iconv_to_internal">
|
|
<title>iconv_to_internal</title>
|
|
|
|
<para>
|
|
Prototype:
|
|
<command>
|
|
void iconv_to_internal (t_weechat_plugin *plugin, char *charset,
|
|
char *string)
|
|
</command>
|
|
</para>
|
|
<para>
|
|
Convert string to WeeChat internal charset (UTF-8).
|
|
</para>
|
|
<para>
|
|
Arguments:
|
|
<itemizedlist>
|
|
<listitem>
|
|
<para>
|
|
<option>plugin</option>: pointer to plugin structure
|
|
</para>
|
|
</listitem>
|
|
<listitem>
|
|
<para>
|
|
<option>charset</option>: charset to convert
|
|
</para>
|
|
</listitem>
|
|
<listitem>
|
|
<para>
|
|
<option>string</option>: string to convert
|
|
</para>
|
|
</listitem>
|
|
</itemizedlist>
|
|
</para>
|
|
<para>
|
|
Return value: converted string.
|
|
</para>
|
|
<para>
|
|
Note: result has to be free by a call to "free" after use.
|
|
</para>
|
|
<para>
|
|
Example:
|
|
<screen>char *str = plugin->iconv_to_internal (plugin, "ISO-8859-1", "iso string: é à");</screen>
|
|
</para>
|
|
</section>
|
|
|
|
<!-- TRANSLATION NEEDED -->
|
|
<section id="secAPI_iconv_from_internal">
|
|
<title>iconv_from_internal</title>
|
|
|
|
<para>
|
|
Prototype:
|
|
<command>
|
|
void iconv_from_internal (t_weechat_plugin *plugin, char *charset,
|
|
char *string)
|
|
</command>
|
|
</para>
|
|
<para>
|
|
Convert string from internal WeeChat charset (UTF-8) to another.
|
|
</para>
|
|
<para>
|
|
Arguments:
|
|
<itemizedlist>
|
|
<listitem>
|
|
<para>
|
|
<option>plugin</option>: pointer to plugin structure
|
|
</para>
|
|
</listitem>
|
|
<listitem>
|
|
<para>
|
|
<option>charset</option>: target charset
|
|
</para>
|
|
</listitem>
|
|
<listitem>
|
|
<para>
|
|
<option>string</option>: string to convert
|
|
</para>
|
|
</listitem>
|
|
</itemizedlist>
|
|
</para>
|
|
<para>
|
|
Return value: converted string.
|
|
</para>
|
|
<para>
|
|
Note: result has to be free by a call to "free" after use.
|
|
</para>
|
|
<para>
|
|
Example:
|
|
<screen>char *str = plugin->iconv_from_internal (plugin, "ISO-8859-1", "utf-8 string: é à");</screen>
|
|
</para>
|
|
</section>
|
|
|
|
<section id="secAPI_ascii_strcasecmp">
|
|
<title>ascii_strcasecmp</title>
|
|
|
|
<para>
|
|
Prototyp:
|
|
<command>
|
|
int ascii_strcasecmp (t_weechat_plugin *plugin,
|
|
char *string1, char *string2)
|
|
</command>
|
|
</para>
|
|
<para>
|
|
Vergleich von Zeichenketten unabhängig von Sprache und Schreibweise (gross/klein).
|
|
</para>
|
|
<para>
|
|
Argumente:
|
|
<itemizedlist>
|
|
<listitem>
|
|
<para>
|
|
<option>plugin</option>: Zeiger auf Plugin-Struktur
|
|
</para>
|
|
</listitem>
|
|
<listitem>
|
|
<para>
|
|
<option>string1</option>: erste Zeichenkette des Vergleichs
|
|
</para>
|
|
</listitem>
|
|
<listitem>
|
|
<para>
|
|
<option>string2</option>: zweite Zeichenkette des Vergleichs
|
|
</para>
|
|
</listitem>
|
|
</itemizedlist>
|
|
</para>
|
|
<para>
|
|
Rückgabewert: Unterschied zwischen den zwei Zeichenketten: kleiner Null wenn
|
|
string1 < string2, Null wenn string1 == string2, grösser Null wenn string1 > string2
|
|
</para>
|
|
<para>
|
|
Beispiel:
|
|
<screen>if (plugin->ascii_strcasecmp (plugin, "abc", "def") != 0) ...</screen>
|
|
</para>
|
|
</section>
|
|
|
|
<section id="secAPI_ascii_strncasecmp">
|
|
<title>ascii_strncasecmp</title>
|
|
|
|
<para>
|
|
Prototyp:
|
|
<command>
|
|
int ascii_strncasecmp (t_weechat_plugin *plugin,
|
|
char *string1, char *string2, int max)
|
|
</command>
|
|
</para>
|
|
<para>
|
|
Vergleich von Zeichenketten unabhängig von Sprache und Schreibweise (gross/klein) für höchstens "max" Zeichen.
|
|
</para>
|
|
<para>
|
|
Argumente:
|
|
<itemizedlist>
|
|
<listitem>
|
|
<para>
|
|
<option>plugin</option>: Zeiger auf Plugin-Struktur
|
|
</para>
|
|
</listitem>
|
|
<listitem>
|
|
<para>
|
|
<option>string1</option>: erste Zeichenkette des Vergleichs
|
|
</para>
|
|
</listitem>
|
|
<listitem>
|
|
<para>
|
|
<option>string2</option>: zweite Zeichenkette des Vergleichs
|
|
</para>
|
|
</listitem>
|
|
<listitem>
|
|
<para>
|
|
<option>max</option>: maximale Zahl an Zeichen für den Vergleich
|
|
</para>
|
|
</listitem>
|
|
</itemizedlist>
|
|
</para>
|
|
<para>
|
|
Rückgabewert: Unterschied zwischen den zwei Zeichenketten: kleiner Null wenn
|
|
string1 < string2, Null wenn string1 == string2, grösser Null wenn string1 > string2
|
|
</para>
|
|
<para>
|
|
Beispiel:
|
|
<screen>if (plugin->ascii_strncasecmp (plugin, "abc", "def", 2) != 0) ...</screen>
|
|
</para>
|
|
</section>
|
|
|
|
<section id="secAPI_explode_string">
|
|
<title>explode_string</title>
|
|
|
|
<para>
|
|
Prototyp:
|
|
<command>
|
|
char **explode_string (t_weechat_plugin *plugin, char *string,
|
|
char *separators, int num_items_max, int *num_items)
|
|
</command>
|
|
</para>
|
|
<para>
|
|
Zerlege eine Zeichenkette entsprechend eines oder mehrerer Trennzeichen(s).
|
|
</para>
|
|
<para>
|
|
Argumente:
|
|
<itemizedlist>
|
|
<listitem>
|
|
<para>
|
|
<option>plugin</option>: Zeiger auf eine Plugin-Struktur
|
|
</para>
|
|
</listitem>
|
|
<listitem>
|
|
<para>
|
|
<option>string</option>: zu zerlegende Zeichenkette
|
|
</para>
|
|
</listitem>
|
|
<listitem>
|
|
<para>
|
|
<option>separators</option>: zu verwendende(s) Trennzeichen
|
|
</para>
|
|
</listitem>
|
|
<listitem>
|
|
<para>
|
|
<option>num_items_max</option>: maximale Anzahl an zu erzeugenden Teilen (0 = keine Grenze)
|
|
</para>
|
|
</listitem>
|
|
<listitem>
|
|
<para>
|
|
<option>num_items</option>: Zeiger auf eine int-Variable, die die Anzahl der erzeugten
|
|
Teile enthält
|
|
</para>
|
|
</listitem>
|
|
</itemizedlist>
|
|
</para>
|
|
<para>
|
|
Rückgabewert: ein Array von Zeichenketten, NULL bei Fehlern.
|
|
</para>
|
|
<para>
|
|
Hinweis: Das zurückgegebene Array muss nach der Benutzung mittels
|
|
"free_exloded_string" explizit freigegeben werden.
|
|
</para>
|
|
<para>
|
|
Beispiel:
|
|
<screen>
|
|
char **argv;
|
|
int argc;
|
|
argv = plugin->explode_string (plugin, string, " ", 0, &argc);
|
|
...
|
|
if (argv != NULL)
|
|
plugin->free_exploded_string (plugin, argv);
|
|
</screen>
|
|
</para>
|
|
</section>
|
|
|
|
<section id="secAPI_free_exploded_string">
|
|
<title>free_exploded_string</title>
|
|
|
|
<para>
|
|
Prototyp:
|
|
<command>
|
|
char **free_exploded_string (t_weechat_plugin *plugin,
|
|
char **string)
|
|
</command>
|
|
</para>
|
|
<para>
|
|
Gib ein Array frei, dass infolge der Zerlegung eines Strings reserviert wurde.
|
|
</para>
|
|
<para>
|
|
Argumente:
|
|
<itemizedlist>
|
|
<listitem>
|
|
<para>
|
|
<option>plugin</option>: Zeiger auf eine Plugin-Struktur
|
|
</para>
|
|
</listitem>
|
|
<listitem>
|
|
<para>
|
|
<option>string</option>: ein Array von Strings
|
|
</para>
|
|
</listitem>
|
|
</itemizedlist>
|
|
</para>
|
|
<para>
|
|
Rückgabewert: keiner (?).
|
|
</para>
|
|
<para>
|
|
Beispiel:
|
|
<screen>
|
|
char *argv;
|
|
int argc;
|
|
argv = plugin->explode_string (plugin, string, " ", 0, &argc);
|
|
...
|
|
if (argv != NULL)
|
|
plugin->free_exploded_string (plugin, argv);
|
|
</screen>
|
|
</para>
|
|
</section>
|
|
|
|
<section id="secAPI_mkdir_home">
|
|
<title>mkdir_home</title>
|
|
|
|
<para>
|
|
Prototyp:
|
|
<command>
|
|
int mkdir_home (t_weechat_plugin *plugin, char *directory)
|
|
</command>
|
|
</para>
|
|
<para>
|
|
Erzeugt ein Verzeichnis im WeeChat-Verzeichnis.
|
|
</para>
|
|
<para>
|
|
Argumente:
|
|
<itemizedlist>
|
|
<listitem>
|
|
<para>
|
|
<option>plugin</option>: Zeiger auf Pluginstrukur
|
|
</para>
|
|
</listitem>
|
|
<listitem>
|
|
<para>
|
|
<option>directory</option>: Verzeichnis, das erzeugt werden soll
|
|
</para>
|
|
</listitem>
|
|
</itemizedlist>
|
|
</para>
|
|
<para>
|
|
Rückgabewert: 1 wenn das Verzeichnis erfolgreich erstellt wurde, 0 wenn ein
|
|
Fehler aufgetreten ist.
|
|
</para>
|
|
<para>
|
|
Beispiel:
|
|
<screen>
|
|
if (!plugin->mkdir_home (plugin, "temp"))
|
|
plugin->print_server(plugin, "Konnte 'temp'-Verzeichnis im WeeChat-Verzeichnis nicht erstellen.");
|
|
</screen>
|
|
</para>
|
|
</section>
|
|
|
|
<section id="secAPI_exec_on_files">
|
|
<title>exec_on_files</title>
|
|
|
|
<para>
|
|
Prototyp:
|
|
<command>
|
|
void exec_on_files (t_weechat_plugin *plugin, char *repertoire,
|
|
int (*callback)(t_weechat_plugin *, char *))
|
|
</command>
|
|
</para>
|
|
<para>
|
|
Führe eine Funktion auf allen Dateien eines Verzeichnisses aus.
|
|
</para>
|
|
<para>
|
|
Argumente:
|
|
<itemizedlist>
|
|
<listitem>
|
|
<para>
|
|
<option>plugin</option>: Zeiger auf eine Plugin-Struktur
|
|
</para>
|
|
</listitem>
|
|
<listitem>
|
|
<para>
|
|
<option>directory</option>: Verzeichnis der zu verwendenden Dateien
|
|
</para>
|
|
</listitem>
|
|
<listitem>
|
|
<para>
|
|
<option>callback</option>: die anzuwendende Funktion
|
|
</para>
|
|
</listitem>
|
|
</itemizedlist>
|
|
</para>
|
|
<para>
|
|
Rückgabewert: keiner.
|
|
</para>
|
|
<para>
|
|
Beispiel:
|
|
<screen>
|
|
int callback (t_weechat_plugin *plugin, char *file)
|
|
{
|
|
plugin->print_server (plugin, "file: %s", file);
|
|
return 1;
|
|
}
|
|
...
|
|
plugin->exec_on_files (plugin, "/tmp", &callback);
|
|
</screen>
|
|
</para>
|
|
</section>
|
|
|
|
<section id="secAPI_print">
|
|
<title>print</title>
|
|
|
|
<para>
|
|
Prototyp:
|
|
<command>
|
|
void print (t_weechat_plugin *plugin,
|
|
char *server, char *channel, char *message, ...)
|
|
</command>
|
|
</para>
|
|
<para>
|
|
Sende eine Nachricht an einen WeeChat-Puffer, bezeichnet durch server
|
|
und channel (beide können NULL sein, dann wird der aktuelle Puffer verwendet).
|
|
</para>
|
|
<para>
|
|
Argumente:
|
|
<itemizedlist>
|
|
<listitem>
|
|
<para>
|
|
<option>plugin</option>: Zeiger auf Plugin-Struktur
|
|
</para>
|
|
</listitem>
|
|
<listitem>
|
|
<para>
|
|
<option>server</option>: interner Name des Servers, zu welchem der Puffer gehört, in dem die Nachricht
|
|
angezeigt werden soll (kann NULL sein)
|
|
</para>
|
|
</listitem>
|
|
<listitem>
|
|
<para>
|
|
<option>channel</option>: Name des Channels, in dem die Nachricht angezeigt werden soll (kann NULL sein)
|
|
</para>
|
|
</listitem>
|
|
<listitem>
|
|
<para>
|
|
<option>message</option>: Nachricht
|
|
</para>
|
|
</listitem>
|
|
</itemizedlist>
|
|
</para>
|
|
<para>
|
|
Rückgabewert: keiner.
|
|
</para>
|
|
<para>
|
|
Beispiele:
|
|
<screen>
|
|
plugin->print (plugin, NULL, NULL, "hello");
|
|
plugin->print (plugin, NULL, "#weechat", "hello");
|
|
plugin->print (plugin, "freenode", "#weechat", "hello");
|
|
</screen>
|
|
</para>
|
|
</section>
|
|
|
|
<section id="secAPI_print_server">
|
|
<title>print_server</title>
|
|
|
|
<para>
|
|
Prototyp:
|
|
<command>
|
|
void print_server (t_weechat_plugin *plugin,
|
|
char *message, ...)
|
|
</command>
|
|
</para>
|
|
<para>
|
|
Zeige eine Nachricht im aktuellen Server-Puffer.
|
|
</para>
|
|
<para>
|
|
Argumente:
|
|
<itemizedlist>
|
|
<listitem>
|
|
<para>
|
|
<option>plugin</option>: Zeiger auf eine Plugin-Struktur
|
|
</para>
|
|
</listitem>
|
|
<listitem>
|
|
<para>
|
|
<option>message</option>: Nachricht
|
|
</para>
|
|
</listitem>
|
|
</itemizedlist>
|
|
</para>
|
|
<para>
|
|
Rückgabewert: keiner.
|
|
</para>
|
|
<para>
|
|
Beispiel: <screen>plugin->print_server (plugin, "hello");</screen>
|
|
</para>
|
|
</section>
|
|
|
|
<section id="secAPI_print_infobar">
|
|
<title>print_infobar</title>
|
|
|
|
<para>
|
|
Prototyp:
|
|
<command>
|
|
void print_infobar (t_weechat_plugin *plugin,
|
|
int time, char *message, ...)
|
|
</command>
|
|
</para>
|
|
<para>
|
|
Zeige eine Nachricht in der Infobar für eine bestimmte Zeit
|
|
</para>
|
|
<para>
|
|
Argumente:
|
|
<itemizedlist>
|
|
<listitem>
|
|
<para>
|
|
<option>plugin</option>: Zeiger auf eine Plugin-Struktur
|
|
</para>
|
|
</listitem>
|
|
<listitem>
|
|
<para>
|
|
<option>time</option>: Zeitspanne für die Anzeige (in Sekunden, 0 = ständige Anzeige)
|
|
</para>
|
|
</listitem>
|
|
</itemizedlist>
|
|
</para>
|
|
<para>
|
|
Rückgabewert: keiner.
|
|
</para>
|
|
<para>
|
|
Beispiel:
|
|
<screen>
|
|
plugin->print_infobar (plugin, 5, "hello");
|
|
</screen>
|
|
</para>
|
|
</section>
|
|
|
|
<section id="secAPI_infobar_remove">
|
|
<title>infobar_remove</title>
|
|
|
|
<para>
|
|
Prototyp:
|
|
<command>
|
|
void infobar_remove (t_weechat_plugin *plugin, int count)
|
|
</command>
|
|
</para>
|
|
<para>
|
|
Entferne eine oder mehr Nachrichten aus der Infobar.
|
|
</para>
|
|
<para>
|
|
Argumente:
|
|
<itemizedlist>
|
|
<listitem>
|
|
<para>
|
|
<option>plugin</option>: Zeiger auf eine Plugin-Struktur
|
|
</para>
|
|
</listitem>
|
|
<listitem>
|
|
<para>
|
|
<option>count</option>: Anzahl der Nachrichten (wenn das Argument kleiner als Null ist, werden alle Nachrichten entfernt)
|
|
</para>
|
|
</listitem>
|
|
</itemizedlist>
|
|
</para>
|
|
<para>
|
|
Rückgabewert: keiner.
|
|
</para>
|
|
<para>
|
|
Beispiel: <screen>plugin->infobar_remove (1);</screen>
|
|
</para>
|
|
</section>
|
|
|
|
<section id="secAPI_log">
|
|
<title>log</title>
|
|
|
|
<para>
|
|
Prototyp:
|
|
<command>
|
|
void log (t_weechat_plugin *plugin,
|
|
char *server, char *channel, char *message, ...)
|
|
</command>
|
|
</para>
|
|
<para>
|
|
Schreibe eine Nachricht in die Log-Datei (für den entsprechenden Server/Channel).
|
|
</para>
|
|
<para>
|
|
Argumente:
|
|
<itemizedlist>
|
|
<listitem>
|
|
<para>
|
|
<option>plugin</option>: Zeiger auf eine Plugin-Struktur
|
|
</para>
|
|
</listitem>
|
|
<listitem>
|
|
<para>
|
|
<option>server</option>: interner Name des Servers, zu welchem der Log-Puffer gehört (kann NULL sein)
|
|
</para>
|
|
</listitem>
|
|
<listitem>
|
|
<para>
|
|
<option>channel</option>: Name des Channels, zu welchem der Log-Puffer gehört (kann NULL sein)
|
|
</para>
|
|
</listitem>
|
|
<listitem>
|
|
<para>
|
|
<option>message</option>: Nachricht
|
|
</para>
|
|
</listitem>
|
|
</itemizedlist>
|
|
</para>
|
|
<para>
|
|
Rückgabewert: keiner.
|
|
</para>
|
|
<para>
|
|
Beispiel:
|
|
<screen>
|
|
plugin->log (plugin, "freenode", "#weechat", "test");
|
|
</screen>
|
|
</para>
|
|
</section>
|
|
|
|
<section id="secAPI_msg_handler_add">
|
|
<title>msg_handler_add</title>
|
|
|
|
<para>
|
|
Prototyp:
|
|
<command>
|
|
t_plugin_handler *msg_handler_add (t_weechat_plugin
|
|
*plugin, char *message, t_plugin_handler_func *function,
|
|
char *handler_args, void *handler_pointer)
|
|
</command>
|
|
</para>
|
|
<para>
|
|
Erzeuge einen IRC-Message-Handler, der aufgerufen wird, wenn
|
|
eine Nachricht empfangen wird.
|
|
</para>
|
|
<para>
|
|
Argumente:
|
|
<itemizedlist>
|
|
<listitem>
|
|
<para>
|
|
<option>plugin</option>: Zeiger auf eine Plugin-Struktur
|
|
</para>
|
|
</listitem>
|
|
<listitem>
|
|
<para>
|
|
<option>message</option>: Name (Typ) der IRC-Nachricht.
|
|
Eine Liste der bekannten IRC-Nachrichten ist in den
|
|
<acronym>RFC</acronym>s
|
|
<ulink url="http://www.ietf.org/rfc/rfc1459.txt">1459</ulink> und
|
|
<ulink url="http://www.ietf.org/rfc/rfc2812.txt">2812</ulink> zu finden.
|
|
Weiterhin können sie einen speziellen Namen verwenden, der mit "weechat_" beginnt,
|
|
um spezielle Ereignisse zu bearbeiten, wie in der folgenden Tabelle aufgeführt:
|
|
<informaltable colsep="0" frame="none">
|
|
<tgroup cols="2">
|
|
<thead>
|
|
<row>
|
|
<entry>Name</entry>
|
|
<entry>Beschreibung</entry>
|
|
</row>
|
|
</thead>
|
|
<tbody>
|
|
<row>
|
|
<entry><literal>weechat_pv</literal></entry>
|
|
<entry>private Nachricht empfangen</entry>
|
|
</row>
|
|
<row>
|
|
<entry><literal>weechat_highlight</literal></entry>
|
|
<entry>
|
|
hervorgehobene Nachricht (in einem Channel oder privatem Chat)
|
|
</entry>
|
|
</row>
|
|
<row>
|
|
<entry><literal>weechat_ctcp</literal></entry>
|
|
<entry>
|
|
CTCP-Nachricht empfangen (VERSION, PING, ...)
|
|
</entry>
|
|
</row>
|
|
<row>
|
|
<entry><literal>weechat_dcc</literal></entry>
|
|
<entry>
|
|
DCC-Nachricht empfangen (Chat oder Datei)
|
|
</entry>
|
|
</row>
|
|
</tbody>
|
|
</tgroup>
|
|
</informaltable>
|
|
</para>
|
|
</listitem>
|
|
<listitem>
|
|
<para>
|
|
<option>function</option>: Funktion, die aufgerufen wird, wenn eine Nachricht empfangen wurde
|
|
</para>
|
|
<para>
|
|
Sie verwendet den folgenden Prototyp:
|
|
<command>
|
|
int my_function (t_weechat_plugin *plugin,
|
|
int argc, char **argv,
|
|
char *handler_args, void *handler_pointer)
|
|
</command>
|
|
</para>
|
|
<para>
|
|
Argument argc ist auf 3 gesetzt, die folgenden Werte sind im argv-Array:
|
|
<itemizedlist>
|
|
<listitem>
|
|
<para>argv[0] = Server Name</para>
|
|
</listitem>
|
|
<listitem>
|
|
<para>argv[1] = IRC Nachricht</para>
|
|
</listitem>
|
|
<listitem>
|
|
<para>argv[2] = Kommando Argumente</para>
|
|
</listitem>
|
|
</itemizedlist>
|
|
</para>
|
|
</listitem>
|
|
<listitem>
|
|
<para>
|
|
<option>handler_args</option>: Argumente, die beim Aufruf an die Funktion übergeben werden
|
|
</para>
|
|
</listitem>
|
|
<listitem>
|
|
<para>
|
|
<option>handler_pointer</option>: pointer given to function when called
|
|
<option>handler_pointer</option>: Zeiger, der an die Funktion übergeben wird
|
|
</para>
|
|
</listitem>
|
|
</itemizedlist>
|
|
</para>
|
|
<para>
|
|
Rückgabewert: Zeiger auf den neuen Handler
|
|
</para>
|
|
<para>
|
|
Hinweis: die Funktion, die aufgerufen wird wenn eine Nachricht empfangen wurde,
|
|
muss einen der folgenden Werte zurückgeben:
|
|
<itemizedlist>
|
|
<listitem>
|
|
<para>
|
|
<literal>PLUGIN_RC_KO</literal>: Funktion ist fehlgschlagen
|
|
</para>
|
|
</listitem>
|
|
<listitem>
|
|
<para>
|
|
<literal>PLUGIN_RC_OK</literal>: Funktion war erfolgreich
|
|
</para>
|
|
</listitem>
|
|
<listitem>
|
|
<para>
|
|
<literal>PLUGIN_RC_OK_IGNORE_WEECHAT</literal>: Die Nachricht wird nicht an WeeChat übergeben
|
|
</para>
|
|
</listitem>
|
|
<listitem>
|
|
<para>
|
|
<literal>PLUGIN_RC_OK_IGNORE_PLUGINS</literal>: Die Nachricht wird nicht an andere Plugins weitergegeben
|
|
</para>
|
|
</listitem>
|
|
<listitem>
|
|
<para>
|
|
<literal>PLUGIN_RC_OK_IGNORE_ALL</literal>: Die Nachricht wird weder an WeeChat noch an andere
|
|
Plugins weitergegeben
|
|
</para>
|
|
</listitem>
|
|
</itemizedlist>
|
|
</para>
|
|
<para>
|
|
Beispiel:
|
|
<screen>
|
|
int msg_kick (t_weechat_plugin *plugin, int argc, char **argv,
|
|
char *handler_args, void *handler_pointer)
|
|
{
|
|
plugin->print (plugin, argv[0], NULL, "KICK received");
|
|
return PLUGIN_RC_OK;
|
|
}
|
|
...
|
|
t_plugin_handler *msg_handler;
|
|
msg_handler = plugin->msg_handler_add (plugin, "KICK",
|
|
&msg_kick, NULL, NULL);
|
|
</screen>
|
|
</para>
|
|
</section>
|
|
|
|
<section id="secAPI_cmd_handler_add">
|
|
<title>cmd_handler_add</title>
|
|
|
|
<para>
|
|
Prototyp:
|
|
<command>
|
|
t_plugin_handler *cmd_handler_add (t_weechat_plugin
|
|
*plugin, char *command, char *description, char *arguments,
|
|
char *arguments_description, char *completion_template,
|
|
t_plugin_handler_func *fonction, char *handler_args,
|
|
void *handler_pointer)
|
|
</command>
|
|
</para>
|
|
<para>
|
|
Erzeugt einen Handler für ein WeeChat-Kommando, der aufgerufen wird, wenn
|
|
der Anwender das Kommando ausführt (Beispiel: /command).
|
|
</para>
|
|
<para>
|
|
Argumente:
|
|
<itemizedlist>
|
|
<listitem>
|
|
<para>
|
|
<option>plugin</option>: Zeiger auf eine Plugin-Struktur
|
|
</para>
|
|
</listitem>
|
|
<listitem>
|
|
<para>
|
|
<option>command</option>: Name des neuen Kommandos, der auch Name eines bereits existierenden Kommandos
|
|
sein kann (mit Bedacht zu verwenden, das ersetzte Kommando ist nicht verfügbar, bis das Plugin entfernt
|
|
wurde)
|
|
</para>
|
|
</listitem>
|
|
<listitem>
|
|
<para>
|
|
<option>description</option>: kurze Beschreibung des Kommandos (angezeigt beim Ausführen von /help command)
|
|
</para>
|
|
</listitem>
|
|
<listitem>
|
|
<para>
|
|
<option>arguments</option>: kurze Beschreibung der Argumente des Kommandos (angezeigt beim Ausführen von /help command)
|
|
</para>
|
|
</listitem>
|
|
<listitem>
|
|
<para>
|
|
<option>arguments_description</option>: lange Beschreibung der Argumente des Kommandos (angezeigt beim Ausführen von /help command)
|
|
</para>
|
|
</listitem>
|
|
<listitem>
|
|
<para>
|
|
<option>completion_template</option>: Vorlage für die Vervollständigung; zum Beispiel
|
|
bedeutet "<literal>abc|%w def|%i</literal>", dass das erste Argument "abc" oder ein
|
|
WeeChat-Kommando sein kann und das zweite Argument "def" oder ein IRC-Kommando.
|
|
Eine leere Zeichenkette bedeutet, dass WeeChat für jedes Argument einen Nicknamen
|
|
des gegenwärtigen Channels einsetzt, ein NULL oder "-" schaltet die Vervollständigung
|
|
für alle Argumente ab.
|
|
</para>
|
|
<para>
|
|
Die folgenden Ersetzungen können verwendet werden:
|
|
<informaltable colsep="0" frame="none">
|
|
<tgroup cols="2">
|
|
<thead>
|
|
<row>
|
|
<entry>Code</entry>
|
|
<entry>Beschreibung</entry>
|
|
</row>
|
|
</thead>
|
|
<tbody>
|
|
<row>
|
|
<entry><literal>%-</literal></entry>
|
|
<entry>keine Vervollständigung für das Argument</entry>
|
|
</row>
|
|
<row>
|
|
<entry><literal>%a</literal></entry>
|
|
<entry>Alias</entry>
|
|
</row>
|
|
<row>
|
|
<entry><literal>%A</literal></entry>
|
|
<entry>
|
|
Aliase und Kommandos (WeeChat, IRC und Plugins)
|
|
</entry>
|
|
</row>
|
|
<row>
|
|
<entry><literal>%c</literal></entry>
|
|
<entry>gegenwärtiger Channel</entry>
|
|
</row>
|
|
<row>
|
|
<entry><literal>%C</literal></entry>
|
|
<entry>Channels des gegenwärtigen Servers</entry>
|
|
</row>
|
|
<!-- <row>
|
|
<entry><literal>%f</literal></entry>
|
|
<entry>file name</entry>
|
|
</row> -->
|
|
<row>
|
|
<entry><literal>%h</literal></entry>
|
|
<entry>Plugin Kommandos</entry>
|
|
</row>
|
|
<row>
|
|
<entry><literal>%i</literal></entry>
|
|
<entry>IRC Kommandos (senden)</entry>
|
|
</row>
|
|
<row>
|
|
<entry><literal>%I</literal></entry>
|
|
<entry>IRC Kommandos (empfangen)</entry>
|
|
</row>
|
|
<row>
|
|
<entry><literal>%k</literal></entry>
|
|
<entry>Grundfunktionen</entry>
|
|
</row>
|
|
<row>
|
|
<entry><literal>%m</literal></entry>
|
|
<entry>Nicknamen des gegenwärtigen Servers</entry>
|
|
</row>
|
|
<row>
|
|
<entry><literal>%n</literal></entry>
|
|
<entry>Nicknamen des gegenwärtigen Channels</entry>
|
|
</row>
|
|
<row>
|
|
<entry><literal>%N</literal></entry>
|
|
<entry>Nicknamen und Hostnamen des gegenwärtigen Channels</entry>
|
|
</row>
|
|
<row>
|
|
<entry><literal>%o</literal></entry>
|
|
<entry>Konfigurationseinstellungen</entry>
|
|
</row>
|
|
<row>
|
|
<entry><literal>%O</literal></entry>
|
|
<entry>Plugin Optionen</entry>
|
|
</row>
|
|
<row>
|
|
<entry><literal>%p</literal></entry>
|
|
<entry>Standard "part" Nachricht</entry>
|
|
</row>
|
|
<row>
|
|
<entry><literal>%q</literal></entry>
|
|
<entry>Standard "quit" Nachricht</entry>
|
|
</row>
|
|
<row>
|
|
<entry><literal>%s</literal></entry>
|
|
<entry>Name des gegenwärtigen Servers</entry>
|
|
</row>
|
|
<row>
|
|
<entry><literal>%S</literal></entry>
|
|
<entry>Namen aller definierten Server</entry>
|
|
</row>
|
|
<row>
|
|
<entry><literal>%t</literal></entry>
|
|
<entry>Topic des gegenwärtigen Channels</entry>
|
|
</row>
|
|
<row>
|
|
<entry><literal>%v</literal></entry>
|
|
<entry>Wert einer Konfigurationseinstellung</entry>
|
|
</row>
|
|
<row>
|
|
<entry><literal>%V</literal></entry>
|
|
<entry>Wert einer Plugin-Option</entry>
|
|
</row>
|
|
<row>
|
|
<entry><literal>%w</literal></entry>
|
|
<entry>WeeChat Kommandos</entry>
|
|
</row>
|
|
</tbody>
|
|
</tgroup>
|
|
</informaltable>
|
|
</para>
|
|
</listitem>
|
|
<listitem>
|
|
<para>
|
|
<option>function</option>: Funktion, die aufgerufen wird, wenn das Kommando ausgeführt wird
|
|
</para>
|
|
<para>
|
|
Sie verwendet den folgenden Prototypen:
|
|
<command>
|
|
int my_function (t_weechat_plugin *plugin,
|
|
int argc, char **argv,
|
|
char *handler_args, void *handler_pointer)
|
|
</command>
|
|
</para>
|
|
<para>
|
|
Das Argument argc ist auf 3 gesetzt, das Array argv enthält die folgenden Werte:
|
|
<itemizedlist>
|
|
<listitem>
|
|
<para>argv[0] = Server Name</para>
|
|
</listitem>
|
|
<listitem>
|
|
<para>argv[1] = Kommando</para>
|
|
</listitem>
|
|
<listitem>
|
|
<para>argv[2] = Kommando-Argumente</para>
|
|
</listitem>
|
|
</itemizedlist>
|
|
</para>
|
|
</listitem>
|
|
<listitem>
|
|
<para>
|
|
<option>handler_args</option>: Argumente, die an die Funktion übergeben werden
|
|
</para>
|
|
</listitem>
|
|
<listitem>
|
|
<para>
|
|
<option>handler_pointer</option>: Zeiger, der an die Funktion übergeben wird
|
|
</para>
|
|
</listitem>
|
|
</itemizedlist>
|
|
</para>
|
|
<para>
|
|
Rückgabewert: Zeiger auf den neuen Kommando-Handler.
|
|
</para>
|
|
<para>
|
|
Hinweis: die Funktion, die aufgerufen wird, wenn das Kommando ausgeführt wird,
|
|
muss einen der folgende Werte zurückgeben:
|
|
<itemizedlist>
|
|
<listitem>
|
|
<para>
|
|
<literal>PLUGIN_RC_KO</literal>: Funktion ist fehlgeschlagen
|
|
</para>
|
|
</listitem>
|
|
<listitem>
|
|
<para>
|
|
<literal>PLUGIN_RC_OK</literal>: Funktion war erfolgreich
|
|
</para>
|
|
</listitem>
|
|
</itemizedlist>
|
|
</para>
|
|
<para>
|
|
Beispiel:
|
|
<screen>
|
|
int cmd_test (t_weechat_plugin *plugin, int argc, char **argv,
|
|
char *handler_args, void *handler_pointer)
|
|
{
|
|
plugin->print (plugin, argv[0], NULL,
|
|
"test command, nick: %s",
|
|
(argv[2]) ? argv[2] : "none");
|
|
return PLUGIN_RC_OK;
|
|
}
|
|
...
|
|
t_plugin_handler *cmd_handler;
|
|
cmd_handler = plugin->cmd_handler_add (plugin, "test", "Test command",
|
|
"[nick]", "nick: nick of channel",
|
|
"%n", &cmd_test, NULL, NULL);
|
|
</screen>
|
|
</para>
|
|
</section>
|
|
|
|
<section id="secAPI_timer_handler_add">
|
|
<title>timer_handler_add</title>
|
|
|
|
<para>
|
|
Prototyp:
|
|
<command>
|
|
t_plugin_handler *timer_handler_add (t_weechat_plugin
|
|
*plugin, int interval, t_plugin_handler_func *function,
|
|
char *handler_args, void *handler_pointer)
|
|
</command>
|
|
</para>
|
|
<para>
|
|
Erzeuge einen zeitgesteuerten Handler, der periodisch
|
|
eine Funktion aufruft.
|
|
</para>
|
|
<para>
|
|
Argumente:
|
|
<itemizedlist>
|
|
<listitem>
|
|
<para>
|
|
<option>plugin</option>: Zeiger auf eine Plugin-Struktur
|
|
</para>
|
|
</listitem>
|
|
<listitem>
|
|
<para>
|
|
<option>interval</option>: Intervall (in Secunden) zwischen zwei Aufrufen der Funktion
|
|
</para>
|
|
</listitem>
|
|
<listitem>
|
|
<para>
|
|
<option>function</option>: Funktion, die aufgerufen wird
|
|
</para>
|
|
<para>
|
|
Sie verwendet den folgenden Prototypen:
|
|
<command>
|
|
int my_function (t_weechat_plugin *plugin,
|
|
int argc, char **argv,
|
|
char *handler_args, void *handler_pointer)
|
|
</command>
|
|
</para>
|
|
<para>
|
|
Das Argument argc ist auf 0 gesetzt und argv ist auf NULL gesetzt.
|
|
</para>
|
|
</listitem>
|
|
<listitem>
|
|
<para>
|
|
<option>handler_args</option>: Argumente der aufgerufenen Funktion
|
|
</para>
|
|
</listitem>
|
|
<listitem>
|
|
<para>
|
|
<option>handler_pointer</option>: Zeiger, der an die Funktion übergeben wird
|
|
</para>
|
|
</listitem>
|
|
</itemizedlist>
|
|
</para>
|
|
<para>
|
|
Rückgabewert: Zeiger auf den neuen timer-Handler.
|
|
</para>
|
|
<para>
|
|
Hinweis: die Funktion, die aufgerufen wird, muss einen der folgende Werte zurückgeben:
|
|
<itemizedlist>
|
|
<listitem>
|
|
<para>
|
|
<literal>PLUGIN_RC_KO</literal>: Funktion ist fehlgeschlagen
|
|
</para>
|
|
</listitem>
|
|
<listitem>
|
|
<para>
|
|
<literal>PLUGIN_RC_OK</literal>: Funktion war erfolgreich
|
|
</para>
|
|
</listitem>
|
|
</itemizedlist>
|
|
</para>
|
|
<para>
|
|
Beispiel:
|
|
<screen>
|
|
int my_timer (t_weechat_plugin *plugin, int argc, char **argv,
|
|
char *handler_args, void *handler_pointer)
|
|
{
|
|
plugin->print (plugin, NULL, NULL, "my timer");
|
|
return PLUGIN_RC_OK;
|
|
}
|
|
...
|
|
t_plugin_handler *timer_handler;
|
|
timer_handler = plugin->timer_handler_add (plugin, 60, &my_timer);
|
|
</screen>
|
|
</para>
|
|
</section>
|
|
|
|
<section id="secAPI_keyboard_handler_add">
|
|
<title>keyboard_handler_add</title>
|
|
|
|
<para>
|
|
Prototyp:
|
|
<command>
|
|
t_plugin_handler *keyboard_handler_add (t_weechat_plugin
|
|
*plugin, t_plugin_handler_func *function,
|
|
char *handler_args, void *handler_pointer)
|
|
</command>
|
|
</para>
|
|
<para>
|
|
Erzeugt einen Keyboard-Handler, der nach dem Drücken einer Taste aufgerufen wird.
|
|
</para>
|
|
<para>
|
|
Argumente:
|
|
<itemizedlist>
|
|
<listitem>
|
|
<para>
|
|
<option>plugin</option>: Zeiger auf eine Plugin-Struktur
|
|
</para>
|
|
</listitem>
|
|
<listitem>
|
|
<para>
|
|
<option>function</option>: Die Funktion, die aufgerufen wird
|
|
</para>
|
|
<para>
|
|
Sie verwendet den folgenden Prototypen:
|
|
<command>
|
|
int my_function (t_weechat_plugin *plugin,
|
|
int argc, char **argv,
|
|
char *handler_args, void *handler_pointer)
|
|
</command>
|
|
</para>
|
|
<para>
|
|
Das Argument argc ist auf 3 gesetzt, argv enthält die folgenden Werte:
|
|
<itemizedlist>
|
|
<listitem>
|
|
<para>
|
|
argv[0] = Taste, die gedrückt wurde
|
|
(Name der internen Funktion oder '*' gefolgt von einem Tastaturcode)
|
|
</para>
|
|
</listitem>
|
|
<listitem>
|
|
<para>
|
|
argv[1] = Kommandozeile vor dem Tastendruck
|
|
</para>
|
|
</listitem>
|
|
<listitem>
|
|
<para>
|
|
argv[2] = Kommandozeile nach dem Tastendruck
|
|
</para>
|
|
</listitem>
|
|
</itemizedlist>
|
|
</para>
|
|
</listitem>
|
|
<listitem>
|
|
<para>
|
|
<option>handler_args</option>: Argumente, die bei Aufruf der Funktion übergeben
|
|
werden
|
|
</para>
|
|
</listitem>
|
|
<listitem>
|
|
<para>
|
|
<option>handler_pointer</option>: Zeiger auf die Funktion, der bei Aufruf übergeben
|
|
wird
|
|
</para>
|
|
</listitem>
|
|
</itemizedlist>
|
|
</para>
|
|
<para>
|
|
Rückgabewert: Zeiger auf den Handler.
|
|
</para>
|
|
<para>
|
|
Hinweis: Die aufgerufene Funktion muss einen der folgenden Werte zurückgeben:
|
|
<itemizedlist>
|
|
<listitem>
|
|
<para>
|
|
<literal>PLUGIN_RC_KO</literal>: Funktion ist fehlgeschlagen
|
|
</para>
|
|
</listitem>
|
|
<listitem>
|
|
<para>
|
|
<literal>PLUGIN_RC_OK</literal>: Funktion war erfolgreich
|
|
</para>
|
|
</listitem>
|
|
</itemizedlist>
|
|
</para>
|
|
<para>
|
|
Beispiel:
|
|
<screen>
|
|
int my_keyb (t_weechat_plugin *plugin, int argc, char **argv,
|
|
char *handler_args, void *handler_pointer)
|
|
{
|
|
if (argc == 2)
|
|
{
|
|
plugin->print (plugin, NULL, NULL, "key pressed: %s", argv[0]);
|
|
if (argv[1] && (argv[1][0] == '1'))
|
|
plugin->print (plugin, NULL, NULL, "input text changed");
|
|
else
|
|
plugin->print (plugin, NULL, NULL, "input text not changed");
|
|
}
|
|
return PLUGIN_RC_OK;
|
|
}
|
|
...
|
|
t_plugin_handler *keyb_handler;
|
|
keyb_handler = plugin->keyboard_handler_add (plugin, &my_keyb);
|
|
</screen>
|
|
</para>
|
|
</section>
|
|
|
|
<section id="secAPI_handler_remove">
|
|
<title>handler_remove</title>
|
|
|
|
<para>
|
|
Prototyp:
|
|
<command>
|
|
void handler_remove (t_weechat_plugin *plugin,
|
|
t_plugin_handler *handler)
|
|
</command>
|
|
</para>
|
|
<para>
|
|
Entfernt einen Nachrichten- oder Kommando-Handler.
|
|
</para>
|
|
<para>
|
|
Argumente:
|
|
<itemizedlist>
|
|
<listitem>
|
|
<para>
|
|
<option>plugin</option>: Zeiger auf eine Plugin-Struktur
|
|
</para>
|
|
</listitem>
|
|
<listitem>
|
|
<para>
|
|
<option>handler</option>: Handler, der entfernt werden soll
|
|
</para>
|
|
</listitem>
|
|
</itemizedlist>
|
|
</para>
|
|
<para>
|
|
Rückgabewert: keiner
|
|
</para>
|
|
<para>
|
|
Beispiel:
|
|
<screen>plugin->handler_remove (plugin, my_handler);</screen>
|
|
</para>
|
|
</section>
|
|
|
|
<section id="secAPI_handler_remove_all">
|
|
<title>handler_remove_all</title>
|
|
|
|
<para>
|
|
Prototyp:
|
|
<command>
|
|
void handler_remove_all (t_weechat_plugin *plugin)
|
|
</command>
|
|
</para>
|
|
<para>
|
|
Entfernt alle Handler eines Plugins.
|
|
</para>
|
|
<para>
|
|
Argumente:
|
|
<itemizedlist>
|
|
<listitem>
|
|
<para>
|
|
<option>plugin</option>: Zeiger auf eine Plugin-Struktur
|
|
</para>
|
|
</listitem>
|
|
</itemizedlist>
|
|
</para>
|
|
<para>
|
|
Rückgabewert: keiner
|
|
</para>
|
|
<para>
|
|
Beispiel:
|
|
<screen>plugin->handler_remove_all (plugin);</screen>
|
|
</para>
|
|
</section>
|
|
|
|
<!-- TRANSLATION NEEDED -->
|
|
<section id="secAPI_modifier_add">
|
|
<title>modifier_add</title>
|
|
|
|
<para>
|
|
Prototype:
|
|
<command>
|
|
t_plugin_modifier *modifier_add (t_weechat_plugin *plugin,
|
|
char *type, char *message, t_plugin_modifier_func *function,
|
|
char *modifier_args, void *modifier_pointer)
|
|
</command>
|
|
</para>
|
|
<para>
|
|
Add a message modifier.
|
|
</para>
|
|
<para>
|
|
Arguments:
|
|
<itemizedlist>
|
|
<listitem>
|
|
<para>
|
|
<option>plugin</option>: pointer to plugin structure
|
|
</para>
|
|
</listitem>
|
|
<listitem>
|
|
<para>
|
|
<option>type</option>: modifier type:
|
|
<informaltable colsep="0" frame="none">
|
|
<tgroup cols="2">
|
|
<thead>
|
|
<row>
|
|
<entry>Type</entry>
|
|
<entry>Description</entry>
|
|
</row>
|
|
</thead>
|
|
<tbody>
|
|
<row>
|
|
<entry><literal>irc_in</literal></entry>
|
|
<entry>called for incoming IRC messages</entry>
|
|
</row>
|
|
<row>
|
|
<entry><literal>irc_user</literal></entry>
|
|
<entry>
|
|
called for each user message (or command) (before
|
|
WeeChat parses message)
|
|
</entry>
|
|
</row>
|
|
<row>
|
|
<entry><literal>irc_out</literal></entry>
|
|
<entry>
|
|
called for outgoing messages, immediately before
|
|
sending it to IRC server (this includes messages
|
|
sent automatically by WeeChat to server)
|
|
</entry>
|
|
</row>
|
|
</tbody>
|
|
</tgroup>
|
|
</informaltable>
|
|
</para>
|
|
</listitem>
|
|
<listitem>
|
|
<para>
|
|
<option>message</option>: name of IRC message (used only for
|
|
types "irc_in" and "irc_out").
|
|
To know list of IRC messages, please consult
|
|
<acronym>RFC</acronym>s
|
|
<ulink url="http://www.ietf.org/rfc/rfc1459.txt">1459</ulink> and
|
|
<ulink url="http://www.ietf.org/rfc/rfc2812.txt">2812</ulink>.
|
|
Moreover, special value "*" means all messages (no filter).
|
|
</para>
|
|
</listitem>
|
|
<listitem>
|
|
<para>
|
|
<option>function</option>: function called
|
|
</para>
|
|
<para>
|
|
It uses following prototype:
|
|
<command>
|
|
int my_function (t_weechat_plugin *plugin,
|
|
int argc, char **argv,
|
|
char *modifier_args, void *modifier_pointer)
|
|
</command>
|
|
</para>
|
|
<para>
|
|
Argument argc is set to 2, following values are set in
|
|
argv array:
|
|
<itemizedlist>
|
|
<listitem>
|
|
<para>argv[0] = server name</para>
|
|
</listitem>
|
|
<listitem>
|
|
<para>argv[1] = message</para>
|
|
</listitem>
|
|
</itemizedlist>
|
|
</para>
|
|
</listitem>
|
|
<listitem>
|
|
<para>
|
|
<option>modifier_args</option>: arguments given to function
|
|
when called
|
|
</para>
|
|
</listitem>
|
|
<listitem>
|
|
<para>
|
|
<option>modifier_pointer</option>: pointer given to function
|
|
when called
|
|
</para>
|
|
</listitem>
|
|
</itemizedlist>
|
|
</para>
|
|
<para>
|
|
Return value: pointer to new message modifier.
|
|
</para>
|
|
<para>
|
|
Note: function has to return modified string, or NULL if no
|
|
changes are made to message.
|
|
If function returns empty string, then message is dropped and
|
|
will not be read at all by WeeChat (be careful when dropping
|
|
messages!).
|
|
Returned string must have been allocated by malloc() and will
|
|
be freed (with call to free()) automatically by WeeChat after use.
|
|
</para>
|
|
<para>
|
|
Example:
|
|
<screen>
|
|
char *adder (t_weechat_plugin *plugin, int argc, char **argv,
|
|
char *modifier_args, void *modifier_pointer)
|
|
{
|
|
char *string;
|
|
string = (char *)malloc (strlen (argv[1]) + 16);
|
|
strcpy (string, argv[1]);
|
|
strcat (string, "test");
|
|
return string;
|
|
}
|
|
...
|
|
t_plugin_modifier *modifier;
|
|
modifier = plugin->modifier_add (plugin, "irc_in", "privmsg",
|
|
&adder, NULL, NULL);
|
|
</screen>
|
|
</para>
|
|
</section>
|
|
|
|
<!-- TRANSLATION NEEDED -->
|
|
<section id="secAPI_modifier_remove">
|
|
<title>modifier_remove</title>
|
|
|
|
<para>
|
|
Prototype:
|
|
<command>
|
|
void modifier_remove (t_weechat_plugin *plugin,
|
|
t_plugin_modifier *modifier)
|
|
</command>
|
|
</para>
|
|
<para>
|
|
Remove a message modifier.
|
|
</para>
|
|
<para>
|
|
Arguments:
|
|
<itemizedlist>
|
|
<listitem>
|
|
<para>
|
|
<option>plugin</option>: pointer to plugin structure
|
|
</para>
|
|
</listitem>
|
|
<listitem>
|
|
<para>
|
|
<option>modifier</option>: modifier to remove
|
|
</para>
|
|
</listitem>
|
|
</itemizedlist>
|
|
</para>
|
|
<para>
|
|
Return value: none.
|
|
</para>
|
|
<para>
|
|
Example:
|
|
<screen>plugin->modifier_remove (plugin, my_modifier);</screen>
|
|
</para>
|
|
</section>
|
|
|
|
<!-- TRANSLATION NEEDED -->
|
|
<section id="secAPI_modifier_remove_all">
|
|
<title>modifier_remove_all</title>
|
|
|
|
<para>
|
|
Prototype:
|
|
<command>
|
|
void modifier_remove_all (t_weechat_plugin *plugin)
|
|
</command>
|
|
</para>
|
|
<para>
|
|
Remove all modifiers for a plugin.
|
|
</para>
|
|
<para>
|
|
Arguments:
|
|
<itemizedlist>
|
|
<listitem>
|
|
<para>
|
|
<option>plugin</option>: pointer to plugin structure
|
|
</para>
|
|
</listitem>
|
|
</itemizedlist>
|
|
</para>
|
|
<para>
|
|
Return value: none.
|
|
</para>
|
|
<para>
|
|
Example:
|
|
<screen>plugin->modifier_remove_all (plugin);</screen>
|
|
</para>
|
|
</section>
|
|
|
|
<section id="secAPI_exec_command">
|
|
<title>exec_command</title>
|
|
|
|
<para>
|
|
Prototyp:
|
|
<command>
|
|
void exec_command (t_weechat_plugin
|
|
*plugin, char *server, char *channel, char *command)
|
|
</command>
|
|
</para>
|
|
<para>
|
|
Führe ein WeeChat-Kommando aus (oder sende eine Nachricht an einen Channel).
|
|
</para>
|
|
<para>
|
|
Argumente:
|
|
<itemizedlist>
|
|
<listitem>
|
|
<para>
|
|
<option>plugin</option>: Zeiger auf eine Plugin-Struktur
|
|
</para>
|
|
</listitem>
|
|
<listitem>
|
|
<para>
|
|
<option>server</option>: interner Name des Servers, auf den das Kommando angewendet werden soll (kann NULL sein)
|
|
</para>
|
|
</listitem>
|
|
<listitem>
|
|
<para>
|
|
<option>channel</option>: Name des Channels, auf den das Kommando angewendet werden soll (kann NULL sein)
|
|
</para>
|
|
</listitem>
|
|
<listitem>
|
|
<para>
|
|
<option>command</option>: Kommando
|
|
</para>
|
|
</listitem>
|
|
</itemizedlist>
|
|
</para>
|
|
<para>
|
|
Rückgabewert: keiner
|
|
</para>
|
|
<para>
|
|
Beispiel:
|
|
<screen>
|
|
plugin->exec_command (plugin, NULL, NULL, "/help nick");
|
|
plugin->exec_command (plugin, "freenode", "#weechat", "hello");
|
|
</screen>
|
|
</para>
|
|
</section>
|
|
|
|
<section id="secAPI_get_info">
|
|
<title>get_info</title>
|
|
|
|
<para>
|
|
Prototyp:
|
|
<command>
|
|
char *get_info (t_weechat_plugin *plugin,
|
|
char *info, char *server)
|
|
</command>
|
|
</para>
|
|
<para>
|
|
Gib eine Information über WeeChat oder einen Channel zurück.
|
|
</para>
|
|
<para>
|
|
Argumente:
|
|
<itemizedlist>
|
|
<listitem>
|
|
<para>
|
|
<option>plugin</option>: Zeiger auf eine Plugin-Struktur
|
|
</para>
|
|
</listitem>
|
|
<listitem>
|
|
<para>
|
|
<option>info</option> : Name (Typ) der Information:
|
|
<informaltable colsep="0" frame="none">
|
|
<tgroup cols="2">
|
|
<thead>
|
|
<row>
|
|
<entry>Info</entry>
|
|
<entry>Beschreibung</entry>
|
|
</row>
|
|
</thead>
|
|
<tbody>
|
|
<row>
|
|
<entry><literal>version</literal></entry>
|
|
<entry>WeeChats Version</entry>
|
|
</row>
|
|
<row>
|
|
<entry><literal>nick</literal></entry>
|
|
<entry>Nickname</entry>
|
|
</row>
|
|
<row>
|
|
<entry><literal>channel</literal></entry>
|
|
<entry>
|
|
Name des Channels (NULL bei einem Server oder Privatchat)
|
|
</entry>
|
|
</row>
|
|
<row>
|
|
<entry><literal>server</literal></entry>
|
|
<entry>Name des Servers</entry>
|
|
</row>
|
|
<row>
|
|
<entry><literal>away</literal></entry>
|
|
<entry>Status des "away"-Flags</entry>
|
|
</row>
|
|
<row>
|
|
<entry><literal>inactivity</literal></entry>
|
|
<entry>
|
|
Anzahl der Sekunden seit der letzten Tastenbetätigung
|
|
</entry>
|
|
</row>
|
|
<row>
|
|
<entry><literal>input</literal></entry>
|
|
<entry>
|
|
Inhalt der Kommandozeile im gegenwärtigen Fenster
|
|
</entry>
|
|
</row>
|
|
<row>
|
|
<entry><literal>input_mask</literal></entry>
|
|
<entry>
|
|
Inhalt der Farbmaske für die Kommandozeile
|
|
</entry>
|
|
</row>
|
|
<row>
|
|
<entry><literal>input_pos</literal></entry>
|
|
<entry>
|
|
Position des Cursors in der Kommandozeile
|
|
</entry>
|
|
</row>
|
|
<row>
|
|
<entry><literal>weechat_dir</literal></entry>
|
|
<entry>
|
|
WeeChat-Verzeichnis (Standard: ~/.weechat/)
|
|
</entry>
|
|
</row>
|
|
<row>
|
|
<entry><literal>weechat_libdir</literal></entry>
|
|
<entry>WeeChat-Systemverzeichnis (Bibliotheken) </entry>
|
|
</row>
|
|
<row>
|
|
<entry><literal>weechat_sharedir</literal></entry>
|
|
<entry>WeeChat-Systemverzeichnis (gemeinsame Dateien)</entry>
|
|
</row>
|
|
</tbody>
|
|
</tgroup>
|
|
</informaltable>
|
|
</para>
|
|
</listitem>
|
|
<listitem>
|
|
<para>
|
|
<option>server</option>: interner Name des Servers um Informationen zu lesen (wenn benötigt)
|
|
</para>
|
|
</listitem>
|
|
</itemizedlist>
|
|
</para>
|
|
<para>
|
|
Rückgabewert: angeforderte Information oder NULL
|
|
</para>
|
|
<para>
|
|
Hinweis: das Ergebnis muss nach Nutzung mit "free" wieder freigegeben werden.
|
|
</para>
|
|
<para>
|
|
Beispiele:
|
|
<screen>
|
|
char *version = plugin->get_info (plugin, "version", NULL);
|
|
char *nick = plugin->get_info (plugin, "nick", "freenode");
|
|
char *inactivity = plugin->get_info (plugin, "inactivity", NULL);
|
|
|
|
plugin->print (plugin, NULL, NULL,
|
|
"WeeChat version %s, you are %s on freenode "
|
|
"(inactive for %s seconds)",
|
|
version, nick, inactivity);
|
|
|
|
if (version)
|
|
free (version);
|
|
if (nick)
|
|
free (nick);
|
|
if (inactivity)
|
|
free (inactivity);
|
|
</screen>
|
|
</para>
|
|
</section>
|
|
|
|
<section id="secAPI_get_dcc_info">
|
|
<title>get_dcc_info</title>
|
|
|
|
<para>
|
|
Prototyp:
|
|
<command>
|
|
t_plugin_info_dcc *get_dcc_info (t_weechat_plugin *plugin)
|
|
</command>
|
|
</para>
|
|
<para>
|
|
Gib eine Liste der aktiven oder beendeten DCCs zurück.
|
|
</para>
|
|
<para>
|
|
Argumente:
|
|
<itemizedlist>
|
|
<listitem>
|
|
<para>
|
|
<option>plugin</option>: Zeiger auf eine Plugin-Struktur
|
|
</para>
|
|
</listitem>
|
|
</itemizedlist>
|
|
</para>
|
|
<para>
|
|
Rückgabewert: verkettete Liste von DCCs.
|
|
<informaltable colsep="0" frame="none">
|
|
<tgroup cols="2">
|
|
<thead>
|
|
<row>
|
|
<entry>Typ</entry>
|
|
<entry>Feld</entry>
|
|
<entry>Beschreibung</entry>
|
|
</row>
|
|
</thead>
|
|
<tbody>
|
|
<row>
|
|
<entry>char *</entry>
|
|
<entry><literal>server</literal></entry>
|
|
<entry>IRC Server</entry>
|
|
</row>
|
|
<row>
|
|
<entry>char *</entry>
|
|
<entry><literal>channel</literal></entry>
|
|
<entry>IRC Channel</entry>
|
|
</row>
|
|
<row>
|
|
<entry>int</entry>
|
|
<entry><literal>type</literal></entry>
|
|
<entry>
|
|
DCC Typ:
|
|
0 = Chatanfrage empfangen,
|
|
1 = Chatanfrage gesendet,
|
|
2 = Datei empfangen,
|
|
3 = Datei gesendet
|
|
</entry>
|
|
</row>
|
|
<row>
|
|
<entry>int*</entry>
|
|
<entry><literal>status</literal></entry>
|
|
<entry>
|
|
DCC Status:
|
|
0 = wartend,
|
|
1 = verbindend,
|
|
2 = aktiv,
|
|
3 = beendet,
|
|
4 = fehlgeschlagen,
|
|
5 = unterbrochen durch Anwender
|
|
</entry>
|
|
</row>
|
|
<row>
|
|
<entry>time_t</entry>
|
|
<entry><literal>start_time</literal></entry>
|
|
<entry>Datum/Zeit der Erzeugung der DCC</entry>
|
|
</row>
|
|
<row>
|
|
<entry>time_t</entry>
|
|
<entry><literal>start_transfer</literal></entry>
|
|
<entry>Datum/Zeit des Beginns der Übertragung der DCC</entry>
|
|
</row>
|
|
<row>
|
|
<entry>unsigned long</entry>
|
|
<entry><literal>addr</literal></entry>
|
|
<entry>IP-Adresse des Partners</entry>
|
|
</row>
|
|
<row>
|
|
<entry>int</entry>
|
|
<entry><literal>port</literal></entry>
|
|
<entry>Port der DCC</entry>
|
|
</row>
|
|
<row>
|
|
<entry>char *</entry>
|
|
<entry><literal>nick</literal></entry>
|
|
<entry>Nickname des Partners</entry>
|
|
</row>
|
|
<row>
|
|
<entry>char *</entry>
|
|
<entry><literal>filename</literal></entry>
|
|
<entry>Dateiname</entry>
|
|
</row>
|
|
<row>
|
|
<entry>char *</entry>
|
|
<entry><literal>local_filename</literal></entry>
|
|
<entry>lokaler Dateiname</entry>
|
|
</row>
|
|
<row>
|
|
<entry>int</entry>
|
|
<entry><literal>filename_suffix</literal></entry>
|
|
<entry>Suffix wenn die Datei umbenannt wird</entry>
|
|
</row>
|
|
<row>
|
|
<entry>unsigned long</entry>
|
|
<entry><literal>size</literal></entry>
|
|
<entry>Dateigrösse</entry>
|
|
</row>
|
|
<row>
|
|
<entry>unsigned long</entry>
|
|
<entry><literal>pos</literal></entry>
|
|
<entry>Position in Datei</entry>
|
|
</row>
|
|
<row>
|
|
<entry>unsigned long</entry>
|
|
<entry><literal>start_resume</literal></entry>
|
|
<entry>Startposition nach einer Unterbrechung</entry>
|
|
</row>
|
|
<row>
|
|
<entry>unsigned long</entry>
|
|
<entry><literal>bytes_per_sec</literal></entry>
|
|
<entry>
|
|
Übertragungsrate (Bytes/s) seit Beginn der Übertragung
|
|
</entry>
|
|
</row>
|
|
<row>
|
|
<entry>t_plugin_dcc_info *</entry>
|
|
<entry><literal>prev_dcc</literal></entry>
|
|
<entry>
|
|
Zeiger auf voheriges DCC-Info
|
|
</entry>
|
|
</row>
|
|
<row>
|
|
<entry>t_plugin_dcc_info *</entry>
|
|
<entry><literal>next_dcc</literal></entry>
|
|
<entry>
|
|
Zeiger auf nächstes DCC-Info
|
|
</entry>
|
|
</row>
|
|
|
|
</tbody>
|
|
</tgroup>
|
|
</informaltable>
|
|
</para>
|
|
<para>
|
|
Hinweis: Das Ergebnis muss nach der Benutzung mittels "free_dcc_info" wieder freigegeben werden.
|
|
</para>
|
|
<para>
|
|
Beispiele:
|
|
<screen>
|
|
t_plugin_dcc_info *dcc_info = plugin->get_dcc_info (plugin);
|
|
for (ptr_dcc = dcc_info; ptr_dcc; ptr_dcc = ptr_dcc->next_dcc)
|
|
{
|
|
plugin->print_server (plugin, "DCC type=%d, with: %s",
|
|
ptr_dcc->type, ptr_dcc->nick);
|
|
}
|
|
if (dcc_info)
|
|
plugin->free_dcc_info (plugin, dcc_info);
|
|
</screen>
|
|
</para>
|
|
</section>
|
|
|
|
<section id="secAPI_free_dcc_info">
|
|
<title>free_dcc_info</title>
|
|
|
|
<para>
|
|
Prototyp:
|
|
<command>
|
|
void free_dcc_info (t_weechat_plugin *plugin,
|
|
t_plugin_dcc_info *dcc_info)
|
|
</command>
|
|
</para>
|
|
<para>
|
|
Gibt den Speicher einer Liste von DCC-Infos wieder frei.
|
|
</para>
|
|
<para>
|
|
Argumente:
|
|
<itemizedlist>
|
|
<listitem>
|
|
<para>
|
|
<option>plugin</option>: Zeiger auf eine Plugin-Struktur
|
|
</para>
|
|
</listitem>
|
|
<listitem>
|
|
<para>
|
|
<option>dcc_info</option>: Zeiger auf eine Liste mit DCC-Infos, die
|
|
mit "get_dcc_info" angelegt wurde
|
|
</para>
|
|
</listitem>
|
|
</itemizedlist>
|
|
</para>
|
|
<para>
|
|
Rückgabewert: keiner.
|
|
</para>
|
|
<para>
|
|
Beispiel:
|
|
<screen>plugin->free_dcc_info (plugin, dcc_info);</screen>
|
|
</para>
|
|
</section>
|
|
|
|
<section id="secAPI_get_server_info">
|
|
<title>get_server_info</title>
|
|
|
|
<para>
|
|
Prototyp:
|
|
<command>
|
|
t_plugin_server_info *get_server_info (t_weechat_plugin *plugin)
|
|
</command>
|
|
</para>
|
|
<para>
|
|
Gibt die Liste von IRC-Servern zurück (verbunden oder nicht)
|
|
</para>
|
|
<para>
|
|
Argumente:
|
|
<itemizedlist>
|
|
<listitem>
|
|
<para>
|
|
<option>plugin</option>: Zeiger auf eine Plugin-Struktur
|
|
</para>
|
|
</listitem>
|
|
</itemizedlist>
|
|
</para>
|
|
<para>
|
|
Rückgabewert: Liste von IRC-Servern.
|
|
<informaltable colsep="0" frame="none">
|
|
<tgroup cols="2">
|
|
<thead>
|
|
<row>
|
|
<entry>Typ</entry>
|
|
<entry>Feld</entry>
|
|
<entry>Beschreibung</entry>
|
|
</row>
|
|
</thead>
|
|
<tbody>
|
|
<row>
|
|
<entry>char *</entry>
|
|
<entry><literal>name</literal></entry>
|
|
<entry>interner Servername</entry>
|
|
</row>
|
|
<row>
|
|
<entry>int</entry>
|
|
<entry><literal>autoconnect</literal></entry>
|
|
<entry>1 wenn Autoconnect gesetzt ist, 0 sonst</entry>
|
|
</row>
|
|
<row>
|
|
<entry>int</entry>
|
|
<entry><literal>autoreconnect</literal></entry>
|
|
<entry>
|
|
1 wenn autoreconnect gesetzt ist,
|
|
0 sonst
|
|
</entry>
|
|
</row>
|
|
<row>
|
|
<entry>int</entry>
|
|
<entry><literal>autoreconnect_delay</literal></entry>
|
|
<entry>Wartezeit vor erneutem Verbindungsversuch</entry>
|
|
</row>
|
|
<row>
|
|
<entry>int</entry>
|
|
<entry><literal>command_line</literal></entry>
|
|
<entry>
|
|
1 wenn der Servername auf der Kommandozeile angegeben wurde (ist somit temporär)
|
|
0 sonst
|
|
</entry>
|
|
</row>
|
|
<row>
|
|
<entry>char *</entry>
|
|
<entry><literal>address</literal></entry>
|
|
<entry>Serveradresse (Name oder IP)</entry>
|
|
</row>
|
|
<row>
|
|
<entry>int</entry>
|
|
<entry><literal>port</literal></entry>
|
|
<entry>Port</entry>
|
|
</row>
|
|
<row>
|
|
<entry>int</entry>
|
|
<entry><literal>ipv6</literal></entry>
|
|
<entry>IPv6-Verbindung</entry>
|
|
</row>
|
|
<row>
|
|
<entry>int</entry>
|
|
<entry><literal>ssl</literal></entry>
|
|
<entry>SSL-Verbindung</entry>
|
|
</row>
|
|
<row>
|
|
<entry>char *</entry>
|
|
<entry><literal>password</literal></entry>
|
|
<entry>Passwort</entry>
|
|
</row>
|
|
<row>
|
|
<entry>char *</entry>
|
|
<entry><literal>nick1</literal></entry>
|
|
<entry>primärer Nickname</entry>
|
|
</row>
|
|
<row>
|
|
<entry>char *</entry>
|
|
<entry><literal>nick2</literal></entry>
|
|
<entry>alternativer Nickname</entry>
|
|
</row>
|
|
<row>
|
|
<entry>char *</entry>
|
|
<entry><literal>nick3</literal></entry>
|
|
<entry>zweiter, alternativer Nickname</entry>
|
|
</row>
|
|
<row>
|
|
<entry>char *</entry>
|
|
<entry><literal>username</literal></entry>
|
|
<entry>Username</entry>
|
|
</row>
|
|
<row>
|
|
<entry>char *</entry>
|
|
<entry><literal>real name</literal></entry>
|
|
<entry>tatsächlicher Name</entry>
|
|
</row>
|
|
<row>
|
|
<entry>char *</entry>
|
|
<entry><literal>command</literal></entry>
|
|
<entry>Kommando, dass bei erfolgreicher Verbindung ausgeführt wurde</entry>
|
|
</row>
|
|
<row>
|
|
<entry>int</entry>
|
|
<entry><literal>command_delay</literal></entry>
|
|
<entry>Verzögerung nach Ausführung des Kommandos</entry>
|
|
</row>
|
|
<row>
|
|
<entry>char *</entry>
|
|
<entry><literal>autojoin</literal></entry>
|
|
<entry>Channels, die automatisch betreten werden sollen</entry>
|
|
</row>
|
|
<row>
|
|
<entry>int</entry>
|
|
<entry><literal>autorejoin</literal></entry>
|
|
<entry>
|
|
1 wenn Channels wieder betreten werden sollen, nachdem man gekickt wurde
|
|
0 sonst
|
|
</entry>
|
|
</row>
|
|
<row>
|
|
<entry>char *</entry>
|
|
<entry><literal>notify_levels</literal></entry>
|
|
<entry>Benachrichtigungs-Level von Channels</entry>
|
|
</row>
|
|
<row>
|
|
<entry>char *</entry>
|
|
<entry><literal>charset_decode_iso</literal></entry>
|
|
<entry>Zeichensatz zum Dekodieren von ISO</entry>
|
|
</row>
|
|
<row>
|
|
<entry>char *</entry>
|
|
<entry><literal>charset_decode_utf</literal></entry>
|
|
<entry>Zeichensatz zum Dekodieren von UTF</entry>
|
|
</row>
|
|
<row>
|
|
<entry>char *</entry>
|
|
<entry><literal>charset_encode</literal></entry>
|
|
<entry>Zeichensatz der Channels zum Kodieren von Nachrichten</entry>
|
|
</row>
|
|
<row>
|
|
<entry>int</entry>
|
|
<entry><literal>is_connected</literal></entry>
|
|
<entry>1 wenn verbunden mit einem Server, 0 otherwise</entry>
|
|
</row>
|
|
<row>
|
|
<entry>int</entry>
|
|
<entry><literal>ssl_connected</literal></entry>
|
|
<entry>1 wenn verbunden über SSL, 0 sonst</entry>
|
|
</row>
|
|
<row>
|
|
<entry>char *</entry>
|
|
<entry><literal>nick</literal></entry>
|
|
<entry>gegenwärtiger Nickname</entry>
|
|
</row>
|
|
<row>
|
|
<entry>int</entry>
|
|
<entry><literal>is_away</literal></entry>
|
|
<entry>1 wenn away-flag gesetzt ist, 0 sonst</entry>
|
|
</row>
|
|
<row>
|
|
<entry>time_t</entry>
|
|
<entry><literal>away_time</literal></entry>
|
|
<entry>Zeitspanne seit away-flag gesetzt ist</entry>
|
|
</row>
|
|
<row>
|
|
<entry>int</entry>
|
|
<entry><literal>lag</literal></entry>
|
|
<entry>Lag (in Millisekunden)</entry>
|
|
</row>
|
|
<row>
|
|
<entry>t_plugin_server_info *</entry>
|
|
<entry><literal>prev_server</literal></entry>
|
|
<entry>Zeiger auf vorherigen Knoten der Liste</entry>
|
|
</row>
|
|
<row>
|
|
<entry>t_plugin_server_info *</entry>
|
|
<entry><literal>next_server</literal></entry>
|
|
<entry>Zeiger auf nächsten Knoten der Liste</entry>
|
|
</row>
|
|
</tbody>
|
|
</tgroup>
|
|
</informaltable>
|
|
</para>
|
|
<para>
|
|
Hinweis: das Ergebnis muss nach der Benutzung mit "free_server_info" wieder
|
|
freigegeben werden.
|
|
</para>
|
|
<para>
|
|
Beispiel:
|
|
<screen>
|
|
t_plugin_server_info *server_info, *ptr_server_info;
|
|
server_info = plugin->get_server_info (plugin);
|
|
if (server_info)
|
|
{
|
|
for (ptr_server_info = server_info; ptr_server_info;
|
|
ptr_server_info = ptr_server_info->next_server)
|
|
{
|
|
plugin->print (plugin, NULL, NULL,
|
|
"server: %s, address: %s, port: %d %s",
|
|
ptr_server_info->name,
|
|
ptr_server_info->address,
|
|
ptr_server_info->port,
|
|
(ptr_server_info->is_connected) ? "(connected)" : "");
|
|
}
|
|
plugin->free_server_info (plugin, server_info);
|
|
}
|
|
</screen>
|
|
</para>
|
|
</section>
|
|
|
|
<section id="secAPI_free_server_info">
|
|
<title>free_server_info</title>
|
|
|
|
<para>
|
|
Prototyp:
|
|
<command>
|
|
void free_server_info (t_weechat_plugin *plugin,
|
|
t_plugin_server_info *server_info)
|
|
</command>
|
|
</para>
|
|
<para>
|
|
Gib den Speicher einer Liste "server info" frei
|
|
</para>
|
|
<para>
|
|
Argumente:
|
|
<itemizedlist>
|
|
<listitem>
|
|
<para>
|
|
<option>plugin</option>: Zeiger auf eine Plugin-Struktur
|
|
</para>
|
|
</listitem>
|
|
<listitem>
|
|
<para>
|
|
<option>server_info</option>: Zeiger auf eine Server-Liste, der von der Funktion "get_server_info"
|
|
zurückgegeben wurde.
|
|
</para>
|
|
</listitem>
|
|
</itemizedlist>
|
|
</para>
|
|
<para>
|
|
Rückgabewert: keiner.
|
|
</para>
|
|
<para>
|
|
Beispiel:
|
|
<screen>plugin->free_server_info (plugin, server_info);</screen>
|
|
</para>
|
|
</section>
|
|
|
|
<section id="secAPI_get_channel_info">
|
|
<title>get_channel_info</title>
|
|
|
|
<para>
|
|
Prototyp:
|
|
<command>
|
|
t_plugin_channel_info *get_channel_info (t_weechat_plugin *plugin,
|
|
char *server)
|
|
</command>
|
|
</para>
|
|
<para>
|
|
Gib eine Liste der Channels für einen Server zurück.
|
|
</para>
|
|
<para>
|
|
Argumente:
|
|
<itemizedlist>
|
|
<listitem>
|
|
<para>
|
|
<option>plugin</option>: Zeiger auf eine Plugin-Struktur
|
|
</para>
|
|
</listitem>
|
|
<listitem>
|
|
<para>
|
|
<option>server</option>: interner Name des Server
|
|
</para>
|
|
</listitem>
|
|
</itemizedlist>
|
|
</para>
|
|
<para>
|
|
Rückgabewert: verkettete Liste von Channels für einen Server.
|
|
<informaltable colsep="0" frame="none">
|
|
<tgroup cols="2">
|
|
<thead>
|
|
<row>
|
|
<entry>Typ</entry>
|
|
<entry>Feld</entry>
|
|
<entry>Beschreibung</entry>
|
|
</row>
|
|
</thead>
|
|
<tbody>
|
|
<row>
|
|
<entry>int</entry>
|
|
<entry><literal>type</literal></entry>
|
|
<entry>0 für einen normalen Channel, 1 für einen Privaten</entry>
|
|
</row>
|
|
<row>
|
|
<entry>char *</entry>
|
|
<entry><literal>name</literal></entry>
|
|
<entry>Name des Channels</entry>
|
|
</row>
|
|
<row>
|
|
<entry>char *</entry>
|
|
<entry><literal>topic</literal></entry>
|
|
<entry>Topic des Channels</entry>
|
|
</row>
|
|
<row>
|
|
<entry>char *</entry>
|
|
<entry><literal>modes</literal></entry>
|
|
<entry>Channelmodus (Flags)</entry>
|
|
</row>
|
|
<row>
|
|
<entry>int</entry>
|
|
<entry><literal>limit</literal></entry>
|
|
<entry>Anzahl der erlaubten User</entry>
|
|
</row>
|
|
<row>
|
|
<entry>char *</entry>
|
|
<entry><literal>key</literal></entry>
|
|
<entry>Schlüssel des Channels</entry>
|
|
</row>
|
|
<row>
|
|
<entry>int</entry>
|
|
<entry><literal>nicks_count</literal></entry>
|
|
<entry>Anzahl der Nicknamen des Channels</entry>
|
|
</row>
|
|
<row>
|
|
<entry>t_plugin_channel_info *</entry>
|
|
<entry><literal>prev_channel</literal></entry>
|
|
<entry>Zeiger auf vorherigem Knoten der Liste</entry>
|
|
</row>
|
|
<row>
|
|
<entry>t_plugin_channel_info *</entry>
|
|
<entry><literal>next_channel</literal></entry>
|
|
<entry>Zeiger auf nächsten Knoten der Liste</entry>
|
|
</row>
|
|
</tbody>
|
|
</tgroup>
|
|
</informaltable>
|
|
</para>
|
|
<para>
|
|
Hinweis: Das Ergebnis muss nach der Benutzung mit "free_channel_info" wieder freigegeben werden.
|
|
</para>
|
|
<para>
|
|
Beispiel:
|
|
<screen>
|
|
t_plugin_channel_info *channel_info, *ptr_chan_info;
|
|
channel_info = plugin->get_channel_info (plugin, "freenode");
|
|
if (channel_info)
|
|
{
|
|
for (ptr_chan_info = channel_info; ptr_chan_info;
|
|
ptr_chan_info = ptr_chan_info->next_channel)
|
|
{
|
|
plugin->print (plugin, NULL, NULL,
|
|
" %s (type %d)",
|
|
ptr_chan_info->name,
|
|
ptr_chan_info->type);
|
|
}
|
|
plugin->free_channel_info (plugin, channel_info);
|
|
}
|
|
</screen>
|
|
</para>
|
|
</section>
|
|
|
|
<section id="secAPI_free_channel_info">
|
|
<title>free_channel_info</title>
|
|
|
|
<para>
|
|
Prototyp:
|
|
<command>
|
|
void free_channel_info (t_weechat_plugin *plugin,
|
|
t_plugin_channel_info *channel_info)
|
|
</command>
|
|
</para>
|
|
<para>
|
|
Gibt den Speicher einer Liste "channel info" wieder frei.
|
|
</para>
|
|
<para>
|
|
Argumente:
|
|
<itemizedlist>
|
|
<listitem>
|
|
<para>
|
|
<option>plugin</option>: Zeiger auf eine Plugin-Struktur
|
|
</para>
|
|
</listitem>
|
|
<listitem>
|
|
<para>
|
|
<option>channel_info</option>: Zeiger auf eine Liste "channel info", der von "get_channel_info"
|
|
zurückgegeben wurde
|
|
</para>
|
|
</listitem>
|
|
</itemizedlist>
|
|
</para>
|
|
<para>
|
|
Rückgabewert: keiner.
|
|
</para>
|
|
<para>
|
|
Beispiel:
|
|
<screen>plugin->free_channel_info (plugin, channel_info);</screen>
|
|
</para>
|
|
</section>
|
|
|
|
<section id="secAPI_get_nick_info">
|
|
<title>get_nick_info</title>
|
|
|
|
<para>
|
|
Prototyp:
|
|
<command>
|
|
t_plugin_nick_info *get_nick_info (t_weechat_plugin *plugin,
|
|
char *server, char *channel)
|
|
</command>
|
|
</para>
|
|
<para>
|
|
Gib eine Liste der Nicknamen für einen Channel zurück.
|
|
</para>
|
|
<para>
|
|
Argumente:
|
|
<itemizedlist>
|
|
<listitem>
|
|
<para>
|
|
<option>plugin</option>: Zeiger auf eine Plugin-Struktur
|
|
</para>
|
|
</listitem>
|
|
<listitem>
|
|
<para>
|
|
<option>server</option>: interner Name des Servers
|
|
</para>
|
|
</listitem>
|
|
<listitem>
|
|
<para>
|
|
<option>channel</option>: Name des Channels
|
|
</para>
|
|
</listitem>
|
|
</itemizedlist>
|
|
</para>
|
|
<para>
|
|
Rückgabewert: verkettete Liste von Nicknamen eines Channels.
|
|
<informaltable colsep="0" frame="none">
|
|
<tgroup cols="2">
|
|
<thead>
|
|
<row>
|
|
<entry>Typ</entry>
|
|
<entry>Feld</entry>
|
|
<entry>Beschreibung</entry>
|
|
</row>
|
|
</thead>
|
|
<tbody>
|
|
<row>
|
|
<entry>char *</entry>
|
|
<entry><literal>nick</literal></entry>
|
|
<entry>Nickname</entry>
|
|
</row>
|
|
<row>
|
|
<entry>char *</entry>
|
|
<entry><literal>host</literal></entry>
|
|
<entry>Hostname</entry>
|
|
</row>
|
|
<row>
|
|
<entry>int</entry>
|
|
<entry><literal>Flags</literal></entry>
|
|
<entry>
|
|
Flags, die für einen Nicknamen gesetzt sind:
|
|
Zweierpotenzen "oder" Zwischenwerte
|
|
(1 = channel owner,
|
|
2 = channel admin,
|
|
4 = op,
|
|
8 = halfop,
|
|
16 = voice,
|
|
32 = away)
|
|
</entry>
|
|
</row>
|
|
<row>
|
|
<entry>t_plugin_nick_info *</entry>
|
|
<entry><literal>prev_nick</literal></entry>
|
|
<entry>Zeiger auf vorherigen Knoten der Liste</entry>
|
|
</row>
|
|
<row>
|
|
<entry>t_plugin_nick_info *</entry>
|
|
<entry><literal>next_nick</literal></entry>
|
|
<entry>Zeiger auf nächsten Knoten der Liste</entry>
|
|
</row>
|
|
</tbody>
|
|
</tgroup>
|
|
</informaltable>
|
|
</para>
|
|
<para>
|
|
Hinweis: Das Ergebnis muss nach der Benutzung mit "free_nick_info" wieder freigegeben werden.
|
|
</para>
|
|
<para>
|
|
Beispiel:
|
|
<screen>
|
|
t_plugin_nick_info *nick_info, *ptr_nick_info;
|
|
nick_info = plugin->get_nick_info (plugin, "freenode", "#weechat");
|
|
if (nick_info)
|
|
{
|
|
for (ptr_nick_info = nick_info; ptr_nick_info;
|
|
ptr_nick_info = ptr_nick_info->next_nick)
|
|
{
|
|
plugin->print (plugin, NULL, NULL,
|
|
" %s (flags: %d)",
|
|
ptr_nick_info->nick,
|
|
ptr_nick_info->flags);
|
|
}
|
|
plugin->free_nick_info (plugin, nick_info);
|
|
}
|
|
</screen>
|
|
</para>
|
|
</section>
|
|
|
|
<section id="secAPI_free_nick_info">
|
|
<title>free_nick_info</title>
|
|
|
|
<para>
|
|
Prototyp:
|
|
<command>
|
|
void free_nick_info (t_weechat_plugin *plugin,
|
|
t_plugin_nick_info *nick_info)
|
|
</command>
|
|
</para>
|
|
<para>
|
|
Gibt den Speicher einer Liste "nick info" frei.
|
|
</para>
|
|
<para>
|
|
Argumente:
|
|
<itemizedlist>
|
|
<listitem>
|
|
<para>
|
|
<option>plugin</option>: Zeiger auf eine Plugin-Struktur
|
|
</para>
|
|
</listitem>
|
|
<listitem>
|
|
<para>
|
|
<option>nick_info</option>: Zeiger auf eine Liste "nick info", der von "get_nick_info"
|
|
zurückgegeben wurde
|
|
</para>
|
|
</listitem>
|
|
</itemizedlist>
|
|
</para>
|
|
<para>
|
|
Rückgabewert: keiner.
|
|
</para>
|
|
<para>
|
|
Beispiel:
|
|
<screen>plugin->free_nick_info (plugin, nick_info);</screen>
|
|
</para>
|
|
</section>
|
|
|
|
<section id="secAPI_get_config">
|
|
<title>get_config</title>
|
|
|
|
<para>
|
|
Prototyp:
|
|
<command>
|
|
char *get_config (t_weechat_plugin *plugin, char *option)
|
|
</command>
|
|
</para>
|
|
<para>
|
|
Gibt den Wert einer Option der WeeChat-Konfiguration zurück.
|
|
</para>
|
|
<para>
|
|
Argumente:
|
|
<itemizedlist>
|
|
<listitem>
|
|
<para>
|
|
<option>plugin</option>: Zeiger auf eine Plugin-Struktur
|
|
</para>
|
|
</listitem>
|
|
<listitem>
|
|
<para>
|
|
<option>option</option>: Name der Option
|
|
</para>
|
|
</listitem>
|
|
</itemizedlist>
|
|
</para>
|
|
<para>
|
|
Rückgabewert: Wert der Option, oder NULL, wenn nichts gefunden wurde.
|
|
</para>
|
|
<para>
|
|
Hinweis: Das Ergebnis muss nach der Benutzung mit "free" wieder freigegeben werden.
|
|
</para>
|
|
<para>
|
|
Beispiel:
|
|
<screen>
|
|
char *value1 = plugin->get_config (plugin, "look_set_title");
|
|
char *value2 = plugin->get_config (plugin, "freenode.server_autojoin");
|
|
</screen>
|
|
</para>
|
|
</section>
|
|
|
|
<section id="secAPI_set_config">
|
|
<title>set_config</title>
|
|
|
|
<para>
|
|
Prototyp:
|
|
<command>
|
|
int set_config (t_weechat_plugin *plugin,
|
|
char *option, char *value)
|
|
</command>
|
|
</para>
|
|
<para>
|
|
Setze den Wert einer Option der WeeChat-Konfiguration.
|
|
</para>
|
|
<para>
|
|
Argumente:
|
|
<itemizedlist>
|
|
<listitem>
|
|
<para>
|
|
<option>plugin</option>: Zeiger auf eine Plugin-Struktur
|
|
</para>
|
|
</listitem>
|
|
<listitem>
|
|
<para>
|
|
<option>option</option>: Name der Option
|
|
</para>
|
|
</listitem>
|
|
<listitem>
|
|
<para>
|
|
<option>value</option>: der neue Wert der Option
|
|
</para>
|
|
</listitem>
|
|
</itemizedlist>
|
|
</para>
|
|
<para>
|
|
Rückgabewert: 1 wenn der Wert der Option gesetzt werden konnte, 0 bei Auftreten eines Fehlers.
|
|
</para>
|
|
<para>
|
|
Beispiel:
|
|
<screen>
|
|
plugin->set_config (plugin, "look_nicklist", "off");
|
|
</screen>
|
|
</para>
|
|
</section>
|
|
|
|
<section id="secAPI_get_plugin_config">
|
|
<title>get_plugin_config</title>
|
|
|
|
<para>
|
|
Prototyp:
|
|
<command>
|
|
char *get_plugin_config (t_weechat_plugin *plugin, char *option)
|
|
</command>
|
|
</para>
|
|
<para>
|
|
Gibt den Wert einer Option eines Plugins zurück.
|
|
Die Option wird aus "<literal>~/.weechat/plugins.rc</literal>" gelesen
|
|
und sieht so aus: "<literal>plugin.option=value</literal>"
|
|
(Hinweis: der Name des Plugins wird automatisch gesetzt).
|
|
|
|
</para>
|
|
<para>
|
|
Argumente:
|
|
<itemizedlist>
|
|
<listitem>
|
|
<para>
|
|
<option>plugin</option>: Zeiger auf eine Plugin-Struktur
|
|
</para>
|
|
</listitem>
|
|
<listitem>
|
|
<para>
|
|
<option>option</option>: Name der Option
|
|
</para>
|
|
</listitem>
|
|
</itemizedlist>
|
|
</para>
|
|
<para>
|
|
Rückgabewert: Wert der Option, NULL wenn nichts gefunden wurde.
|
|
</para>
|
|
<para>
|
|
Hinweis: Das Ergebnis muss nach der Benutzung mit "free" wieder freigegeben werden.
|
|
</para>
|
|
<para>
|
|
Beispiel:
|
|
<screen>
|
|
char *value = plugin->get_plugin_config (plugin, "my_var");
|
|
</screen>
|
|
</para>
|
|
</section>
|
|
|
|
<section id="secAPI_set_plugin_config">
|
|
<title>set_plugin_config</title>
|
|
|
|
<para>
|
|
Prototyp:
|
|
<command>
|
|
int set_plugin_config (t_weechat_plugin *plugin,
|
|
char *option, char *value)
|
|
</command>
|
|
</para>
|
|
<para>
|
|
Setzt den Wert einer Option eines Plugins.
|
|
Die Option wird in die Datei "<literal>~/.weechat/plugins.rc</literal>" geschrieben
|
|
und sieht so aus: "<literal>plugin.option=value</literal>"
|
|
(Hinweis: der Name des Plugins wird automatisch gesetzt)
|
|
</para>
|
|
<para>
|
|
Argumente:
|
|
<itemizedlist>
|
|
<listitem>
|
|
<para>
|
|
<option>plugin</option>: Zeiger auf eine Plugin-Struktur
|
|
</para>
|
|
</listitem>
|
|
<listitem>
|
|
<para>
|
|
<option>option</option>: Name der Option, die gesetzt werden soll
|
|
</para>
|
|
</listitem>
|
|
<listitem>
|
|
<para>
|
|
<option>value</option>: Wert der zu setzenden Option
|
|
</para>
|
|
</listitem>
|
|
</itemizedlist>
|
|
</para>
|
|
<para>
|
|
Rückgabewert: 1 wenn die Option gesetzt werden konnte, 0 wenn ein Fehler aufgetreten ist.
|
|
</para>
|
|
<para>
|
|
Beispiel:
|
|
<screen>
|
|
plugin->set_plugin_config (plugin, "my_var", "value");
|
|
</screen>
|
|
</para>
|
|
</section>
|
|
|
|
<section id="secAPI_get_irc_color">
|
|
<title>get_irc_color</title>
|
|
|
|
<para>
|
|
Prototype:
|
|
<command>
|
|
int get_irc_color (t_weechat_plugin *plugin,
|
|
char *color_name)
|
|
</command>
|
|
</para>
|
|
<para>
|
|
Hole IRC-Farbindex mit dem Farbnamen.
|
|
</para>
|
|
<para>
|
|
Argumente:
|
|
<itemizedlist>
|
|
<listitem>
|
|
<para>
|
|
<option>plugin</option>: Zeiger auf die Pluginstruktur
|
|
</para>
|
|
</listitem>
|
|
<listitem>
|
|
<para>
|
|
<option>color_name</option>: Farbname
|
|
Folgende Farben sind erlaubt:
|
|
<informaltable colsep="0" frame="none">
|
|
<tgroup cols="2">
|
|
<thead>
|
|
<row>
|
|
<entry>Farbname</entry>
|
|
<entry>Wert</entry>
|
|
</row>
|
|
</thead>
|
|
<tbody>
|
|
<row>
|
|
<entry>white</entry>
|
|
<entry>0</entry>
|
|
</row>
|
|
<row>
|
|
<entry>black</entry>
|
|
<entry>1</entry>
|
|
</row>
|
|
<row>
|
|
<entry>blue</entry>
|
|
<entry>2</entry>
|
|
</row>
|
|
<row>
|
|
<entry>green</entry>
|
|
<entry>3</entry>
|
|
</row>
|
|
<row>
|
|
<entry>lightred</entry>
|
|
<entry>4</entry>
|
|
</row>
|
|
<row>
|
|
<entry>red</entry>
|
|
<entry>5</entry>
|
|
</row>
|
|
<row>
|
|
<entry>magenta</entry>
|
|
<entry>6</entry>
|
|
</row>
|
|
<row>
|
|
<entry>brown</entry>
|
|
<entry>7</entry>
|
|
</row>
|
|
<row>
|
|
<entry>yellow</entry>
|
|
<entry>8</entry>
|
|
</row>
|
|
<row>
|
|
<entry>lightgreen</entry>
|
|
<entry>9</entry>
|
|
</row>
|
|
<row>
|
|
<entry>cyan</entry>
|
|
<entry>10</entry>
|
|
</row>
|
|
<row>
|
|
<entry>lightcyan</entry>
|
|
<entry>11</entry>
|
|
</row>
|
|
<row>
|
|
<entry>lightblue</entry>
|
|
<entry>12</entry>
|
|
</row>
|
|
<row>
|
|
<entry>lightmagenta</entry>
|
|
<entry>13</entry>
|
|
</row>
|
|
<row>
|
|
<entry>gray</entry>
|
|
<entry>14</entry>
|
|
</row>
|
|
<row>
|
|
<entry>lightgray</entry>
|
|
<entry>15</entry>
|
|
</row>
|
|
</tbody>
|
|
</tgroup>
|
|
</informaltable>
|
|
</para>
|
|
</listitem>
|
|
</itemizedlist>
|
|
</para>
|
|
<para>
|
|
Rückgabewert: IRC-Farbindex, -1 wenn die Farbe nicht gefunden wurde.
|
|
</para>
|
|
<para>
|
|
Beispiel:
|
|
<screen>
|
|
int color_blue = plugin->get_irc_color (plugin, "blue"); /* return 2 */
|
|
</screen>
|
|
</para>
|
|
</section>
|
|
|
|
<section id="secAPI_input_color">
|
|
<title>input_color</title>
|
|
|
|
<para>
|
|
Prototyp:
|
|
<command>
|
|
void input_color (t_weechat_plugin *plugin,
|
|
int color, int start, int length)
|
|
</command>
|
|
</para>
|
|
<para>
|
|
Erzeugt einen Farbcode im Eingabepuffer.
|
|
</para>
|
|
<para>
|
|
Argumente:
|
|
<itemizedlist>
|
|
<listitem>
|
|
<para>
|
|
<option>plugin</option>: Zeiger auf die Pluginstruktur
|
|
</para>
|
|
</listitem>
|
|
<listitem>
|
|
<para>
|
|
<option>color</option>: Textfarbe (wenn der Wert < 0 ist, dann wird der
|
|
Eingabepuffer aufgefrischt und nicht verändert)
|
|
</para>
|
|
</listitem>
|
|
<listitem>
|
|
<para>
|
|
<option>start</option>: Startposition für Einfärbung (wenn der Wert < 0 ist,
|
|
wird die Maske neu initialisiert)
|
|
</para>
|
|
</listitem>
|
|
<listitem>
|
|
<para>
|
|
<option>length</option>: Länge der Einfärbung (wenn der Wert <= 0 ist,
|
|
wird die Maske neu initialisiert)
|
|
</para>
|
|
</listitem>
|
|
</itemizedlist>
|
|
</para>
|
|
<para>
|
|
Rückgabewert: keiner.
|
|
</para>
|
|
<para>
|
|
Beispiele:
|
|
<screen>
|
|
plugin->input_color (plugin, plugin->get_irc_color (plugin, "blue"), 10, 5);
|
|
</screen>
|
|
</para>
|
|
</section>
|
|
|
|
<section id="secAPI_get_window_info">
|
|
<title>get_window_info</title>
|
|
|
|
<para>
|
|
Prototype:
|
|
<command>
|
|
t_plugin_window_info *get_window_info (t_weechat_plugin *plugin)
|
|
</command>
|
|
</para>
|
|
<para>
|
|
Gibt die Liste der WeeChat-Fenster zurück.
|
|
</para>
|
|
<para>
|
|
Argumente:
|
|
<itemizedlist>
|
|
<listitem>
|
|
<para>
|
|
<option>plugin</option>: Zeiger auf Pluginstruktur
|
|
</para>
|
|
</listitem>
|
|
</itemizedlist>
|
|
</para>
|
|
<para>
|
|
Rückgabewert: verkettete Liste der WeeChat-Fenster.
|
|
<informaltable colsep="0" frame="none">
|
|
<tgroup cols="2">
|
|
<thead>
|
|
<row>
|
|
<entry>Typ</entry>
|
|
<entry>Feld</entry>
|
|
<entry>Beschreibung</entry>
|
|
</row>
|
|
</thead>
|
|
<tbody>
|
|
<row>
|
|
<entry>int</entry>
|
|
<entry><literal>win_x</literal></entry>
|
|
<entry>horizontale Fensterposition</entry>
|
|
</row>
|
|
<row>
|
|
<entry>int</entry>
|
|
<entry><literal>win_y</literal></entry>
|
|
<entry>vertikale Fensterposition</entry>
|
|
</row>
|
|
<row>
|
|
<entry>int</entry>
|
|
<entry><literal>win_width</literal></entry>
|
|
<entry>Fensterbreite</entry>
|
|
</row>
|
|
<row>
|
|
<entry>int</entry>
|
|
<entry><literal>win_height</literal></entry>
|
|
<entry>Fensterhöhe</entry>
|
|
</row>
|
|
<row>
|
|
<entry>int</entry>
|
|
<entry><literal>win_width_pct</literal></entry>
|
|
<entry>Breite in % (im Vergleich zum übergeordneten Fenster)</entry>
|
|
</row>
|
|
<row>
|
|
<entry>int</entry>
|
|
<entry><literal>win_height_pct</literal></entry>
|
|
<entry>Höhe % (im Vergleich zum übergeordneten Fenster)</entry>
|
|
</row>
|
|
<row>
|
|
<entry>int</entry>
|
|
<entry><literal>num_buffer</literal></entry>
|
|
<entry>Anzahl der angezeigten Puffer</entry>
|
|
</row>
|
|
<row>
|
|
<entry>t_plugin_window_info *</entry>
|
|
<entry><literal>prev_window</literal></entry>
|
|
<entry>Zeiger auf die Informationen des vorhergehenden Fensters</entry>
|
|
</row>
|
|
<row>
|
|
<entry>t_plugin_window_info *</entry>
|
|
<entry><literal>next_window</literal></entry>
|
|
<entry>Zeiger auf die Informationen des nächsten Fensters</entry>
|
|
</row>
|
|
</tbody>
|
|
</tgroup>
|
|
</informaltable>
|
|
</para>
|
|
<para>
|
|
Anmerkung: Das Ergebnis muss nach Benutzung durch einen Aufruf der
|
|
"free_window_info"-Funktion gelöscht werden.
|
|
</para>
|
|
<para>
|
|
Example:
|
|
<screen>
|
|
t_plugin_window_info *window_info, *ptr_window;
|
|
|
|
window_info = plugin->get_window_info (plugin);
|
|
if (window_info)
|
|
{
|
|
for (ptr_window = window_info; ptr_window; ptr_window = ptr_window->next_window)
|
|
{
|
|
plugin->print (plugin, NULL, NULL, "--- window info ---");
|
|
plugin->print (plugin, NULL, NULL, "(%d,%d), size: %dx%d, %%size: %d%%x%d%%",
|
|
ptr_window->win_x, ptr_window->win_y,
|
|
ptr_window->win_width, ptr_window->win_height,
|
|
ptr_window->win_width_pct, ptr_window->win_height_pct);
|
|
plugin->print (plugin, NULL, NULL, "num_buffer: %d", ptr_window->num_buffer);
|
|
}
|
|
plugin->free_window_info (plugin, window_info);
|
|
}
|
|
else
|
|
plugin->print (plugin, NULL, NULL, "no window info!");
|
|
</screen>
|
|
</para>
|
|
</section>
|
|
|
|
<section id="secAPI_free_window_info">
|
|
<title>free_window_info</title>
|
|
|
|
<para>
|
|
Prototyp:
|
|
<command>
|
|
void free_window_info (t_weechat_plugin *plugin,
|
|
t_plugin_window_info *window_info)
|
|
</command>
|
|
</para>
|
|
<para>
|
|
Gibt den Speicher wieder frei, der von der Fenster-Informationsliste belegt wird.
|
|
</para>
|
|
<para>
|
|
Argumente:
|
|
<itemizedlist>
|
|
<listitem>
|
|
<para>
|
|
<option>plugin</option>: Zeiger auf Pluginstruktur
|
|
</para>
|
|
</listitem>
|
|
<listitem>
|
|
<para>
|
|
<option>window_info</option>: Zeiger auf Fenster-Informationsliste,
|
|
der von der "get_window_info"-Funktion zurückgegeben wurde
|
|
</para>
|
|
</listitem>
|
|
</itemizedlist>
|
|
</para>
|
|
<para>
|
|
Rückgabewert: keiner.
|
|
</para>
|
|
<para>
|
|
Beispiel:
|
|
<screen>plugin->free_window_info (plugin, window_info);</screen>
|
|
</para>
|
|
</section>
|
|
|
|
<section id="secAPI_get_buffer_info">
|
|
<title>get_buffer_info</title>
|
|
|
|
<para>
|
|
Prototyp:
|
|
<command>
|
|
t_plugin_buffer_info *get_buffer_info (t_weechat_plugin *plugin)
|
|
</command>
|
|
</para>
|
|
<para>
|
|
Gibt eine Liste der WeeChat-Puffer zurück.
|
|
</para>
|
|
<para>
|
|
Argumente:
|
|
<itemizedlist>
|
|
<listitem>
|
|
<para>
|
|
<option>plugin</option>: Zeiger auf Pluginstruktur
|
|
</para>
|
|
</listitem>
|
|
</itemizedlist>
|
|
</para>
|
|
<para>
|
|
Rückgabewert: verkettete Liste der WeeChat-Puffer.
|
|
<informaltable colsep="0" frame="none">
|
|
<tgroup cols="2">
|
|
<thead>
|
|
<row>
|
|
<entry>Typ</entry>
|
|
<entry>Feld</entry>
|
|
<entry>Beschreibung</entry>
|
|
</row>
|
|
</thead>
|
|
<tbody>
|
|
<row>
|
|
<entry>int</entry>
|
|
<entry><literal>type</literal></entry>
|
|
<entry>Puffertyp: 0=standard, 1=dcc, 2=raw IRC data</entry>
|
|
</row>
|
|
<row>
|
|
<entry>int</entry>
|
|
<entry><literal>number</literal></entry>
|
|
<entry>Puffer-Nummer</entry>
|
|
</row>
|
|
<row>
|
|
<entry>int</entry>
|
|
<entry><literal>num_displayed</literal></entry>
|
|
<entry>Anzahl der Fenster im Puffer</entry>
|
|
</row>
|
|
<row>
|
|
<entry>char *</entry>
|
|
<entry><literal>server_name</literal></entry>
|
|
<entry>Servername für den Puffer (kann NULL sein)</entry>
|
|
</row>
|
|
<row>
|
|
<entry>char *</entry>
|
|
<entry><literal>channel_name</literal></entry>
|
|
<entry>Channelname für den Puffer (kann NULL sein)</entry>
|
|
</row>
|
|
<row>
|
|
<entry>int</entry>
|
|
<entry><literal>notify_level</literal></entry>
|
|
<entry>Benachrichtigungslevel für den Puffer</entry>
|
|
</row>
|
|
<row>
|
|
<entry>char *</entry>
|
|
<entry><literal>log_filename</literal></entry>
|
|
<entry>Name der Logdatei (NULL bedeutet, dass nichts geloggt wird)</entry>
|
|
</row>
|
|
<row>
|
|
<entry>t_plugin_buffer_info *</entry>
|
|
<entry><literal>prev_buffer</literal></entry>
|
|
<entry>Zeiger auf die vorhergehenden Pufferinformationen</entry>
|
|
</row>
|
|
<row>
|
|
<entry>t_plugin_buffer_info *</entry>
|
|
<entry><literal>next_buffer</literal></entry>
|
|
<entry>Zeiger auf die nächsten Pufferinformationen</entry>
|
|
</row>
|
|
</tbody>
|
|
</tgroup>
|
|
</informaltable>
|
|
</para>
|
|
<para>
|
|
Bemerkung: Das Ergebnis muss nach der Auswertung mit der "free_buffer_info"-Funktion
|
|
wieder gelöscht werden.
|
|
</para>
|
|
<para>
|
|
Beispiel:
|
|
<screen>
|
|
t_plugin_buffer_info *buffer_info, *ptr_buffer;
|
|
|
|
buffer_info = plugin->get_buffer_info (plugin);
|
|
if (buffer_info)
|
|
{
|
|
for (ptr_buffer = buffer_info; ptr_buffer; ptr_buffer = ptr_buffer->next_buffer)
|
|
{
|
|
plugin->print (plugin, NULL, NULL, "--- buffer info ---");
|
|
plugin->print (plugin, NULL, NULL, "type: %d", ptr_buffer->type);
|
|
plugin->print (plugin, NULL, NULL, "number: %d", ptr_buffer->number);
|
|
plugin->print (plugin, NULL, NULL, "num_displayed: %d", ptr_buffer->num_displayed);
|
|
plugin->print (plugin, NULL, NULL, "server: %s", ptr_buffer->server_name);
|
|
plugin->print (plugin, NULL, NULL, "channel: %s", ptr_buffer->channel_name);
|
|
plugin->print (plugin, NULL, NULL, "notify level: %d", ptr_buffer->notify_level);
|
|
plugin->print (plugin, NULL, NULL, "log filename: %s", ptr_buffer->log_filename);
|
|
}
|
|
plugin->free_buffer_info (plugin, buffer_info);
|
|
}
|
|
else
|
|
plugin->print (plugin, NULL, NULL, "no buffer info!");
|
|
</screen>
|
|
</para>
|
|
</section>
|
|
|
|
<section id="secAPI_free_buffer_info">
|
|
<title>free_buffer_info</title>
|
|
|
|
<para>
|
|
Prototyp:
|
|
<command>
|
|
void free_buffer_info (t_weechat_plugin *plugin,
|
|
t_plugin_buffer_info *buffer_info)
|
|
</command>
|
|
</para>
|
|
<para>
|
|
Gibt den Speicher frei, der von der Puffer-Informationsliste belegt wird.
|
|
</para>
|
|
<para>
|
|
Argumente:
|
|
<itemizedlist>
|
|
<listitem>
|
|
<para>
|
|
<option>plugin</option>: Zeiger auf Pluginstruktur
|
|
</para>
|
|
</listitem>
|
|
<listitem>
|
|
<para>
|
|
<option>buffer_info</option>: pointer to buffer info list
|
|
returned by "get_buffer_info" function
|
|
</para>
|
|
</listitem>
|
|
</itemizedlist>
|
|
</para>
|
|
<para>
|
|
Rückgabewert: keiner.
|
|
</para>
|
|
<para>
|
|
Beispiel:
|
|
<screen>plugin->free_buffer_info (plugin, buffer_info);</screen>
|
|
</para>
|
|
</section>
|
|
|
|
<section id="secAPI_get_buffer_data">
|
|
<title>get_buffer_data</title>
|
|
|
|
<para>
|
|
Prototype:
|
|
<command>
|
|
t_plugin_buffer_data *get_buffer_info (t_weechat_plugin *plugin,
|
|
char *server, char *channel)
|
|
</command>
|
|
</para>
|
|
<para>
|
|
Gibt den Inhalt des Puffers zurück.
|
|
</para>
|
|
<para>
|
|
Argumente:
|
|
<itemizedlist>
|
|
<listitem>
|
|
<para>
|
|
<option>plugin</option>: Zeiger auf Pluginstruktur
|
|
</para>
|
|
</listitem>
|
|
<listitem>
|
|
<para>
|
|
<option>server</option>: interner Name des Servers
|
|
</para>
|
|
</listitem>
|
|
<listitem>
|
|
<para>
|
|
<option>channel</option>: Channelname
|
|
</para>
|
|
</listitem>
|
|
</itemizedlist>
|
|
</para>
|
|
<para>
|
|
Rückgabewert: Pufferinhalt (verkettete Liste mit den Zeilen).
|
|
<informaltable colsep="0" frame="none">
|
|
<tgroup cols="2">
|
|
<thead>
|
|
<row>
|
|
<entry>Typ</entry>
|
|
<entry>Feld</entry>
|
|
<entry>Beschreibung</entry>
|
|
</row>
|
|
</thead>
|
|
<tbody>
|
|
<row>
|
|
<entry>time_t</entry>
|
|
<entry><literal>date</literal></entry>
|
|
<entry>Datum/Zeit</entry>
|
|
</row>
|
|
<row>
|
|
<entry>char *</entry>
|
|
<entry><literal>nick</literal></entry>
|
|
<entry>Nick</entry>
|
|
</row>
|
|
<row>
|
|
<entry>char *</entry>
|
|
<entry><literal>data</literal></entry>
|
|
<entry>Zeileninhalt (Farbcodes wurden entfernt)</entry>
|
|
</row>
|
|
<row>
|
|
<entry>t_plugin_buffer_line *</entry>
|
|
<entry><literal>prev_line</literal></entry>
|
|
<entry>Zeiger auf die vorherige Zeile</entry>
|
|
</row>
|
|
<row>
|
|
<entry>t_plugin_buffer_line *</entry>
|
|
<entry><literal>next_line</literal></entry>
|
|
<entry>Zeiger auf die nächste Zeile</entry>
|
|
</row>
|
|
</tbody>
|
|
</tgroup>
|
|
</informaltable>
|
|
</para>
|
|
<para>
|
|
Bemerkung: Das Ergebnis muss nach der Auswertung mit der "free_buffer_data"-Funktion
|
|
wieder gelöscht werden.
|
|
</para>
|
|
<para>
|
|
Example:
|
|
<screen>
|
|
t_plugin_buffer_line *buffer_line, *ptr_line;
|
|
char text_time[256];
|
|
|
|
buffer_line = plugin->get_buffer_data (plugin);
|
|
if (buffer_line)
|
|
{
|
|
for (ptr_line = buffer_line; ptr_line; ptr_line = ptr_line->next_line)
|
|
{
|
|
strftime (text_time, sizeof (text_time), "%x %X", localtime (&(ptr_line->date)));
|
|
plugin->print (plugin, NULL, NULL, "date: %s, nick: %s, data: %s",
|
|
text_time, ptr_line->nick, ptr_line->data);
|
|
}
|
|
plugin->free_buffer_data (plugin, buffer_line);
|
|
}
|
|
</screen>
|
|
</para>
|
|
</section>
|
|
|
|
<section id="secAPI_free_buffer_data">
|
|
<title>free_buffer_data</title>
|
|
|
|
<para>
|
|
Prototype:
|
|
<command>
|
|
void free_buffer_data (t_weechat_plugin *plugin,
|
|
t_plugin_buffer_line *buffer_line)
|
|
</command>
|
|
</para>
|
|
<para>
|
|
Gibt den Speicher frei, der von den Pufferzeilen belegt wurde.
|
|
</para>
|
|
<para>
|
|
Arguments:
|
|
<itemizedlist>
|
|
<listitem>
|
|
<para>
|
|
<option>plugin</option>: Zeiger auf Pluginstruktur
|
|
</para>
|
|
</listitem>
|
|
<listitem>
|
|
<para>
|
|
<option>buffer_line</option>: Zeiger auf Pufferzeilen, der
|
|
von der "get_buffer_data"-Funktion zurückgegeben wurde
|
|
</para>
|
|
</listitem>
|
|
</itemizedlist>
|
|
</para>
|
|
<para>
|
|
Rückgabewert: keiner.
|
|
</para>
|
|
<para>
|
|
Beispiele:
|
|
<screen>plugin->free_buffer_data (plugin, buffer_line);</screen>
|
|
</para>
|
|
</section>
|
|
|
|
</section>
|
|
|
|
<section id="secCompilePlugin">
|
|
<title>Übersetzen eines Plugins</title>
|
|
|
|
<para>
|
|
Das Übersetzen braucht keine WeeChat-Quellen, aber die Datei "<literal>weechat-plugin.h</literal>".
|
|
</para>
|
|
|
|
<para>
|
|
Um ein Plugin zu übersetzen, das aus einer Datei "toto.c" besteht (unter GNU/Linux):
|
|
<screen>
|
|
<prompt>$ </prompt><userinput>gcc -fPIC -Wall -c toto.c</userinput>
|
|
<prompt>$ </prompt><userinput>gcc -shared -fPIC -o libtoto.so toto.o</userinput>
|
|
</screen>
|
|
</para>
|
|
|
|
</section>
|
|
|
|
<section id="secLoadPlugin">
|
|
<title>Laden des Plugins in WeeChat</title>
|
|
|
|
<para>
|
|
Kopiere die Datei "libtoto.so" in das Plugin-Verzeichnis der systemweiten Dateien WeeChats
|
|
(zum Beispiel: "<literal>/usr/local/lib/weechat/plugins</literal>") oder in das Plugin-Verzeichnis
|
|
des Users (zum Beispiel: "<literal>/home/xxxxx/.weechat/plugins</literal>").
|
|
</para>
|
|
|
|
<para>
|
|
In WeeChat:
|
|
<screen><userinput>/plugin load toto</userinput></screen>
|
|
</para>
|
|
|
|
</section>
|
|
|
|
<section id="secPluginExample">
|
|
<title>Plugin Beispiel</title>
|
|
|
|
<para>
|
|
Vollständiges Beispiel eines Plugins, welches das Kommando /double implementiert, dass
|
|
seine Argumente im gegenwärtigen Channel doppelt ausgibt (ok, das ist weniger nützlich,
|
|
aber auch nur ein Beispiel!):
|
|
<screen>
|
|
#include <stdlib.h>
|
|
|
|
#include "weechat-plugin.h"
|
|
|
|
char plugin_name[] = "Double";
|
|
char plugin_version[] = "0.1";
|
|
char plugin_description[] = "Test plugin for WeeChat";
|
|
|
|
/* "/double" command manager */
|
|
|
|
int double_cmd (t_weechat_plugin *plugin, int argc, char **argv,
|
|
char *handler_args, void *handler_pointer)
|
|
{
|
|
if (argv[2] && (argv[2][0] != '/'))
|
|
{
|
|
plugin->exec_command (plugin, NULL, NULL, argv[2]);
|
|
plugin->exec_command (plugin, NULL, NULL, argv[2]);
|
|
}
|
|
return PLUGIN_RC_OK;
|
|
}
|
|
|
|
int weechat_plugin_init (t_weechat_plugin *plugin)
|
|
{
|
|
plugin->cmd_handler_add (plugin, "double",
|
|
"Display two times a message",
|
|
"msg",
|
|
"msg: message to display two times",
|
|
NULL,
|
|
&double_cmd,
|
|
NULL, NULL);
|
|
return PLUGIN_RC_OK;
|
|
}
|
|
|
|
void weechat_plugin_end (t_weechat_plugin *plugin)
|
|
{
|
|
/* nothing done here */
|
|
}
|
|
</screen>
|
|
</para>
|
|
|
|
</section>
|
|
|
|
</section>
|
|
|
|
<section id="secScriptsPlugins">
|
|
<title>Skript-Plugins</title>
|
|
|
|
<para>
|
|
Vier Plugins werden von WeeChat angeboten um Skriptsprachen zu nutzen:
|
|
Perl, Python, Ruby und Lua.
|
|
</para>
|
|
|
|
<section id="secLoadUnloadScripts">
|
|
<title>Laden / Entfernen von Skripten</title>
|
|
|
|
<para>
|
|
Scripts are loaded and unloaded with <command>/perl</command>,
|
|
<command>/python</command>, <command>/ruby</command> and
|
|
<command>/lua</command> commands
|
|
(type <command>/help</command> in WeeChat for help about commands).
|
|
|
|
Skripte werden mit den Kommandos <command>/perl</command>, <command>/python</command>,
|
|
<command>/ruby</command> und <command>/lua</command> geladen oder entfernt.
|
|
(Benutze <command>/help</command> in WeeChat für Hilfe zu den Kommandos).
|
|
</para>
|
|
|
|
<para>
|
|
Beispiele:
|
|
<itemizedlist>
|
|
<listitem>
|
|
<para>
|
|
Laden eines Perl-Skripts:
|
|
<command><userinput>/perl load /tmp/test.pl</userinput></command>
|
|
</para>
|
|
</listitem>
|
|
<listitem>
|
|
<para>
|
|
Liste alle geladenen Perl-Skripte auf:
|
|
<command><userinput>/perl</userinput></command>
|
|
</para>
|
|
</listitem>
|
|
<listitem>
|
|
<para>
|
|
Laden eines Python-Skripts:
|
|
<command><userinput>/python load /tmp/test.py</userinput></command>
|
|
</para>
|
|
</listitem>
|
|
<listitem>
|
|
<para>
|
|
Liste alle geladenen Python-Skripte auf:
|
|
<command><userinput>/python</userinput></command>
|
|
</para>
|
|
</listitem>
|
|
<listitem>
|
|
<para>
|
|
Laden eines Ruby-Skripts:
|
|
<command><userinput>/ruby load /tmp/test.rb</userinput></command>
|
|
</para>
|
|
</listitem>
|
|
<listitem>
|
|
<para>
|
|
Liste alle geladenen Ruby-Skripte auf:
|
|
<command><userinput>/ruby</userinput></command>
|
|
</para>
|
|
</listitem>
|
|
<listitem>
|
|
<para>
|
|
Laden eines Lua-Skripts:
|
|
<command><userinput>/lua load /tmp/test.lua</userinput></command>
|
|
</para>
|
|
</listitem>
|
|
<listitem>
|
|
<para>
|
|
Liste alle geladenen Lua-Skripte auf:
|
|
<command><userinput>/lua</userinput></command>
|
|
</para>
|
|
</listitem>
|
|
</itemizedlist>
|
|
</para>
|
|
|
|
</section>
|
|
|
|
<section id="secSyntaxByLanguage">
|
|
<title>Syntax in den Skriptsprachen</title>
|
|
|
|
<section id="secScriptPerl">
|
|
<title>Perl</title>
|
|
|
|
<para>
|
|
In einem WeeChat-PerlSkript ist allen API-Funktionen und Variablen ein
|
|
"<literal>weechat::</literal>" vorangestellt.
|
|
Beispiel:
|
|
<screen>weechat::register("test", "1.0", "end_test", "WeeChat perl script");</screen>
|
|
</para>
|
|
|
|
</section>
|
|
|
|
<section id="secScriptPython">
|
|
<title>Python</title>
|
|
|
|
<para>
|
|
Ein WeeChat-Pythonskript muss mit einer Importdirektive für WeeChat beginnen:
|
|
<screen>import weechat</screen>
|
|
</para>
|
|
|
|
<para>
|
|
Allen API-Funktionen und Variablen ist ein "<literal>weechat.</literal>" vorangestellt.
|
|
Beispiel:
|
|
<screen>weechat.register("test", "1.0", "end_test", "WeeChat python script")</screen>
|
|
</para>
|
|
|
|
</section>
|
|
|
|
<section id="secScriptRuby">
|
|
<title>Ruby</title>
|
|
|
|
<para>
|
|
In einem WeeChat-Rubyskript muss der gesamte Code innerhalb von
|
|
Funktionen stehen. Für den Hauptteil ist die Funktion "<literal>weechat_init</literal>"
|
|
zu definieren, die automatisch aufgerufen wird, wenn das Skript in WeeChat geladen wird.
|
|
Beispiel:
|
|
<screen>
|
|
def weechat_init
|
|
Weechat.register("test", "1.0", "end_test", "WeeChat ruby script")
|
|
Weechat.add_command_handler("command", "my_command")
|
|
return Weechat::PLUGIN_RC_OK
|
|
end
|
|
|
|
def my_command(server, args)
|
|
Weechat.print("my command")
|
|
return Weechat::PLUGIN_RC_OK
|
|
end
|
|
</screen>
|
|
</para>
|
|
|
|
<para>
|
|
Allen API-Funktionen ist "<literal>Weechat.</literal>"
|
|
und Variablen "<literal>Weechat::</literal>" vorangestellt.
|
|
</para>
|
|
|
|
</section>
|
|
|
|
<section id="secScriptLua">
|
|
<title>Lua</title>
|
|
|
|
<para>
|
|
In einem WeeChat-Luaskript ist allen Funktionen ein "<literal>weechat.</literal>"
|
|
vorangestellt. Variablen beginnen mit "<literal>weechat.</literal>" und
|
|
enden mit "<literal>()</literal>".
|
|
Beispiel:
|
|
<screen>
|
|
function message_handler(server, args)
|
|
weechat.print("I am a message handler")
|
|
return weechat.PLUGIN_RC_OK()
|
|
end
|
|
</screen>
|
|
</para>
|
|
|
|
</section>
|
|
|
|
</section>
|
|
|
|
<section id="secWeeChatScriptsAPI">
|
|
<title>WeeChat / Skript-API</title>
|
|
|
|
<section id="secScript_register">
|
|
<title>register</title>
|
|
|
|
<para>
|
|
Perl-Prototyp:
|
|
<command>
|
|
weechat::register(name, version, end_function, description, [charset]);
|
|
</command>
|
|
</para>
|
|
<para>
|
|
Python-Prototyp:
|
|
<command>
|
|
weechat.register(name, version, end_function, description, [charset])
|
|
</command>
|
|
</para>
|
|
<para>
|
|
Ruby-Prototyp:
|
|
<command>
|
|
Weechat.register(name, version, end_function, description, [charset])
|
|
</command>
|
|
</para>
|
|
<para>
|
|
Lua-Prototyp:
|
|
<command>
|
|
weechat.register(name, version, end_function, description, [charset])
|
|
</command>
|
|
</para>
|
|
<para>
|
|
Das ist die erste Funktion, die in einem Skript aufgerufen wird.
|
|
Alle WeeChat-Skripte müssen diese Funktion aufrufen.
|
|
</para>
|
|
<para>
|
|
Argumente:
|
|
<itemizedlist>
|
|
<listitem>
|
|
<para>
|
|
<option>name</option>: eindeutiger Name des Skripts
|
|
(jedes Skript muss einen eindeutigen Namen besitzen)
|
|
</para>
|
|
</listitem>
|
|
<listitem>
|
|
<para>
|
|
<option>version</option>: Version des Skripts
|
|
</para>
|
|
</listitem>
|
|
<listitem>
|
|
<para>
|
|
<option>end_function</option>: Funktion, die aufgerufen wird, wenn
|
|
das Skript entfernt werden soll (optional; ein leerer String bedeutet,
|
|
dass nichts aufgerufen wird)
|
|
</para>
|
|
</listitem>
|
|
<listitem>
|
|
<para>
|
|
<option>description</option>: eine kurze Beschreibung des Skripts
|
|
</para>
|
|
</listitem>
|
|
<listitem>
|
|
<para>
|
|
<!-- TRANSLATION NEEDED -->
|
|
<option>charset</option>: charset used by script, you should
|
|
set this if script is not written with UTF-8
|
|
</para>
|
|
</listitem>
|
|
</itemizedlist>
|
|
</para>
|
|
<para>
|
|
Rückgabewert: 1 wenn das Skript registriert werden konnte, 0 wenn ein Fehler aufgetaucht ist.
|
|
</para>
|
|
<para>
|
|
Beispiele:
|
|
<screen>
|
|
# perl
|
|
weechat::register("test", "1.0", "end_test", "Test script!", "ISO-8859-1");
|
|
|
|
# python
|
|
weechat.register("test", "1.0", "end_test", "Test script!", "ISO-8859-1")
|
|
|
|
# ruby
|
|
Weechat.register("test", "1.0", "end_test", "Test script!", "ISO-8859-1")
|
|
|
|
-- lua
|
|
weechat.register("test", "1.0", "end_test", "Test script!", "ISO-8859-1")
|
|
</screen>
|
|
</para>
|
|
</section>
|
|
|
|
<!-- TRANSLATION NEEDED -->
|
|
<section id="secScript_set_charset">
|
|
<title>set_charset</title>
|
|
|
|
<para>
|
|
Perl prototype:
|
|
<command>
|
|
weechat::set_charset(charset);
|
|
</command>
|
|
</para>
|
|
<para>
|
|
Python prototype:
|
|
<command>
|
|
weechat.set_charset(charset)
|
|
</command>
|
|
</para>
|
|
<para>
|
|
Ruby prototype:
|
|
<command>
|
|
Weechat.set_charset(charset)
|
|
</command>
|
|
</para>
|
|
<para>
|
|
Lua prototype:
|
|
<command>
|
|
weechat.set_charset(charset)
|
|
</command>
|
|
</para>
|
|
<para>
|
|
Set new script charset.
|
|
</para>
|
|
<para>
|
|
Arguments:
|
|
<itemizedlist>
|
|
<listitem>
|
|
<para>
|
|
<option>charset</option>: new script charset
|
|
</para>
|
|
</listitem>
|
|
</itemizedlist>
|
|
</para>
|
|
<para>
|
|
Return value: 1 if new charset was set, 0 if an error occured.
|
|
</para>
|
|
<para>
|
|
Examples:
|
|
<screen>
|
|
# perl
|
|
weechat::set_charset("ISO-8859-1");
|
|
|
|
# python
|
|
weechat.set_charset("ISO-8859-1")
|
|
|
|
# ruby
|
|
Weechat.set_charset("ISO-8859-1")
|
|
|
|
-- lua
|
|
weechat.set_charset("ISO-8859-1")
|
|
</screen>
|
|
</para>
|
|
</section>
|
|
|
|
<section id="secScript_print">
|
|
<title>print</title>
|
|
|
|
<para>
|
|
Perl-Prototyp:
|
|
<command>
|
|
weechat::print(message, [channel, [server]])
|
|
</command>
|
|
</para>
|
|
<para>
|
|
Python-Prototyp:
|
|
<command>
|
|
weechat.prnt(message, [channel, [server]])
|
|
</command>
|
|
</para>
|
|
<para>
|
|
Ruby-Prototyp:
|
|
<command>
|
|
Weechat.print(message, [channel, [server]])
|
|
</command>
|
|
</para>
|
|
<para>
|
|
Lua-Prototyp:
|
|
<command>
|
|
weechat.print(message, [channel, [server]])
|
|
</command>
|
|
</para>
|
|
<para>
|
|
Sende eine Nachricht an einen WeeChat-Puffer, identifiziert durch Server
|
|
und Channel.
|
|
</para>
|
|
<para>
|
|
Argumente:
|
|
<itemizedlist>
|
|
<listitem>
|
|
<para>
|
|
<option>message</option>: Nachricht
|
|
</para>
|
|
</listitem>
|
|
<listitem>
|
|
<para>
|
|
<option>channel</option>: Name des Channels, zu welchem der Puffer gehört, in dem die
|
|
Nachricht angezeigt werden soll
|
|
</para>
|
|
</listitem>
|
|
<listitem>
|
|
<para>
|
|
<option>server</option>: interner Name des Servers, zu welchem der Puffer gehört, in dem
|
|
die Nachricht angezeigt werden soll
|
|
</para>
|
|
</listitem>
|
|
</itemizedlist>
|
|
</para>
|
|
<para>
|
|
Rückgabewert: 1 bei Erfolg, 0 wenn ein Fehler aufgetreten ist
|
|
</para>
|
|
<para>
|
|
Beispiele:
|
|
<screen>
|
|
# perl
|
|
weechat::print("message");
|
|
weechat::print("message", "#weechat");
|
|
weechat::print("message", "#weechat", "freenode");
|
|
|
|
# python
|
|
weechat.prnt("message")
|
|
weechat.prnt("message", "#weechat")
|
|
weechat.prnt("message", "#weechat", "freenode")
|
|
|
|
# ruby
|
|
Weechat.print("message")
|
|
Weechat.print("message", "#weechat")
|
|
Weechat.print("message", "#weechat", "freenode")
|
|
|
|
-- lua
|
|
weechat.print("message")
|
|
weechat.print("message", "#weechat")
|
|
weechat.print("message", "#weechat", "freenode")
|
|
</screen>
|
|
</para>
|
|
</section>
|
|
|
|
<section id="secScript_print_infobar">
|
|
<title>print_infobar</title>
|
|
|
|
<para>
|
|
Perl-Prototyp:
|
|
<command>
|
|
weechat::print_infobar(time, message);
|
|
</command>
|
|
</para>
|
|
<para>
|
|
Python-Prototyp:
|
|
<command>
|
|
weechat.print_infobar(time, message)
|
|
</command>
|
|
</para>
|
|
<para>
|
|
Ruby-Prototyp:
|
|
<command>
|
|
Weechat.print_infobar(time, message)
|
|
</command>
|
|
</para>
|
|
<para>
|
|
Lua-Prototyp:
|
|
<command>
|
|
weechat.print_infobar(time, message)
|
|
</command>
|
|
</para>
|
|
<para>
|
|
Zeige eine Nachricht für einen festen Zeitraum in der Infobar.
|
|
</para>
|
|
<para>
|
|
Argumente:
|
|
<itemizedlist>
|
|
<listitem>
|
|
<para>
|
|
<option>time</option>: Zeit (in sekunden) der Anzeige (0 = permanent)
|
|
</para>
|
|
</listitem>
|
|
<listitem>
|
|
<para>
|
|
<option>message</option>: Nachricht
|
|
</para>
|
|
</listitem>
|
|
</itemizedlist>
|
|
</para>
|
|
<para>
|
|
Rückgabewert: 1 bei Erfolg, 0 wenn ein Fehler aufgetreten ist
|
|
</para>
|
|
<para>
|
|
Beispiele:
|
|
<screen>
|
|
# perl
|
|
weechat::print_infobar(5, "message");
|
|
|
|
# python
|
|
weechat.print_infobar(5, "message")
|
|
|
|
# ruby
|
|
Weechat.print_infobar(5, "message")
|
|
|
|
-- lua
|
|
weechat.print_infobar(5, "message")
|
|
</screen>
|
|
</para>
|
|
</section>
|
|
|
|
<section id="secScript_remove_infobar">
|
|
<title>remove_infobar</title>
|
|
|
|
<para>
|
|
Perl-Prototyp:
|
|
<command>
|
|
weechat::remove_infobar([count]);
|
|
</command>
|
|
</para>
|
|
<para>
|
|
Python-Prototyp:
|
|
<command>
|
|
weechat.remove_infobar([count])
|
|
</command>
|
|
</para>
|
|
<para>
|
|
Ruby-Prototyp:
|
|
<command>
|
|
Weechat.remove_infobar([count])
|
|
</command>
|
|
</para>
|
|
<para>
|
|
Lua-Prototyp:
|
|
<command>
|
|
weechat.remove_infobar([count])
|
|
</command>
|
|
</para>
|
|
<para>
|
|
Entfernt eine oder mehrere Nachrichten aus dem Infobar-Speicher.
|
|
</para>
|
|
<para>
|
|
Argumente:
|
|
<itemizedlist>
|
|
<listitem>
|
|
<para>
|
|
<option>count</option>: Anzahl der Nachrichten, die entfernt werden sollen
|
|
(Ist kein Argument angegeben oder <= 0 werden alle Nachrichten entfernt)
|
|
</para>
|
|
</listitem>
|
|
</itemizedlist>
|
|
</para>
|
|
<para>
|
|
Rückgabewert: 1 bei Erfolg, 0 bei Auftreten eines Fehlers
|
|
</para>
|
|
<para>
|
|
Beispiele:
|
|
<screen>
|
|
# perl
|
|
weechat::remove_infobar(1);
|
|
|
|
# python
|
|
weechat.remove_infobar(1)
|
|
|
|
# ruby
|
|
Weechat.remove_infobar(1)
|
|
|
|
-- lua
|
|
weechat.remove_infobar(1)
|
|
</screen>
|
|
</para>
|
|
</section>
|
|
|
|
<section id="secScript_log">
|
|
<title>log</title>
|
|
|
|
<para>
|
|
Perl-Prototyp:
|
|
<command>
|
|
weechat::log(message, [channel, [server]]);
|
|
</command>
|
|
</para>
|
|
<para>
|
|
Python-Prototyp:
|
|
<command>
|
|
weechat.log(message, [channel, [server]])
|
|
</command>
|
|
</para>
|
|
<para>
|
|
Ruby-Prototyp:
|
|
<command>
|
|
Weechat.log(message, [channel, [server]])
|
|
</command>
|
|
</para>
|
|
<para>
|
|
Lua-Prototyp:
|
|
<command>
|
|
weechat.log(message, [channel, [server]])
|
|
</command>
|
|
</para>
|
|
<para>
|
|
Schreibe eine Nachricht in die Logdatei eines Servers oder Channels.
|
|
</para>
|
|
<para>
|
|
Argumente:
|
|
<itemizedlist>
|
|
<listitem>
|
|
<para>
|
|
<option>message</option>: Nachricht
|
|
</para>
|
|
</listitem>
|
|
<listitem>
|
|
<para>
|
|
<option>channel</option>: Name des Channels, zu welchem der Puffer der Logdatei gehört
|
|
</para>
|
|
</listitem>
|
|
<listitem>
|
|
<para>
|
|
<option>server</option>: interner Name des Servers, zu welchem der Puffer der Logdatei gehört
|
|
</para>
|
|
</listitem>
|
|
</itemizedlist>
|
|
</para>
|
|
<para>
|
|
Rückgabewert: 1 bei Erfolg, 0 wenn ein Fehler aufgetreten ist.
|
|
</para>
|
|
<para>
|
|
Beispiel:
|
|
<screen>
|
|
# perl
|
|
weechat::log("message", "#weechat", "freenode");
|
|
|
|
# python
|
|
weechat.log("message", "#weechat", "freenode")
|
|
|
|
# ruby
|
|
Weechat.log("message", "#weechat", "freenode")
|
|
|
|
-- lua
|
|
weechat.log("message", "#weechat", "freenode")
|
|
</screen>
|
|
</para>
|
|
</section>
|
|
|
|
<section id="secScript_add_message_handler">
|
|
<title>add_message_handler</title>
|
|
|
|
<para>
|
|
Perl-Prototyp:
|
|
<command>
|
|
weechat::add_message_handler(message, function);
|
|
</command>
|
|
</para>
|
|
<para>
|
|
Python-Prototyp:
|
|
<command>
|
|
weechat.add_message_handler(message, function)
|
|
</command>
|
|
</para>
|
|
<para>
|
|
Ruby-Prototyp:
|
|
<command>
|
|
Weechat.add_message_handler(message, function)
|
|
</command>
|
|
</para>
|
|
<para>
|
|
Lua-Prototyp:
|
|
<command>
|
|
weechat.add_message_handler(message, function)
|
|
</command>
|
|
</para>
|
|
<para>
|
|
Erzeuge einen Nachrichten-Handler, der bei Empfang einer IRC-Nachricht aufgerufen wird.
|
|
</para>
|
|
<para>
|
|
Argumente:
|
|
<itemizedlist>
|
|
<listitem>
|
|
<para>
|
|
<option>message</option>: Name (Typ) der IRC-Nachricht. Für eine Liste
|
|
der bekannten Typen von IRC-Nachrichten konsultieren sie bitte die
|
|
<acronym>RFC</acronym>s
|
|
<ulink url="http://www.ietf.org/rfc/rfc1459.txt">1459</ulink> und
|
|
<ulink url="http://www.ietf.org/rfc/rfc2812.txt">2812</ulink>.
|
|
Mehr noch, sie können spezielle Ereignisse abfangen, indem sie einen speziellen Namen verwenden, der mit
|
|
"weechat_" beginnt (siehe <xref linkend="secAPI_msg_handler_add" />).
|
|
</para>
|
|
</listitem>
|
|
<listitem>
|
|
<para>
|
|
<option>function</option>: Funktion, die bei Empfang einer Nachricht aufgerufen werden soll
|
|
</para>
|
|
</listitem>
|
|
</itemizedlist>
|
|
</para>
|
|
<para>
|
|
Rückgabewert: 1 bei Erfolg, 0 wenn ein Fehler aufgetreten ist.
|
|
</para>
|
|
<para>
|
|
Beispiele:
|
|
<screen>
|
|
# perl
|
|
weechat::add_message_handler ("privmsg", "my_function");
|
|
sub my_function
|
|
{
|
|
weechat::print("server=$_[0]");
|
|
($null, $channel, $message) = split ":",$_[1],3;
|
|
($mask, $null, $channel) = split " ", $channel;
|
|
weechat::print("mask=$mask, channel=$channel, msg=$message");
|
|
return weechat::PLUGIN_RC_OK;
|
|
}
|
|
|
|
# python
|
|
weechat.add_message_handler ("privmsg", "my_function")
|
|
def my_function(server, args):
|
|
weechat.prnt("server="+server)
|
|
null, channel, message = string.split(args, ":", 2)
|
|
mask, null, channel = string.split(string.strip(channel), " ", 2)
|
|
weechat.prnt("mask="+mask+", canal="+channel+", message="+message)
|
|
return weechat.PLUGIN_RC_OK
|
|
|
|
# ruby
|
|
Weechat.add_message_handler("privmsg", "my_function")
|
|
def my_function(server, args)
|
|
Weechat.print("server=#{server}, args=#{args}")
|
|
return Weechat::PLUGIN_RC_OK
|
|
end
|
|
|
|
-- lua
|
|
weechat.add_message_handler ("privmsg", "my_function")
|
|
function my_function(server, args)
|
|
weechat.print("server=" .. server .. ", args=" .. args)
|
|
return weechat.PLUGIN_RC_OK()
|
|
end
|
|
</screen>
|
|
</para>
|
|
<para>
|
|
Hinweis: die Funktion, die aufgerufen wird wenn eine Nachricht
|
|
empfangen wurde, muss einen der folgenden Werte zurückgeben:
|
|
<itemizedlist>
|
|
<listitem>
|
|
<para>
|
|
<literal>PLUGIN_RC_KO</literal>: Funktion fehlgeschlagen
|
|
</para>
|
|
</listitem>
|
|
<listitem>
|
|
<para>
|
|
<literal>PLUGIN_RC_OK</literal>: Funktion war erfolgreich
|
|
</para>
|
|
</listitem>
|
|
<listitem>
|
|
<para>
|
|
<literal>PLUGIN_RC_OK_IGNORE_WEECHAT</literal>: Die Nachricht wird nicht an WeeChat übergeben
|
|
</para>
|
|
</listitem>
|
|
<listitem>
|
|
<para>
|
|
<literal>PLUGIN_RC_OK_IGNORE_PLUGINS</literal>: Die Nachricht wird nicht an andere Plugins
|
|
weitergegeben
|
|
</para>
|
|
</listitem>
|
|
<listitem>
|
|
<para>
|
|
<literal>PLUGIN_RC_OK_IGNORE_ALL</literal>: Die Nachricht wird weder
|
|
an WeeChat noch an andere Plugins übergeben
|
|
</para>
|
|
</listitem>
|
|
</itemizedlist>
|
|
</para>
|
|
</section>
|
|
|
|
<section id="secScript_add_command_handler">
|
|
<title>add_command_handler</title>
|
|
|
|
<para>
|
|
Perl-Prototyp:
|
|
<command>
|
|
weechat::add_command_handler(command, function,
|
|
[description, arguments, arguments_description,
|
|
completion_template]);
|
|
</command>
|
|
</para>
|
|
<para>
|
|
Python-Prototyp:
|
|
<command>
|
|
weechat.add_command_handler(command, function,
|
|
[description, arguments, arguments_description,
|
|
completion_template])
|
|
</command>
|
|
</para>
|
|
<para>
|
|
Ruby-Prototyp:
|
|
<command>
|
|
Weechat.add_command_handler(command, function,
|
|
[description, arguments, arguments_description,
|
|
completion_template])
|
|
</command>
|
|
</para>
|
|
<para>
|
|
Lua-Prototyp:
|
|
<command>
|
|
weechat.add_command_handler(command, function,
|
|
[description, arguments, arguments_description,
|
|
completion_template])
|
|
</command>
|
|
</para>
|
|
<para>
|
|
Erzeugt einen Kommando-Handler, der aufgerufen wird, wenn der Anwender
|
|
das Kommando benutzt (Beispiel: /command).
|
|
</para>
|
|
<para>
|
|
Argumente:
|
|
<itemizedlist>
|
|
<listitem>
|
|
<para>
|
|
<option>command</option>:
|
|
Name des neuen Kommandos, der auch Name eines bereits
|
|
existierenden Kommandos sein kann (mit Bedacht zu verwenden,
|
|
das ersetzte Kommando ist nicht verfügbar, bis das Plugin entfernt wurde)
|
|
</para>
|
|
</listitem>
|
|
<listitem>
|
|
<para>
|
|
<option>function</option>: Funktion, die aufgerufen wird, wenn
|
|
das Kommando ausgeführt wird
|
|
</para>
|
|
</listitem>
|
|
<listitem>
|
|
<para>
|
|
<option>arguments</option>: eine kurze Beschreibung der Argumente des Kommandos
|
|
(werden angezeigt bei /help command)
|
|
</para>
|
|
</listitem>
|
|
<listitem>
|
|
<para>
|
|
<option>arguments_description</option>: eine ausführliche Beschreibung der Argumente
|
|
des Kommandos (werden angezeigt bei /help command)
|
|
</para>
|
|
</listitem>
|
|
<listitem>
|
|
<para>
|
|
<option>completion_template</option>:
|
|
Vorlage für die Vervollständigung; zum Beispiel bedeutet
|
|
"<literal>abc|%w def|%i</literal>", dass das
|
|
erste Argument "abc" oder ein WeeChat-Kommando sein kann
|
|
und das zweite Argument "def" oder ein IRC-Kommando.
|
|
(siehe <xref linkend="secAPI_cmd_handler_add" />)
|
|
</para>
|
|
</listitem>
|
|
</itemizedlist>
|
|
</para>
|
|
<para>
|
|
Rückgabewert: 1 bei Erfolg, 0 wenn ein Fehler aufgetreten ist
|
|
</para>
|
|
<para>
|
|
Beispiele:
|
|
<screen>
|
|
# perl
|
|
weechat::add_command_handler("command", "my_command");
|
|
sub my_command
|
|
{
|
|
weechat::print("server= $_[0], args: $_[1]");
|
|
return weechat::PLUGIN_RC_OK;
|
|
}
|
|
|
|
# python
|
|
weechat.add_command_handler("command", "my_command")
|
|
def my_command(server, args):
|
|
weechat.prnt("server="+server+", args="+args)
|
|
return weechat.PLUGIN_RC_OK
|
|
|
|
# ruby
|
|
Weechat.add_command_handler("command", "my_command")
|
|
def my_command(server, args)
|
|
Weechat.print("server=#{server}, args=#{args}")
|
|
return Weechat::PLUGIN_RC_OK
|
|
end
|
|
|
|
-- lua
|
|
weechat.add_command_handler("command", "my_command")
|
|
def my_command(server, args)
|
|
weechat.print("server="..server..", args="..args)
|
|
return weechat.PLUGIN_RC_OK()
|
|
end
|
|
</screen>
|
|
</para>
|
|
<para>
|
|
Hinweis: die Funktion, die aufgerufen wird wenn eine Nachricht
|
|
empfangen wurde, muss einen der folgenden Werte zurückgeben:
|
|
|
|
<itemizedlist>
|
|
<listitem>
|
|
<para>
|
|
<literal>PLUGIN_RC_KO</literal> : Funktion ist fehlgeschlagen
|
|
</para>
|
|
</listitem>
|
|
<listitem>
|
|
<para>
|
|
<literal>PLUGIN_RC_OK</literal> : Funktion war erfolgreich
|
|
</para>
|
|
</listitem>
|
|
</itemizedlist>
|
|
</para>
|
|
</section>
|
|
|
|
<section id="secScript_add_timer_handler">
|
|
<title>add_timer_handler</title>
|
|
|
|
<para>
|
|
Perl-Prototyp:
|
|
<command>
|
|
weechat::add_timer_handler(interval, function);
|
|
</command>
|
|
</para>
|
|
<para>
|
|
Python-Prototyp:
|
|
<command>
|
|
weechat.add_timer_handler(interval, function)
|
|
</command>
|
|
</para>
|
|
<para>
|
|
Ruby-Prototyp:
|
|
<command>
|
|
Weechat.add_timer_handler(interval, function)
|
|
</command>
|
|
</para>
|
|
<para>
|
|
Lua-Prototyp:
|
|
<command>
|
|
weechat.add_timer_handler(interval, function)
|
|
</command>
|
|
</para>
|
|
<para>
|
|
Erzeugt einen zeitgesteuerten Handler, der periodisch eine Funktion aufruft.
|
|
</para>
|
|
<para>
|
|
Argumente:
|
|
<itemizedlist>
|
|
<listitem>
|
|
<para>
|
|
<option>interval</option>: Interval (in Sekunden) zwischen
|
|
zwei Aufrufen der Funktion.
|
|
</para>
|
|
</listitem>
|
|
<listitem>
|
|
<para>
|
|
<option>function</option>: Funktion, die aufgerufen wird
|
|
</para>
|
|
</listitem>
|
|
</itemizedlist>
|
|
</para>
|
|
<para>
|
|
Rückgabewert: 1 bei Erfolg, 0 wenn ein Fehler aufgetreten ist
|
|
</para>
|
|
<para>
|
|
Beispiele:
|
|
<screen>
|
|
# perl
|
|
weechat::add_timer_handler(60, "my_timer");
|
|
sub my_timer
|
|
{
|
|
weechat::print("this is timer handler");
|
|
return weechat::PLUGIN_RC_OK;
|
|
}
|
|
|
|
# python
|
|
weechat.add_timer_handler(60, "my_timer")
|
|
def my_timer():
|
|
weechat.prnt("this is timer handler")
|
|
return weechat.PLUGIN_RC_OK
|
|
|
|
# ruby
|
|
Weechat.add_timer_handler(60, "my_timer")
|
|
def my_timer()
|
|
Weechat.print("this is timer handler")
|
|
return Weechat::PLUGIN_RC_OK
|
|
end
|
|
|
|
-- lua
|
|
weechat.add_timer_handler(60, "my_timer")
|
|
function my_timer()
|
|
weechat.print("this is timer handler")
|
|
return weechat.PLUGIN_RC_OK()
|
|
end
|
|
</screen>
|
|
</para>
|
|
<para>
|
|
Note: function called has to return one of following values:
|
|
Hinweis: die Funktion, die aufgerufen wird, muss
|
|
einen der folgenden Werte zurückgeben:
|
|
|
|
<itemizedlist>
|
|
<listitem>
|
|
<para>
|
|
<literal>PLUGIN_RC_KO</literal>: Funktion ist fehlgeschlagen
|
|
</para>
|
|
</listitem>
|
|
<listitem>
|
|
<para>
|
|
<literal>PLUGIN_RC_OK</literal>: Funktion war erfolgreich
|
|
completed
|
|
</para>
|
|
</listitem>
|
|
</itemizedlist>
|
|
</para>
|
|
</section>
|
|
|
|
<section id="secScript_add_keyboard_handler">
|
|
<title>add_keyboard_handler</title>
|
|
|
|
<para>
|
|
Perl-Prototyp:
|
|
<command>
|
|
weechat::add_keyboard_handler(function);
|
|
</command>
|
|
</para>
|
|
<para>
|
|
Python-Prototyp:
|
|
<command>
|
|
weechat.add_keyboard_handler(function)
|
|
</command>
|
|
</para>
|
|
<para>
|
|
Ruby-Prototyp:
|
|
<command>
|
|
Weechat.add_keyboard_handler(function)
|
|
</command>
|
|
</para>
|
|
<para>
|
|
Lua-Prototyp:
|
|
<command>
|
|
weechat.add_keyboard_handler(function)
|
|
</command>
|
|
</para>
|
|
<para>
|
|
Erzeugt einen Keyboard-Handler, der für jeden Tastendruck aufgerufen wird.
|
|
</para>
|
|
<para>
|
|
Argumente:
|
|
<itemizedlist>
|
|
<listitem>
|
|
<para>
|
|
<option>function</option>: Funktion, die aufgerufen wird
|
|
</para>
|
|
</listitem>
|
|
</itemizedlist>
|
|
</para>
|
|
<para>
|
|
Rückgabewert: 1 bei Erfolg, 0 wenn ein Fehler aufgetreten ist
|
|
</para>
|
|
<para>
|
|
Beispiele:
|
|
<screen>
|
|
# perl
|
|
weechat::add_keyboard_handler("my_keyboard");
|
|
sub my_keyboard
|
|
{
|
|
my $key = shift;
|
|
my $input_before = shift;
|
|
my $input_after = shift;
|
|
weechat::print("keyboard handler: key = '$key', "
|
|
."input before = '$input_before' "
|
|
."after = '$input_after'");
|
|
return weechat::PLUGIN_RC_OK;
|
|
}
|
|
|
|
# python
|
|
weechat.add_keyboard_handler("my_keyboard")
|
|
def my_keyboard(key, input_before, input_after):
|
|
weechat.prnt("keyboard handler: key = '%s', " \
|
|
"input before = '%s' after = '%s'"
|
|
%(key, input_before, input_after))
|
|
return weechat.PLUGIN_RC_OK
|
|
|
|
# ruby
|
|
Weechat.add_keyboard_handler("my_keyboard")
|
|
def my_keyboard(server, input_before, input_after)
|
|
Weechat.print("keyboard handler: key = '#{key}', " \
|
|
"input before = '#{input_before}' " \
|
|
"after = '#{input_after}'")
|
|
return Weechat::PLUGIN_RC_OK
|
|
end
|
|
|
|
-- lua
|
|
weechat.add_keyboard_handler("my_keyboard")
|
|
function my_keyboard(server, input_before, input_after)
|
|
weechat.print("keyboard handler: key = '"..key..
|
|
"', input before = '"..input_before..
|
|
"' after = '"..input_after.."'")
|
|
return weechat.PLUGIN_RC_OK()
|
|
end
|
|
</screen>
|
|
</para>
|
|
<para>
|
|
Hinweis: Die aufgerufene Funktion muss einen der folgenden Werte zurückgeben:
|
|
<itemizedlist>
|
|
<listitem>
|
|
<para>
|
|
<literal>PLUGIN_RC_KO</literal>: Funktion ist fehlgeschlagen
|
|
</para>
|
|
</listitem>
|
|
<listitem>
|
|
<para>
|
|
<literal>PLUGIN_RC_OK</literal>: Funktion war erfolgreich
|
|
</para>
|
|
</listitem>
|
|
</itemizedlist>
|
|
</para>
|
|
</section>
|
|
|
|
<section id="secScript_remove_handler">
|
|
<title>remove_handler</title>
|
|
|
|
<para>
|
|
Perl-Prototyp:
|
|
<command>
|
|
weechat::remove_handler(name, function);
|
|
</command>
|
|
</para>
|
|
<para>
|
|
Python-Prototyp:
|
|
<command>
|
|
weechat.remove_handler(name, function)
|
|
</command>
|
|
</para>
|
|
<para>
|
|
Ruby-Prototyp:
|
|
<command>
|
|
Weechat.remove_handler(name, function)
|
|
</command>
|
|
</para>
|
|
<para>
|
|
Lua-Prototyp:
|
|
<command>
|
|
weechat.remove_handler(name, function)
|
|
</command>
|
|
</para>
|
|
<para>
|
|
Entfernt einen Nachrichten- oder Kommando-Handler.
|
|
</para>
|
|
<para>
|
|
Argumente:
|
|
<itemizedlist>
|
|
<listitem>
|
|
<para>
|
|
<option>name</option>: Name der IRC-Message oder Kommando
|
|
</para>
|
|
</listitem>
|
|
<listitem>
|
|
<para>
|
|
<option>function</option>: Funktion
|
|
</para>
|
|
</listitem>
|
|
</itemizedlist>
|
|
</para>
|
|
<para>
|
|
Rückgabewert: 1 bei Erfolg, 0 bei Auftreten eines Fehlers
|
|
</para>
|
|
<para>
|
|
Beispiele:
|
|
<screen>
|
|
# perl
|
|
weechat::remove_handler("command", "my_command");
|
|
|
|
# python
|
|
weechat.remove_handler("command", "my_command")
|
|
|
|
# ruby
|
|
Weechat.remove_handler("command", "my_command")
|
|
|
|
-- lua
|
|
weechat.remove_handler("command", "my_command")
|
|
</screen>
|
|
</para>
|
|
</section>
|
|
|
|
<section id="secScript_remove_timer_handler">
|
|
<title>remove_timer_handler</title>
|
|
|
|
<para>
|
|
Perl-Prototyp:
|
|
<command>
|
|
weechat::remove_timer_handler(function);
|
|
</command>
|
|
</para>
|
|
<para>
|
|
Python-Prototyp:
|
|
<command>
|
|
weechat.remove_timer_handler(function)
|
|
</command>
|
|
</para>
|
|
<para>
|
|
Ruby-Prototyp:
|
|
<command>
|
|
Weechat.remove_timer_handler(function)
|
|
</command>
|
|
</para>
|
|
<para>
|
|
Lua-Prototyp:
|
|
<command>
|
|
weechat.remove_timer_handler(function)
|
|
</command>
|
|
</para>
|
|
<para>
|
|
Entfernt einen zeitgesteuerten Handler.
|
|
</para>
|
|
<para>
|
|
Argumente:
|
|
<itemizedlist>
|
|
<listitem>
|
|
<para>
|
|
<option>function</option>: Funktion
|
|
</para>
|
|
</listitem>
|
|
</itemizedlist>
|
|
</para>
|
|
<para>
|
|
Rückgabewert: 1 bei Erfolg, 0 wenn ein Fehler aufgetreten ist
|
|
</para>
|
|
<para>
|
|
Beispiele:
|
|
<screen>
|
|
# perl
|
|
weechat::remove_timer_handler("my_timer");
|
|
|
|
# python
|
|
weechat.remove_timer_handler("my_timer")
|
|
|
|
# ruby
|
|
Weechat.remove_timer_handler("my_timer")
|
|
|
|
-- lua
|
|
weechat.remove_timer_handler("my_timer")
|
|
</screen>
|
|
</para>
|
|
</section>
|
|
|
|
<section id="secScript_remove_keyboard_handler">
|
|
<title>remove_keyboard_handler</title>
|
|
|
|
<para>
|
|
Perl-Prototyp:
|
|
<command>
|
|
weechat::remove_keyboard_handler(function);
|
|
</command>
|
|
</para>
|
|
<para>
|
|
Python-Prototyp:
|
|
<command>
|
|
weechat.remove_keyboard_handler(function)
|
|
</command>
|
|
</para>
|
|
<para>
|
|
Ruby-Prototyp:
|
|
<command>
|
|
Weechat.remove_keyboard_handler(function)
|
|
</command>
|
|
</para>
|
|
<para>
|
|
Lua-Prototyp:
|
|
<command>
|
|
weechat.remove_keyboard_handler(function)
|
|
</command>
|
|
</para>
|
|
<para>
|
|
Entfernt einen Keyboard-Handler.
|
|
</para>
|
|
<para>
|
|
Argumente:
|
|
<itemizedlist>
|
|
<listitem>
|
|
<para>
|
|
<option>function</option>: Funktion
|
|
</para>
|
|
</listitem>
|
|
</itemizedlist>
|
|
</para>
|
|
<para>
|
|
Rückgabewert: 1 bei Erfolg, 0 wenn ein Fehler aufgetreten ist.
|
|
</para>
|
|
<para>
|
|
Beispiele:
|
|
<screen>
|
|
# perl
|
|
weechat::remove_keyboard_handler("my_keyboard");
|
|
|
|
# python
|
|
weechat.remove_keyboard_handler("my_keyboard")
|
|
|
|
# ruby
|
|
Weechat.remove_keyboard_handler("my_keyboard")
|
|
|
|
-- lua
|
|
weechat.remove_keyboard_handler("my_keyboard")
|
|
</screen>
|
|
</para>
|
|
</section>
|
|
|
|
<!-- TRANSLATION NEEDED -->
|
|
<section id="secScript_add_modifier">
|
|
<title>add_modifier</title>
|
|
|
|
<para>
|
|
Perl prototype:
|
|
<command>
|
|
weechat::add_modifier(type, message, function);
|
|
</command>
|
|
</para>
|
|
<para>
|
|
Python prototype:
|
|
<command>
|
|
weechat.add_modifier(type, message, function)
|
|
</command>
|
|
</para>
|
|
<para>
|
|
Ruby prototype:
|
|
<command>
|
|
Weechat.add_modifier(type, message, function)
|
|
</command>
|
|
</para>
|
|
<para>
|
|
Lua prototype:
|
|
<command>
|
|
weechat.add_modifier(type, message, function)
|
|
</command>
|
|
</para>
|
|
<para>
|
|
Add a message modifier.
|
|
</para>
|
|
<para>
|
|
Arguments:
|
|
<itemizedlist>
|
|
<listitem>
|
|
<para>
|
|
<option>type</option>: modifier type:
|
|
<informaltable colsep="0" frame="none">
|
|
<tgroup cols="2">
|
|
<thead>
|
|
<row>
|
|
<entry>Type</entry>
|
|
<entry>Description</entry>
|
|
</row>
|
|
</thead>
|
|
<tbody>
|
|
<row>
|
|
<entry><literal>irc_in</literal></entry>
|
|
<entry>called for incoming IRC messages</entry>
|
|
</row>
|
|
<row>
|
|
<entry><literal>irc_user</literal></entry>
|
|
<entry>
|
|
called for each user message (or command) (before
|
|
WeeChat parses message)
|
|
</entry>
|
|
</row>
|
|
<row>
|
|
<entry><literal>irc_out</literal></entry>
|
|
<entry>
|
|
called for outgoing messages, immediately before
|
|
sending it to IRC server (this includes messages
|
|
sent automatically by WeeChat to server)
|
|
</entry>
|
|
</row>
|
|
</tbody>
|
|
</tgroup>
|
|
</informaltable>
|
|
</para>
|
|
</listitem>
|
|
<listitem>
|
|
<para>
|
|
<option>message</option>: name of IRC message (used only for
|
|
types "irc_in" and "irc_out").
|
|
To know list of IRC messages, please consult
|
|
<acronym>RFC</acronym>s
|
|
<ulink url="http://www.ietf.org/rfc/rfc1459.txt">1459</ulink> and
|
|
<ulink url="http://www.ietf.org/rfc/rfc2812.txt">2812</ulink>.
|
|
Moreover, special value "*" means all messages (no filter).
|
|
</para>
|
|
</listitem>
|
|
<listitem>
|
|
<para>
|
|
<option>function</option>: function called
|
|
</para>
|
|
</listitem>
|
|
</itemizedlist>
|
|
</para>
|
|
<para>
|
|
Return value: 1 if success, 0 if an error occurred.
|
|
</para>
|
|
<para>
|
|
Examples:
|
|
<screen>
|
|
# perl
|
|
weechat::add_modifier("irc_in", "privmsg", "mod_in");
|
|
weechat::add_modifier("irc_out", "privmsg", "mod_out");
|
|
sub mod_in
|
|
{
|
|
return "$_[1] [modifier IN]";
|
|
}
|
|
sub mod_out
|
|
{
|
|
return "$_[1] [modifier OUT]";
|
|
}
|
|
|
|
# python
|
|
weechat.add_modifier("irc_in", "privmsg", "mod_in")
|
|
weechat.add_modifier("irc_out", "privmsg", "mod_out")
|
|
def mod_in(serveur, args):
|
|
return args + " [modifier IN]"
|
|
def mod_out(serveur, args):
|
|
return args + " [modifier OUT]"
|
|
|
|
# ruby
|
|
Weechat.add_modifier("irc_in", "privmsg", "mod_in")
|
|
Weechat.add_modifier("irc_out", "privmsg", "mod_out")
|
|
def mod_in(server, args)
|
|
return args + " [modifier IN]"
|
|
end
|
|
def mod_out(server, args)
|
|
return args + " [modifier OUT]"
|
|
end
|
|
|
|
-- lua
|
|
weechat.add_modifier("irc_in", "privmsg", "mod_in")
|
|
weechat.add_modifier("irc_out", "privmsg", "mod_out")
|
|
function mod_in(server, args)
|
|
return args .. " [modifier IN]"
|
|
end
|
|
function mod_out(server, args)
|
|
return args .. " [modifier OUT]"
|
|
end
|
|
</screen>
|
|
</para>
|
|
</section>
|
|
|
|
<!-- TRANSLATION NEEDED -->
|
|
<section id="secScript_remove_modifier">
|
|
<title>remove_modifier</title>
|
|
|
|
<para>
|
|
Perl prototype:
|
|
<command>
|
|
weechat::remove_modifier(type, message, function);
|
|
</command>
|
|
</para>
|
|
<para>
|
|
Python prototype:
|
|
<command>
|
|
weechat.remove_modifier(type, message, function)
|
|
</command>
|
|
</para>
|
|
<para>
|
|
Ruby prototype:
|
|
<command>
|
|
Weechat.remove_modifier(type, message, function)
|
|
</command>
|
|
</para>
|
|
<para>
|
|
Lua prototype:
|
|
<command>
|
|
weechat.remove_modifier(type, message, function)
|
|
</command>
|
|
</para>
|
|
<para>
|
|
Remove a message modifier.
|
|
</para>
|
|
<para>
|
|
Arguments:
|
|
<itemizedlist>
|
|
<listitem>
|
|
<para>
|
|
<option>type</option>: modifier type
|
|
</para>
|
|
</listitem>
|
|
<listitem>
|
|
<para>
|
|
<option>message</option>: message managed by modifier
|
|
</para>
|
|
</listitem>
|
|
<listitem>
|
|
<para>
|
|
<option>function</option>: function
|
|
</para>
|
|
</listitem>
|
|
</itemizedlist>
|
|
</para>
|
|
<para>
|
|
Return value: 1 if success, 0 if an error occurred.
|
|
</para>
|
|
<para>
|
|
Examples:
|
|
<screen>
|
|
# perl
|
|
weechat::remove_modifier("irc_in", "privmsg", "mod_in");
|
|
|
|
# python
|
|
weechat.remove_modifier("irc_in", "privmsg", "mod_in")
|
|
|
|
# ruby
|
|
Weechat.remove_modifier("irc_in", "privmsg", "mod_in")
|
|
|
|
-- lua
|
|
weechat.remove_modifier("irc_in", "privmsg", "mod_in")
|
|
</screen>
|
|
</para>
|
|
</section>
|
|
|
|
<section id="secScript_command">
|
|
<title>command</title>
|
|
|
|
<para>
|
|
Perl-Prototyp:
|
|
<command>
|
|
weechat::command(command, [channel, [server]]);
|
|
</command>
|
|
</para>
|
|
<para>
|
|
Python-Prototyp:
|
|
<command>
|
|
weechat.command(command, [channel, [server]])
|
|
</command>
|
|
</para>
|
|
<para>
|
|
Ruby-Prototyp:
|
|
<command>
|
|
Weechat.command(command, [channel, [server]])
|
|
</command>
|
|
</para>
|
|
<para>
|
|
Lua-Prototyp:
|
|
<command>
|
|
weechat.command(command, [channel, [server]])
|
|
</command>
|
|
</para>
|
|
<para>
|
|
Führt ein WeeChat-Kommando aus (oder sendet eine Nachricht an einen Channel).
|
|
</para>
|
|
<para>
|
|
Argumente:
|
|
<itemizedlist>
|
|
<listitem>
|
|
<para>
|
|
<option>command</option>: Kommando
|
|
</para>
|
|
</listitem>
|
|
<listitem>
|
|
<para>
|
|
<option>channel</option>: Name des Channels, für den das Kommando
|
|
ausgeführt werden soll
|
|
</para>
|
|
</listitem>
|
|
<listitem>
|
|
<para>
|
|
<option>server</option>: interner Name des Servers, für den das
|
|
Kommando ausgeführt werden soll
|
|
</para>
|
|
</listitem>
|
|
</itemizedlist>
|
|
</para>
|
|
<para>
|
|
Rückgabewert: 1 bei Erfolg, 0 wenn ein Fehler aufgetreten ist
|
|
</para>
|
|
<para>
|
|
Beispiele:
|
|
<screen>
|
|
# perl
|
|
weechat::command("hello everybody!");
|
|
weechat::command("/kick toto please leave this channel", "#weechat");
|
|
weechat::command("/nick newnick", "", "freenode");
|
|
|
|
# python
|
|
weechat.command("hello everybody!")
|
|
weechat.command("/kick toto please leave this channel", "#weechat")
|
|
weechat.command("/nick newnick", "", "freenode")
|
|
|
|
# ruby
|
|
Weechat.command("hello everybody!")
|
|
Weechat.command("/kick toto please leave this channel", "#weechat")
|
|
Weechat.command("/nick newnick", "", "freenode")
|
|
|
|
-- lua
|
|
weechat.command("hello everybody!")
|
|
weechat.command("/kick toto please leave this channel", "#weechat")
|
|
weechat.command("/nick newnick", "", "freenode")
|
|
</screen>
|
|
</para>
|
|
</section>
|
|
|
|
<section id="secScript_get_info">
|
|
<title>get_info</title>
|
|
|
|
<para>
|
|
Perl-Prototyp:
|
|
<command>
|
|
weechat::get_info(name, [server]);
|
|
</command>
|
|
</para>
|
|
<para>
|
|
Python-Prototyp:
|
|
<command>
|
|
weechat.get_info(name, [server])
|
|
</command>
|
|
</para>
|
|
<para>
|
|
Ruby-Prototyp:
|
|
<command>
|
|
Weechat.get_info(name, [server])
|
|
</command>
|
|
</para>
|
|
<para>
|
|
Lua-Prototyp:
|
|
<command>
|
|
weechat.get_info(name, [server])
|
|
</command>
|
|
</para>
|
|
<para>
|
|
Gibt ein Info über WweeChat oder einen Channel zurück.
|
|
</para>
|
|
<para>
|
|
Argumente:
|
|
<itemizedlist>
|
|
<listitem>
|
|
<para>
|
|
<option>name</option>: Name (Typ) des Infos, das gelesen werden soll
|
|
(siehe <xref linkend="secAPI_get_info" />)
|
|
</para>
|
|
</listitem>
|
|
<listitem>
|
|
<para>
|
|
<option>server</option>: interner Name des Servers
|
|
</para>
|
|
</listitem>
|
|
</itemizedlist>
|
|
</para>
|
|
<para>
|
|
Rückgabewert: angefragte Infos, oder leerer String, wenn ein Fehler aufgetreten ist.
|
|
</para>
|
|
<para>
|
|
Beispiele:
|
|
<screen>
|
|
# perl
|
|
$version = get_info("version");
|
|
$nick = get_info("nick", "freenode");
|
|
|
|
# python
|
|
version = weechat.get_info("version")
|
|
nick = weechat.get_info("nick", "freenode")
|
|
|
|
# ruby
|
|
version = Weechat.get_info("version")
|
|
nick = Weechat.get_info("nick", "freenode")
|
|
|
|
-- lua
|
|
version = weechat.get_info("version")
|
|
nick = weechat.get_info("nick", "freenode")
|
|
</screen>
|
|
</para>
|
|
</section>
|
|
|
|
<section id="secScript_get_dcc_info">
|
|
<title>get_dcc_info</title>
|
|
|
|
<para>
|
|
Perl-Prototyp:
|
|
<command>
|
|
weechat::get_dcc_info();
|
|
</command>
|
|
</para>
|
|
<para>
|
|
Python-Prototyp:
|
|
<command>
|
|
weechat.get_dcc_info()
|
|
</command>
|
|
</para>
|
|
<para>
|
|
Ruby-Prototyp:
|
|
<command>
|
|
Weechat.get_dcc_info()
|
|
</command>
|
|
</para>
|
|
<para>
|
|
Lua-Prototyp:
|
|
<command>
|
|
weechat.get_dcc_info()
|
|
</command>
|
|
</para>
|
|
<para>
|
|
Gibt eine Liste der gegenwärtig aktiven oder beendeten DCCs zurück.
|
|
</para>
|
|
<para>
|
|
Rückgabewert: Liste der DCCS
|
|
(siehe <xref linkend="secAPI_get_dcc_info" />).
|
|
</para>
|
|
<para>
|
|
Beispiele:
|
|
<screen>
|
|
# perl
|
|
my @dccs = weechat::get_dcc_info();
|
|
if (@dccs)
|
|
{
|
|
foreach my $dcc (@dccs)
|
|
{
|
|
while (my ($key, $value) = each %$dcc)
|
|
{
|
|
weechat::print("$key = '$value'");
|
|
}
|
|
}
|
|
}
|
|
else
|
|
{
|
|
weechat::print("no DCC");
|
|
}
|
|
|
|
# python
|
|
dccs = weechat.get_dcc_info()
|
|
if dccs != None:
|
|
if dccs == []:
|
|
weechat.prnt("no DCC")
|
|
else:
|
|
for d in dccs:
|
|
for b in d.keys():
|
|
weechat.prnt("%s = '%s'" %(b, d[b]))
|
|
else:
|
|
weechat.prnt("error while getting DCC")
|
|
|
|
# ruby
|
|
dccs = Weechat.get_dcc_info()
|
|
if dccs != nil
|
|
if dccs == []
|
|
Weechat.print("no DCC")
|
|
else
|
|
dccs.each do |m|
|
|
m.each do |key, value|
|
|
Weechat.print("#{key} = '#{value}'")
|
|
end
|
|
end
|
|
end
|
|
else
|
|
Weechat.print("error while getting DCC")
|
|
end
|
|
|
|
-- lua
|
|
dccs = weechat.get_dcc_info()
|
|
if dccs ~= nil then
|
|
if dccs then
|
|
dcc, dccinfos = next (dccs, nil)
|
|
while (dcc) do
|
|
key, value = next (dccinfos, nil)
|
|
while (key) do
|
|
weechat.print(key.." = '"..value.."'")
|
|
key, value = next (dccinfos, key)
|
|
end
|
|
dcc, dccinfos = next (dccs, dcc)
|
|
end
|
|
else
|
|
weechat.print("no DCC")
|
|
end
|
|
else
|
|
weechat.print("error while getting DCC")
|
|
end
|
|
</screen>
|
|
</para>
|
|
</section>
|
|
|
|
<section id="secScript_get_server_info">
|
|
<title>get_server_info</title>
|
|
|
|
<para>
|
|
Perl-Prototyp:
|
|
<command>
|
|
weechat::get_server_info();
|
|
</command>
|
|
</para>
|
|
<para>
|
|
Python-Prototyp:
|
|
<command>
|
|
weechat.get_server_info()
|
|
</command>
|
|
</para>
|
|
<para>
|
|
Ruby-Prototyp:
|
|
<command>
|
|
Weechat.get_server_info()
|
|
</command>
|
|
</para>
|
|
<para>
|
|
Lua-Prototyp:
|
|
<command>
|
|
weechat.get_server_info()
|
|
</command>
|
|
</para>
|
|
<para>
|
|
Gibt eine Liste der IRC-Server zurück (verbunden oder nicht).
|
|
</para>
|
|
<para>
|
|
Rückgabewert: Liste der Server
|
|
(siehe <xref linkend="secAPI_get_server_info" />).
|
|
</para>
|
|
<para>
|
|
Beispiele:
|
|
<screen>
|
|
# perl
|
|
my $servers = weechat::get_server_info();
|
|
if ($servers)
|
|
{
|
|
while (my ($srvname, $srvinfos) = each %$servers)
|
|
{
|
|
while ( my ($key, $value) = each %$srvinfos)
|
|
{
|
|
weechat::print("$srvname -> $key = '$value'");
|
|
}
|
|
}
|
|
}
|
|
else
|
|
{
|
|
weechat::print("no server");
|
|
}
|
|
|
|
# python
|
|
servers = weechat.get_server_info()
|
|
if servers != None:
|
|
if servers == {}:
|
|
weechat.prnt("no server")
|
|
else:
|
|
for s in servers:
|
|
for i in servers[s]:
|
|
weechat.prnt("%s -> %s = '%s'" % (s, i, str(servers[s][i])))
|
|
else:
|
|
weechat.prnt("error while getting servers")
|
|
|
|
# ruby
|
|
servers = Weechat.get_server_info()
|
|
if servers != nil
|
|
if servers == []
|
|
Weechat.print("no server")
|
|
else
|
|
servers.each do |n, s|
|
|
s.each do |key, value|
|
|
Weechat.print("#{n} -> #{key} = '#{value}'")
|
|
end
|
|
end
|
|
end
|
|
else
|
|
Weechat.print("error while getting servers")
|
|
end
|
|
|
|
-- lua
|
|
servers = weechat.get_server_info()
|
|
if servers ~= nil then
|
|
if servers then
|
|
srv, srvinfos = next (servers, nil)
|
|
while (srv) do
|
|
key, value = next (srvinfos, nil)
|
|
while (key) do
|
|
weechat.print(srv.." -> "..key.." = '"..value.."'")
|
|
key, value = next (srvinfos, key)
|
|
end
|
|
srv, srvinfos = next (servers, srv)
|
|
end
|
|
else
|
|
weechat.print("no server")
|
|
end
|
|
else
|
|
weechat.print("error while getting servers")
|
|
end
|
|
</screen>
|
|
</para>
|
|
</section>
|
|
|
|
<section id="secScript_get_channel_info">
|
|
<title>get_channel_info</title>
|
|
|
|
<para>
|
|
Perl-Prototyp:
|
|
<command>
|
|
weechat::get_channel_info(server);
|
|
</command>
|
|
</para>
|
|
<para>
|
|
Python-Prototyp:
|
|
<command>
|
|
weechat.get_channel_info(server)
|
|
</command>
|
|
</para>
|
|
<para>
|
|
Ruby-Prototyp:
|
|
<command>
|
|
Weechat.get_channel_info(server)
|
|
</command>
|
|
</para>
|
|
<para>
|
|
Lua-Prototyp:
|
|
<command>
|
|
weechat.get_channel_info(server)
|
|
</command>
|
|
</para>
|
|
<para>
|
|
Gibt eine Liste der Channels für einen Server zurück.
|
|
</para>
|
|
<para>
|
|
Rückgabewert: Liste der Channel für einen Server
|
|
(siehe <xref linkend="secAPI_get_channel_info" />).
|
|
</para>
|
|
<para>
|
|
Beispiele:
|
|
<screen>
|
|
# perl
|
|
my $channels = weechat::get_channel_info(weechat::get_info("server"));
|
|
if ($channels)
|
|
{
|
|
while (my ($channame, $chaninfos) = each %$channels)
|
|
{
|
|
while (my ($key, $value) = each %$chaninfos)
|
|
{
|
|
weechat::print("$channame -> $key = '$value'");
|
|
}
|
|
}
|
|
}
|
|
else
|
|
{
|
|
weechat::print("no channel");
|
|
}
|
|
|
|
# python
|
|
chans = weechat.get_channel_info(weechat.get_info("server"))
|
|
if chans != None:
|
|
if chans == {}:
|
|
weechat.prnt("no channel")
|
|
else:
|
|
for s in chans:
|
|
for i in chans[s]:
|
|
weechat.prnt("%s -> %s = '%s'" % (s, i, str(chans[s][i])))
|
|
else:
|
|
weechat.prnt("error while getting channels")
|
|
|
|
# ruby
|
|
channels = Weechat.get_channel_info(Weechat.get_info("server"))
|
|
if channels != nil
|
|
if channels == {}
|
|
Weechat.print("no channel")
|
|
else
|
|
channels.each do |n, c|
|
|
c.each do |key, value|
|
|
Weechat.print("#{n} -> #{key} = '#{value}'")
|
|
end
|
|
end
|
|
end
|
|
else
|
|
Weechat.print("error while getting channels")
|
|
end
|
|
|
|
-- lua
|
|
chans = weechat.get_channel_info(weechat.get_info("server"))
|
|
if chans ~= nil then
|
|
if chans then
|
|
chan, chaninfos = next (chans, nil)
|
|
while (chan) do
|
|
key, value = next (chaninfos, nil)
|
|
while (key) do
|
|
weechat.print(chan.." -> "..key.." = '"..value.."'")
|
|
key, value = next (chaninfos, key)
|
|
end
|
|
chan, chaninfos = next (chans, chan)
|
|
end
|
|
else
|
|
weechat.print("no channel")
|
|
end
|
|
else
|
|
weechat.print("error while getting channels")
|
|
end
|
|
</screen>
|
|
</para>
|
|
</section>
|
|
|
|
<section id="secScript_get_nick_info">
|
|
<title>get_nick_info</title>
|
|
|
|
<para>
|
|
Perl-Prototyp:
|
|
<command>
|
|
weechat::get_nick_info(server, channel);
|
|
</command>
|
|
</para>
|
|
<para>
|
|
Python-Prototyp:
|
|
<command>
|
|
weechat.get_nick_info(server, channel)
|
|
</command>
|
|
</para>
|
|
<para>
|
|
Ruby-Prototyp:
|
|
<command>
|
|
Weechat.get_nick_info(server, channel)
|
|
</command>
|
|
</para>
|
|
<para>
|
|
Lua-Prototyp:
|
|
<command>
|
|
weechat.get_nick_info(server, channel)
|
|
</command>
|
|
</para>
|
|
<para>
|
|
Gibt eine Liste der Nicknamen für einen Channel zurück.
|
|
</para>
|
|
<para>
|
|
Rückgabewert: Liste der Nicknamen eines Channels
|
|
(siehe <xref linkend="secAPI_get_nick_info" />).
|
|
</para>
|
|
<para>
|
|
Beispiele:
|
|
<screen>
|
|
# perl
|
|
my $nicks = weechat::get_nick_info("freenode", "#weechat");
|
|
if ($nicks)
|
|
{
|
|
while (my ($nickname, $nickinfos) = each %$nicks)
|
|
{
|
|
while ( my ($key, $value) = each %$nickinfos)
|
|
{
|
|
weechat::print("$nickname -> $key = '$value'");
|
|
}
|
|
}
|
|
}
|
|
else
|
|
{
|
|
weechat::print("no nick");
|
|
}
|
|
|
|
# python
|
|
nicks = weechat.get_nick_info("freenode", "#weechat")
|
|
if nicks != None:
|
|
if nicks == {}:
|
|
weechat.prnt("no nick")
|
|
else:
|
|
for n in nicks:
|
|
for f in nicks[n]:
|
|
weechat.prnt("%s -> %s = '%s'" % (n, f, str(nicks[n][f])))
|
|
else:
|
|
weechat.prnt("error while getting nicks")
|
|
|
|
# ruby
|
|
nicks = Weechat.get_nick_info("freenode", "#weechat")
|
|
if nicks != nil
|
|
if nicks == {}
|
|
Weechat.print("no nick")
|
|
else
|
|
nicks.each do |nk, nattr|
|
|
nattr.each do |key, value|
|
|
Weechat.print("#{nk} -> #{key} = '#{value}'")
|
|
end
|
|
end
|
|
end
|
|
else
|
|
Weechat.print("error while getting nicks")
|
|
end
|
|
|
|
-- lua
|
|
nicks = weechat.get_nick_info("freenode", "#weechat")
|
|
if nicks ~= nil then
|
|
if nicks then
|
|
nick, nickinfos = next (nicks, nil)
|
|
while (nick) do
|
|
key, value = next (nickinfos, nil)
|
|
while (key) do
|
|
weechat.print(nick.." -> "..key.." = '"..value.."'")
|
|
key, value = next (nickinfos, key)
|
|
end
|
|
nick, nickinfos = next (nicks, nick)
|
|
end
|
|
else
|
|
weechat.print("no nick")
|
|
end
|
|
else
|
|
weechat.print("error while getting nicks")
|
|
end
|
|
</screen>
|
|
</para>
|
|
</section>
|
|
|
|
<section id="secScript_get_config">
|
|
<title>get_config</title>
|
|
|
|
<para>
|
|
Perl-Prototyp:
|
|
<command>
|
|
weechat::get_config(option);
|
|
</command>
|
|
</para>
|
|
<para>
|
|
Python-Prototyp:
|
|
<command>
|
|
weechat.get_config(option)
|
|
</command>
|
|
</para>
|
|
<para>
|
|
Ruby-Prototyp:
|
|
<command>
|
|
Weechat.get_config(option)
|
|
</command>
|
|
</para>
|
|
<para>
|
|
Lua-Prototyp:
|
|
<command>
|
|
weechat.get_config(option)
|
|
</command>
|
|
</para>
|
|
<para>
|
|
Gibt den Wert einer Option der WeeChat-Konfiguration zurück.
|
|
</para>
|
|
<para>
|
|
Argumente:
|
|
<itemizedlist>
|
|
<listitem>
|
|
<para>
|
|
<option>option</option>: Name der Option
|
|
</para>
|
|
</listitem>
|
|
</itemizedlist>
|
|
</para>
|
|
<para>
|
|
Rückgabewert: Wert der Option, leerer String wenn nichts gefunden wurde.
|
|
</para>
|
|
<para>
|
|
Beispiele:
|
|
<screen>
|
|
# perl
|
|
$value1 = weechat::get_config("look_nicklist");
|
|
$value2 = weechat::get_config("freenode.server_autojoin");
|
|
|
|
# python
|
|
value1 = weechat.get_config("look_nicklist")
|
|
value2 = weechat.get_config("freenode.server_autojoin")
|
|
|
|
# ruby
|
|
value1 = Weechat.get_config("look_nicklist")
|
|
value2 = Weechat.get_config("freenode.server_autojoin")
|
|
|
|
-- lua
|
|
value1 = weechat.get_config("look_nicklist")
|
|
value2 = weechat.get_config("freenode.server_autojoin")
|
|
</screen>
|
|
</para>
|
|
</section>
|
|
|
|
<section id="secScript_set_config">
|
|
<title>set_config</title>
|
|
|
|
<para>
|
|
Perl-Prototyp:
|
|
<command>
|
|
weechat::set_config(option, value);
|
|
</command>
|
|
</para>
|
|
<para>
|
|
Python-Prototyp:
|
|
<command>
|
|
weechat.set_config(option, value)
|
|
</command>
|
|
</para>
|
|
<para>
|
|
Ruby-Prototyp:
|
|
<command>
|
|
Weechat.set_config(option, value)
|
|
</command>
|
|
</para>
|
|
<para>
|
|
Lua-Prototyp:
|
|
<command>
|
|
weechat.set_config(option, value)
|
|
</command>
|
|
</para>
|
|
<para>
|
|
Setze den Wert einer Option der WeeChat-Konfiguration.
|
|
</para>
|
|
<para>
|
|
Argumente:
|
|
<itemizedlist>
|
|
<listitem>
|
|
<para>
|
|
<option>option</option>: Name der Option, die gesetzt werden soll
|
|
</para>
|
|
</listitem>
|
|
<listitem>
|
|
<para>
|
|
<option>value</option>: neuer Wert der Option
|
|
</para>
|
|
</listitem>
|
|
</itemizedlist>
|
|
</para>
|
|
<para>
|
|
Rückgabewert: 1 wenn der Wert gesetzt wurde, 0 wenn ein Fehler aufgetreten ist.
|
|
</para>
|
|
<para>
|
|
Beispiele:
|
|
<screen>
|
|
# perl
|
|
weechat::set_config("look_nicklist", "off");
|
|
weechat::set_config("freenode.server_autojoin, "#weechat");
|
|
|
|
# python
|
|
weechat.set_config("look_nicklist", "off")
|
|
weechat.set_config("freenode.server_autojoin, "#weechat")
|
|
|
|
# ruby
|
|
Weechat.set_config("look_nicklist", "off")
|
|
Weechat.set_config("freenode.server_autojoin, "#weechat")
|
|
|
|
-- lua
|
|
weechat.set_config("look_nicklist", "off")
|
|
weechat.set_config("freenode.server_autojoin, "#weechat")
|
|
</screen>
|
|
</para>
|
|
</section>
|
|
|
|
<section id="secScript_get_plugin_config">
|
|
<title>get_plugin_config</title>
|
|
|
|
<para>
|
|
Perl-Prototyp:
|
|
<command>
|
|
weechat::get_plugin_config(option);
|
|
</command>
|
|
</para>
|
|
<para>
|
|
Python-Prototyp:
|
|
<command>
|
|
weechat.get_plugin_config(option)
|
|
</command>
|
|
</para>
|
|
<para>
|
|
Ruby-Prototyp:
|
|
<command>
|
|
Weechat.get_plugin_config(option)
|
|
</command>
|
|
</para>
|
|
<para>
|
|
Lua-Prototyp:
|
|
<command>
|
|
weechat.get_plugin_config(option)
|
|
</command>
|
|
</para>
|
|
<para>
|
|
Gibt den Wert einer Option eines Plugins zurück. Die Option wird aus
|
|
der Datei "<literal>~/.weechat/plugins.rc</literal>" gelesen und
|
|
sieht so aus: "<literal>plugin.option=value</literal>"
|
|
(Hinweis: Der Name des Plugins wird automatisch gesetzt).
|
|
</para>
|
|
<para>
|
|
Argumente:
|
|
<itemizedlist>
|
|
<listitem>
|
|
<para>
|
|
<option>option</option>: Name der zu lesenden Option
|
|
</para>
|
|
</listitem>
|
|
</itemizedlist>
|
|
</para>
|
|
<para>
|
|
Rückgabewert: Wert der Option, leerer String wenn die Option nicht
|
|
gefunden wurde.
|
|
</para>
|
|
<para>
|
|
Beispiele:
|
|
<screen>
|
|
# perl
|
|
$value = weechat::get_plugin_config("my_var");
|
|
|
|
# python
|
|
value = weechat.get_plugin_config("my_var")
|
|
|
|
# ruby
|
|
value = Weechat.get_plugin_config("my_var")
|
|
|
|
-- lua
|
|
value = weechat.get_plugin_config("my_var")
|
|
</screen>
|
|
</para>
|
|
</section>
|
|
|
|
<section id="secScript_set_plugin_config">
|
|
<title>set_plugin_config</title>
|
|
|
|
<para>
|
|
Perl-Prototyp:
|
|
<command>
|
|
weechat::set_plugin_config(option, value);
|
|
</command>
|
|
</para>
|
|
<para>
|
|
Python-Prototyp:
|
|
<command>
|
|
weechat.set_plugin_config(option, value)
|
|
</command>
|
|
</para>
|
|
<para>
|
|
Ruby-Prototyp:
|
|
<command>
|
|
Weechat.set_plugin_config(option, value)
|
|
</command>
|
|
</para>
|
|
<para>
|
|
Lua-Prototyp:
|
|
<command>
|
|
weechat.set_plugin_config(option, value)
|
|
</command>
|
|
</para>
|
|
<para>
|
|
Setzt den Wert einer Option eines Plugins. Die Option bzw. ihr Wert
|
|
wird in "<literal>~/.weechat/plugins.rc</literal>" geschrieben und
|
|
sieht so aus: "<literal>plugin.option=value</literal>"
|
|
(Hinweis: der Name des Plugins wird automatisch gesetzt).
|
|
</para>
|
|
<para>
|
|
Argumente:
|
|
<itemizedlist>
|
|
<listitem>
|
|
<para>
|
|
<option>option</option>: Name der Option, die gesetzt werden soll
|
|
</para>
|
|
</listitem>
|
|
<listitem>
|
|
<para>
|
|
<option>value</option>: Der neue Wert der Option
|
|
</para>
|
|
</listitem>
|
|
</itemizedlist>
|
|
</para>
|
|
<para>
|
|
Rückgabewert: 1 wenn die Option gesetzt wurde, 0 wenn ein Fehler aufgetreten ist.
|
|
</para>
|
|
<para>
|
|
Beispiele:
|
|
<screen>
|
|
# perl
|
|
weechat::set_plugin_config("my_var", "value");
|
|
|
|
# python
|
|
weechat.set_plugin_config("my_var", "value")
|
|
|
|
# ruby
|
|
Weechat.set_plugin_config("my_var", "value")
|
|
|
|
-- lua
|
|
weechat.set_plugin_config("my_var", "value")
|
|
</screen>
|
|
</para>
|
|
</section>
|
|
|
|
<section id="secScript_get_irc_color">
|
|
<title>get_irc_color</title>
|
|
|
|
<para>
|
|
Perl-Prototyp:
|
|
<command>
|
|
weechat::get_irc_color(color);
|
|
</command>
|
|
</para>
|
|
<para>
|
|
Python-Prototyp:
|
|
<command>
|
|
weechat.get_irc_color(color)
|
|
</command>
|
|
</para>
|
|
<para>
|
|
Ruby-Prototyp:
|
|
<command>
|
|
Weechat.get_irc_color(color)
|
|
</command>
|
|
</para>
|
|
<para>
|
|
Lua-Prototyp:
|
|
<command>
|
|
weechat.get_irc_color(color)
|
|
</command>
|
|
</para>
|
|
<para>
|
|
Hole IRC-Farbindex mit dem Farbnamen.
|
|
</para>
|
|
<para>
|
|
Rückgabewert: IRC-Farbindex, -1 wenn die Farbe nicht gefunden wurde
|
|
(siehe <xref linkend="secAPI_get_irc_color" />).
|
|
</para>
|
|
<para>
|
|
Beispiele:
|
|
<screen>
|
|
# perl
|
|
my $color_blue = weechat::get_irc_color("blue");
|
|
|
|
# python
|
|
color_blue = weechat.get_irc_color("blue")
|
|
|
|
# ruby
|
|
color_blue = Weechat.get_irc_color("blue")
|
|
|
|
-- lua
|
|
color_blue = weechat.get_irc_color("blue")
|
|
</screen>
|
|
</para>
|
|
</section>
|
|
|
|
<section id="secScript_input_color">
|
|
<title>input_color</title>
|
|
|
|
<para>
|
|
Perl-Prototyp:
|
|
<command>
|
|
weechat::input_color(color);
|
|
</command>
|
|
</para>
|
|
<para>
|
|
Python-Prototyp:
|
|
<command>
|
|
weechat.input_color(color)
|
|
</command>
|
|
</para>
|
|
<para>
|
|
Ruby-Prototyp:
|
|
<command>
|
|
Weechat.input_color(color)
|
|
</command>
|
|
</para>
|
|
<para>
|
|
Lua-Prototyp:
|
|
<command>
|
|
weechat.input_color(color)
|
|
</command>
|
|
</para>
|
|
<para>
|
|
Erzeugt einen Farbcode im Eingabepuffer.Add color in input buffer.
|
|
</para>
|
|
<para>
|
|
Rückgabewert: keiner.
|
|
</para>
|
|
<para>
|
|
Bespiele:
|
|
<screen>
|
|
# perl
|
|
weechat::input_color(weechat::get_irc_color("blue"), 10, 5);
|
|
|
|
# python
|
|
weechat.input_color(weechat.get_irc_color("blue"), 10, 5)
|
|
|
|
# ruby
|
|
Weechat.input_color(Weechat.get_irc_color("blue"), 10, 5)
|
|
|
|
-- lua
|
|
weechat.input_color(weechat.get_irc_color("blue"), 10, 5)
|
|
</screen>
|
|
</para>
|
|
</section>
|
|
|
|
<section id="secScript_get_window_info">
|
|
<title>get_window_info</title>
|
|
|
|
<para>
|
|
Perl-Prototyp:
|
|
<command>
|
|
weechat::get_window_info();
|
|
</command>
|
|
</para>
|
|
<para>
|
|
Python-Prototyp:
|
|
<command>
|
|
weechat.get_window_info()
|
|
</command>
|
|
</para>
|
|
<para>
|
|
Ruby-Prototyp:
|
|
<command>
|
|
Weechat.get_window_info()
|
|
</command>
|
|
</para>
|
|
<para>
|
|
Lua-Prototyp:
|
|
<command>
|
|
weechat.get_window_info()
|
|
</command>
|
|
</para>
|
|
<para>
|
|
Gibt die Liste der WeeChat-Fenster zurück.
|
|
</para>
|
|
<para>
|
|
Rückgabewert: List der WeeChat-Fenster
|
|
(see <xref linkend="secAPI_get_window_info" />).
|
|
</para>
|
|
<para>
|
|
Besipiele:
|
|
<screen>
|
|
# perl
|
|
my @wf = weechat::get_window_info();
|
|
if (@wf)
|
|
{
|
|
weechat::print("**** Fenster-Informationen ****");
|
|
foreach my $w (@wf)
|
|
{
|
|
while ( my ($key, $value) = each %$w)
|
|
{
|
|
weechat::print(" > $key => $value");
|
|
}
|
|
weechat::print("----------------------");
|
|
}
|
|
}
|
|
else
|
|
{
|
|
weechat::print("**** Keine Fenster-Informationen ****");
|
|
}
|
|
|
|
# python
|
|
wf = weechat.get_window_info()
|
|
if wf != None and wf != []:
|
|
weechat.prnt ("**** Fenster-Informationen ****")
|
|
for w in wf:
|
|
for i in w:
|
|
weechat.prnt (" > %s => %s" % (i, w[i]))
|
|
weechat.prnt ("----------------------")
|
|
else:
|
|
weechat.prnt ("**** Keine Fenster-Informationen ****")
|
|
|
|
# ruby
|
|
wf = Weechat.get_window_info()
|
|
if wf != nil and wf != []
|
|
Weechat.print("**** Fenster-Informationen ****")
|
|
wf.each do |w|
|
|
w.each do |key, value|
|
|
Weechat.print(" > #{key} => #{value}")
|
|
end
|
|
Weechat.print("----------------------")
|
|
end
|
|
else
|
|
Weechat.print("**** Keine Fenster-Informationen ****")
|
|
end
|
|
|
|
-- lua
|
|
wf = weechat.get_window_info()
|
|
if wf then
|
|
weechat.print ("**** Fenster-Informationen ****")
|
|
w, winfos = next (wf, nil)
|
|
while (w) do
|
|
key, value = next (winfos, nil)
|
|
while (key) do
|
|
weechat.print(" > " .. key .. " => " .. value)
|
|
key, value = next (winfos, key)
|
|
end
|
|
weechat.print ("----------------------")
|
|
w, winfos = next (wf, w)
|
|
end
|
|
else
|
|
weechat.print("**** Keine Fenster-Informationen ****")
|
|
end
|
|
</screen>
|
|
</para>
|
|
</section>
|
|
|
|
<section id="secScript_get_buffer_info">
|
|
<title>get_buffer_info</title>
|
|
|
|
<para>
|
|
Perl-Prototyp:
|
|
<command>
|
|
weechat::get_buffer_info();
|
|
</command>
|
|
</para>
|
|
<para>
|
|
Python-Prototyp:
|
|
<command>
|
|
weechat.get_buffer_info()
|
|
</command>
|
|
</para>
|
|
<para>
|
|
Ruby-Prototyp:
|
|
<command>
|
|
Weechat.get_buffer_info()
|
|
</command>
|
|
</para>
|
|
<para>
|
|
Lua-Prototyp:
|
|
<command>
|
|
weechat.get_buffer_info()
|
|
</command>
|
|
</para>
|
|
<para>
|
|
Gibt eine Liste der WeeChat-Puffer.
|
|
</para>
|
|
<para>
|
|
Rückgabewert: Liste der WeeChat-Puffer
|
|
(siehe <xref linkend="secAPI_get_buffer_info" />).
|
|
</para>
|
|
<para>
|
|
Beispiele:
|
|
<screen>
|
|
# perl
|
|
my $bf = weechat::get_buffer_info();
|
|
if ($bf)
|
|
{
|
|
while ( my ($nobuf, $binfos) = each %$bf)
|
|
{
|
|
while ( my ($key, $value) = each %$binfos)
|
|
{
|
|
weechat::print(" > $key => $value");
|
|
}
|
|
weechat::print("----------------------");
|
|
}
|
|
}
|
|
else
|
|
{
|
|
weechat::print("**** keine Pufferinformationen ****");
|
|
}
|
|
|
|
# python
|
|
bf = weechat.get_buffer_info()
|
|
if bf != None and bf != {}:
|
|
for b in bf:
|
|
weechat.prnt ("**** Informationen für Puffer Nr. %d ****" % b)
|
|
for c in bf[b]:
|
|
weechat.prnt (" > %s => %s" % (c, bf[b][c]))
|
|
weechat.prnt ("----------------------")
|
|
else:
|
|
weechat.prnt ("**** keine Pufferinformationen ****")
|
|
|
|
# ruby
|
|
bf = Weechat.get_buffer_info()
|
|
if bf != nil and bf != {}
|
|
bf.each do |n, c|
|
|
Weechat.print("**** Informationen für Puffer Nr. #{n} ****")
|
|
c.each do |key, value|
|
|
Weechat.print(" > #{key} => #{value}")
|
|
end
|
|
Weechat.print("----------------------")
|
|
end
|
|
else
|
|
Weechat.print("**** keine Pufferinformationen ****")
|
|
end
|
|
|
|
-- lua
|
|
bf = weechat.get_buffer_info()
|
|
if bf then
|
|
b, binfos = next (bf, nil)
|
|
while (b) do
|
|
weechat.print("**** Informationen für Puffer Nr. " .. b .. " ****")
|
|
key, value = next (binfos, nil)
|
|
while (key) do
|
|
weechat.print(" > " .. key .. " => " .. value)
|
|
key, value = next (binfos, key)
|
|
end
|
|
weechat.print ("----------------------")
|
|
b, infos = next (bf, b)
|
|
end
|
|
else
|
|
weechat.print("**** keine Pufferinformationen ****")
|
|
end
|
|
</screen>
|
|
</para>
|
|
</section>
|
|
|
|
<section id="secScript_get_buffer_data">
|
|
<title>get_buffer_data</title>
|
|
|
|
<para>
|
|
Perl-Prototyp:
|
|
<command>
|
|
weechat::get_buffer_data(server, channel);
|
|
</command>
|
|
</para>
|
|
<para>
|
|
Python-Prototyp:
|
|
<command>
|
|
weechat.get_buffer_data(server, channel)
|
|
</command>
|
|
</para>
|
|
<para>
|
|
Ruby-Prototyp:
|
|
<command>
|
|
Weechat.get_buffer_data(server, channel)
|
|
</command>
|
|
</para>
|
|
<para>
|
|
Lua-Prototyp:
|
|
<command>
|
|
weechat.get_buffer_data(server, channel)
|
|
</command>
|
|
</para>
|
|
<para>
|
|
Gibt den Inhalt eines Puffers zurück.
|
|
</para>
|
|
<para>
|
|
Rückgabewert: Liste der Pufferzeilen
|
|
(see <xref linkend="secAPI_get_buffer_data" />).
|
|
</para>
|
|
<para>
|
|
Beispiele:
|
|
<screen>
|
|
# perl
|
|
my $server = weechat::get_info("server");
|
|
my $channel = weechat::get_info("channel");
|
|
my @bc = weechat::get_buffer_data($server, $channel);
|
|
if (@bc)
|
|
{
|
|
weechat::print("**** Pufferdaten für '$channel'\@'$server' ****");
|
|
foreach my $l (@bc) {
|
|
while ( my ($key, $value) = each %$l) {
|
|
weechat::print(" > $key => $value");
|
|
}
|
|
weechat::print("----------------------");
|
|
}
|
|
}
|
|
else
|
|
{
|
|
weechat::print("**** keine Pufferdaten ****");
|
|
}
|
|
|
|
# python
|
|
server = weechat.get_info("server")
|
|
channel = weechat.get_info("channel")
|
|
bc = weechat.get_buffer_data(server, channel)
|
|
if bc != None and bc != []:
|
|
weechat.prnt ("**** Pufferdaten für '%s'@'%s' ****" % (channel, server))
|
|
for l in bc:
|
|
for i in l:
|
|
weechat.prnt (" > %s => %s" % (i, l[i]))
|
|
weechat.prnt ("----------------------")
|
|
else:
|
|
weechat.prnt ("**** keine Pufferdaten ****")
|
|
|
|
# ruby
|
|
server = Weechat.get_info("server")
|
|
channel = Weechat.get_info("channel")
|
|
bc = Weechat.get_buffer_data(server, channel)
|
|
if bc != nil and bc != []
|
|
Weechat.print("**** Pufferdaten für '#{channel}'@'#{server}' ****")
|
|
bc.each do |l|
|
|
l.each do |key, value|
|
|
Weechat.print(" > #{key} => #{value}")
|
|
end
|
|
Weechat.print("----------------------")
|
|
end
|
|
else
|
|
Weechat.print("**** keine Pufferdaten ****")
|
|
end
|
|
|
|
-- lua
|
|
server = weechat.get_info("server")
|
|
channel = weechat.get_info("channel")
|
|
bc = weechat.get_buffer_data(server, channel)
|
|
if bc then
|
|
b, bdatas = next (bc, nil)
|
|
weechat.print("**** Pufferdaten für '" .. channel .. "'@'" .. server .. "' ****")
|
|
while (b) do
|
|
key, value = next (bdatas, nil)
|
|
while (key) do
|
|
weechat.print(" > " .. key .. " => " .. value)
|
|
key, value = next (bdatas, key)
|
|
end
|
|
weechat.print ("----------------------")
|
|
b, bdatas = next (bc, b)
|
|
end
|
|
else
|
|
weechat.print("**** keine Pufferdaten ****")
|
|
end
|
|
</screen>
|
|
</para>
|
|
</section>
|
|
|
|
</section>
|
|
|
|
</section>
|
|
|
|
</chapter>
|
|
|
|
<!-- ======================== Auteurs / Support ========================= -->
|
|
|
|
<chapter id="chapAuthorsSupport">
|
|
<title>Autoren / Support</title>
|
|
|
|
<para>
|
|
Dieses Kapitel listet Autoren und Beitragende für WeeChat auf, und
|
|
zeigt die Möglichkeiten um Support zu bekommen.
|
|
</para>
|
|
|
|
<section id="secAuthors">
|
|
<title>Autoren</title>
|
|
|
|
<para>
|
|
WeeChat wird entwickelt von:
|
|
<itemizedlist>
|
|
<listitem>
|
|
<para>
|
|
<emphasis>FlashCode (Sébastien Helleu)</emphasis>
|
|
<email>flashcode AT flashtux.org</email> -
|
|
Hauptentwickler
|
|
</para>
|
|
</listitem>
|
|
<listitem>
|
|
<para>
|
|
<emphasis>kolter (Emmanuel Bouthenot)</emphasis>
|
|
<email>kolter AT openics.org</email> -
|
|
Entwickler
|
|
</para>
|
|
</listitem>
|
|
<listitem>
|
|
<para>
|
|
<emphasis>Ptitlouis</emphasis>
|
|
<email>ptitlouis AT sysif.net</email> -
|
|
erzeugt Debian-Pakete
|
|
</para>
|
|
</listitem>
|
|
</itemizedlist>
|
|
</para>
|
|
|
|
</section>
|
|
|
|
<section id="secContributors">
|
|
<title>Beitragende</title>
|
|
|
|
<para>
|
|
Die folgenden Personen trugen zur Entwicklung von WeeChat bei:
|
|
<itemizedlist>
|
|
<listitem>
|
|
<para>
|
|
<emphasis>Jiri Golembiovsky</emphasis> -
|
|
Tschechische Übersetzung, Patches
|
|
</para>
|
|
</listitem>
|
|
<listitem>
|
|
<para>
|
|
<emphasis>Rudolf Polzer</emphasis> -
|
|
Patches
|
|
</para>
|
|
</listitem>
|
|
<listitem>
|
|
<para>
|
|
<emphasis>Jim Ramsay</emphasis> -
|
|
Patches
|
|
</para>
|
|
</listitem>
|
|
<listitem>
|
|
<para>
|
|
<emphasis>Odin</emphasis> -
|
|
SuSE RPM
|
|
</para>
|
|
</listitem>
|
|
<listitem>
|
|
<para>
|
|
<emphasis>Pistos</emphasis> -
|
|
Patches
|
|
</para>
|
|
</listitem>
|
|
<listitem>
|
|
<para>
|
|
<emphasis>Gwenn</emphasis> -
|
|
Patches
|
|
</para>
|
|
</listitem>
|
|
<listitem>
|
|
<para>
|
|
<emphasis>voroskoi</emphasis> -
|
|
Ungarische Übersetzung
|
|
</para>
|
|
</listitem>
|
|
<listitem>
|
|
<para>
|
|
<emphasis>Frank Zacharias</emphasis> -
|
|
Deutsche Übersetzung
|
|
</para>
|
|
</listitem>
|
|
<listitem>
|
|
<para>
|
|
<emphasis>Pavel Shevchuk</emphasis> -
|
|
Russisch Übersetzung
|
|
</para>
|
|
</listitem>
|
|
</itemizedlist>
|
|
</para>
|
|
|
|
</section>
|
|
|
|
<section id="secSupport">
|
|
<title>Support bekommen</title>
|
|
|
|
<para>
|
|
Bevor Sie nach Support fragen, sollten Sie die Dokumentation und die FAQ
|
|
gelesen haben, die bei WeeChat angeboten wird. (Die Dokumentation
|
|
ist dieses Dokument, wenn Sie sie nicht bis zu dieser Zeile gelesen
|
|
haben, sollten Sie sie noch Mal lesen!)
|
|
</para>
|
|
|
|
<para>
|
|
<itemizedlist>
|
|
<listitem>
|
|
<para>
|
|
IRC: Server "<literal>irc.freenode.net</literal>",
|
|
Channel "<literal>#weechat</literal>"
|
|
</para>
|
|
</listitem>
|
|
<listitem>
|
|
<para>
|
|
WeeChat Forum:
|
|
<ulink url="http://forums.flashtux.org">
|
|
http://forums.flashtux.org
|
|
</ulink>
|
|
</para>
|
|
</listitem>
|
|
<listitem>
|
|
<para>
|
|
Mailingliste:
|
|
<itemizedlist>
|
|
<listitem>
|
|
<para>
|
|
Zum abonnieren:
|
|
<ulink url="http://mail.nongnu.org/mailman/listinfo/weechat-support">
|
|
http://mail.nongnu.org/mailman/listinfo/weechat-support
|
|
</ulink>
|
|
</para>
|
|
</listitem>
|
|
<listitem>
|
|
<para>
|
|
Um eine Mail an die Liste zu senden:
|
|
<email>weechat-support@nongnu.org</email>
|
|
</para>
|
|
</listitem>
|
|
</itemizedlist>
|
|
Das Archiv der Mailingliste ist hier:
|
|
<ulink url="http://mail.nongnu.org/archive/html/weechat-support">
|
|
http://mail.nongnu.org/archive/html/weechat-support
|
|
</ulink>
|
|
</para>
|
|
</listitem>
|
|
</itemizedlist>
|
|
</para>
|
|
|
|
</section>
|
|
|
|
</chapter>
|
|
|
|
</book>
|