| 1 |
/* |
| 2 |
* Copyright (C) 2007 Colin DIDIER |
| 3 |
* |
| 4 |
* This program is free software; you can redistribute it and/or modify |
| 5 |
* it under the terms of the GNU General Public License version 2 as |
| 6 |
* published by the Free Software Foundation. |
| 7 |
* |
| 8 |
* This program is distributed in the hope that it will be useful, |
| 9 |
* but WITHOUT ANY WARRANTY; without even the implied warranty of |
| 10 |
* MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the |
| 11 |
* GNU General Public License for more details. |
| 12 |
* |
| 13 |
* You should have received a copy of the GNU General Public License along |
| 14 |
* with this program; if not, write to the Free Software Foundation, Inc., |
| 15 |
* 51 Franklin Street, Fifth Floor, Boston, MA 02110-1301 USA. |
| 16 |
*/ |
| 17 |
|
| 18 |
#include "module.h" |
| 19 |
#include "formats.h" |
| 20 |
|
| 21 |
FORMAT_REC fecommon_xmpp_formats[] = { |
| 22 |
{ MODULE_NAME, "XMPP", 0, { 0 } }, |
| 23 |
|
| 24 |
/* ---- */ |
| 25 |
{ NULL, "Format", 0, { 0 } }, |
| 26 |
|
| 27 |
{ "format_name", "{nick $0} {nickhost $1}", 2, { 0, 0 } }, |
| 28 |
{ "format_jid", "{nick $0}", 1, { 0 } }, |
| 29 |
{ "format_resource", "{comment $0{hilight $1}($2)$3}", 4, { 0, 0, 0, 0 } }, |
| 30 |
{ "format_resource_show", "($0)", 1, { 0 } }, |
| 31 |
{ "format_resource_status", ": $0", 1, { 0 } }, |
| 32 |
{ "format_subscription", "(subscription: $0)", 1, { 0 } }, |
| 33 |
|
| 34 |
/* ---- */ |
| 35 |
{ NULL, "Presence", 0, { 0 } }, |
| 36 |
|
| 37 |
{ "presence_unavailable", "%K(◦) $[14]0 ->%n", 1, { 0 } }, |
| 38 |
{ "presence_error", "%r(!) $[14]0 ->%n", 1, { 0 } }, |
| 39 |
{ "presence_xa", "%r(x) $[14]0 ->%n", 1, { 0 } }, |
| 40 |
{ "presence_dnd", "%r(x) $[14]0 ->%n", 1, { 0 } }, |
| 41 |
{ "presence_away", "%y(-) $[14]0 ->%n", 1, { 0 } }, |
| 42 |
{ "presence_available", "%_%g(+) $[14]0%_ ->%n", 1, { 0 } }, |
| 43 |
{ "presence_chat", "%_%g(+) $[14]0%_ ->%n", 1, { 0 } }, |
| 44 |
{ "presence_online", "%_%g(+) $[14]0%_ ->%n", 1, { 0 } }, |
| 45 |
|
| 46 |
/* ---- */ |
| 47 |
{ NULL, "Roster", 0, { 0 } }, |
| 48 |
|
| 49 |
{ "roster_group", " {hilight $0}:", 1, { 0 } }, |
| 50 |
{ "roster_contact", " ({hilight $0}) $1 $2 $3", 4, { 0, 0, 0, 0 } }, |
| 51 |
{ "begin_of_roster", "ROSTER: {nick $0} $1 $2", 3, { 0, 0, 0 } }, |
| 52 |
{ "end_of_roster", "End of ROSTER", 0, { 0 } }, |
| 53 |
{ "not_in_roster", "{nick $0}: not in the roster", 1, { 0 } }, |
| 54 |
|
| 55 |
/* ---- */ |
| 56 |
{ NULL, "Subscription", 0, { 0 } }, |
| 57 |
|
| 58 |
{ "subscribe", "$0: wants to subscribe to your presence {comment $1} (accept or deny?)", 2, { 0, 0 } }, |
| 59 |
{ "subscribed", "$0: wants you to see their presence", 1, { 0 } }, |
| 60 |
{ "unsubscribe", "$0: doesn't want to see your presence anymore", 1 , { 0 } }, |
| 61 |
{ "unsubscribed", "$0: doesn't want you to see their presence anymore", 1 , { 0 } }, |
| 62 |
|
| 63 |
/* ---- */ |
| 64 |
{ NULL, "Message", 0, { 0 } }, |
| 65 |
|
| 66 |
{ "message_room", "$0", 1, { 0 } }, |
| 67 |
{ "message_event", "$0: $1", 2, { 0, 0 } }, |
| 68 |
{ "message_not_delivered", "$0: cannot deliver message {comment $1}", 2, { 0, 0 } }, |
| 69 |
{ "message_timestamp", "[{timestamp $0}] $1", 2, { 0, 0 } }, |
| 70 |
|
| 71 |
/* ---- */ |
| 72 |
{ NULL, "Queries", 0, { 0 } }, |
| 73 |
|
| 74 |
{ "query_aka", "{nick $0}: Also known as {nick $1}", 2, { 0, 0 } }, |
| 75 |
|
| 76 |
/* ---- */ |
| 77 |
{ NULL, "Channel", 0, { 0 } }, |
| 78 |
|
| 79 |
{ "joinerror", "Cannot join to room {channel $0} {comment $1}", 2, { 0, 0 } }, |
| 80 |
{ "destroyerror", "Cannot destroy room {channel $0} {comment $1}", 2, { 0, 0 } }, |
| 81 |
|
| 82 |
/* ---- */ |
| 83 |
{ NULL, "Presence", 0, { 0 } }, |
| 84 |
|
| 85 |
{ "presence_change", "$0: is now {hilight $1}", 2, { 0, 0 } }, |
| 86 |
{ "presence_change_reason", "$0: is now {hilight $1} {comment $2}", 3, { 0, 0, 0 } }, |
| 87 |
|
| 88 |
/* ---- */ |
| 89 |
{ NULL, "VCard", 0, { 0 } }, |
| 90 |
|
| 91 |
{ "vcard", "{nick $0} {nickhost $1}", 2, { 0, 0 } }, |
| 92 |
{ "vcard_value", " $0: $1", 2, { 0, 0 } }, |
| 93 |
{ "vcard_subvalue", " $0: $1", 2, { 0, 0 } }, |
| 94 |
{ "end_of_vcard", "End of VCARD", 0, { 0 } }, |
| 95 |
|
| 96 |
/* ---- */ |
| 97 |
{ NULL, "Misc", 0, { 0 } }, |
| 98 |
|
| 99 |
{ "raw_in_header", "RECV[$0]:", 1, { 0 } }, |
| 100 |
{ "raw_out_header", "SEND[$0]:", 1, { 0 } }, |
| 101 |
{ "raw_message", "$0", 1, { 0 } }, |
| 102 |
{ "default_event", "$1 $2", 3, { 0, 0, 0 } }, |
| 103 |
{ "default_error", "ERROR $1 $2", 3, { 0, 0, 0 } }, |
| 104 |
|
| 105 |
{ NULL, "Registration", 0, { 0 } }, |
| 106 |
|
| 107 |
{ "xmpp_registration_started", "Registering {nick $0@$1}...", 2, { 0, 0 } }, |
| 108 |
{ "xmpp_registration_succeed", "Registration of {nick $0@$1} succeeded", 2, { 0, 0 } }, |
| 109 |
{ "xmpp_registration_failed", "Registration of {nick $0@$1} failed {comment $2}", 3, { 0, 0, 0 } }, |
| 110 |
|
| 111 |
{ NULL, NULL, 0, { 0 } } |
| 112 |
}; |