Files
kmess/data/chatstyles/examplemessage.xml
2009-05-13 18:20:42 +00:00

296 lines
8.7 KiB
XML

<?xml version='1.0'?>
<!--
This is an example chat conversation.
It contains the common message types and variations.
To view the HTML result of a chat style, use:
xsltproc Themedir/theme.xsl examplemessage.xml > Themedir/test.html
To view all chat styles, use:
for i in */*.xsl; do name=`dirname $i`; xsltproc $i examplemessage.xml > $name/test.html; done
konqueror */test.html &
To cleanup everything, use:
rm */test.html
-->
<messageRoot>
<!--
Incoming message from another contact
When the "Show time in messages" option in unchecked,
the 'time' attribute won't be added to messages.
-->
<message type='incoming'><!-- time may be omitted -->
<from>
<contact contactId='alice@kmess.org'>
<displayPicture url='' />
<displayName text='Alice' dir='ltr' />
</contact>
</from>
<body color='#0033cc'
fontFamily='Sans Serif'
fontBold='0'
fontItalic='0'
fontUnderline='0'
fontBefore='&lt;font face="Sans Serif" color="#0033cc"&gt;'
fontAfter='&lt;/font&gt;'
dir='ltr'
>Aren't you going to open your gift? &lt;img src="/opt/kde3/share/apps/kmess/emoticons/regular.png" height="29" width="29" alt=":)" title="" valign="top" class="standardEmoticon"&gt;&lt;br&gt;&lt;br&gt;This is an example chat message.&lt;br&gt;Use &lt;code&gt;xsltproc &lt;var&gt;theme&lt;/var&gt;.xsl examplemessage.xml &amp;gt; test.html&lt;/code&gt; to see the HTML result.</body>
</message>
<!--
More incoming messages, this time with
longer names to test the layout.
-->
<message type='incoming' time='10:30:23'>
<from>
<contact contactId='carol@kmess.org'>
<displayPicture url='' />
<displayName text='Carol with longer name' dir='ltr' />
</contact>
</from>
<body color='#0099cc'
fontFamily='Sans Serif'
fontBold='0'
fontItalic='0'
fontUnderline='0'
fontBefore='&lt;font face="Sans Serif" color="#0099cc"&gt;'
fontAfter='&lt;/font&gt;'
dir='ltr'
>Hello there!</body>
</message>
<message type='incoming' time='10:30:59'>
<from>
<contact contactId='alice@kmess.org'>
<displayPicture url='' />
<displayName text='Alice' dir='ltr' />
</contact>
</from>
<body color='#0033cc'
fontFamily='Sans Serif'
fontBold='0'
fontItalic='0'
fontUnderline='0'
fontBefore='&lt;font face="Sans Serif" color="#0033cc"&gt;'
fontAfter='&lt;/font&gt;'
dir='ltr'
>Welcome to the chat Carol</body>
</message>
<!--
Outgoing message to another contact.
The "Group follow-up messages from the same contact" is checked,
the messages will be grouped in a <messagegroup> node.
Each time a new message is appended, the whole group is regenerated.
-->
<messagegroup>
<message type='outgoing' time='10:24:30'>
<from>
<contact contactId='bob@kmess.org'>
<displayPicture url='' />
<displayName text='Bob' dir='ltr' />
</contact>
</from>
<body color='#cc3300'
fontFamily='Verdana'
fontBold='0'
fontItalic='0'
fontUnderline='0'
fontBefore='&lt;font face="Verdana" color="#cc3300"&gt;'
fontAfter='&lt;/font&gt;'
dir='ltr'
>I'm not sure yet</body>
</message>
<message type='outgoing' time='10:24:40'>
<from>
<contact contactId='bob@kmess.org'>
<displayPicture url='' />
<displayName text='Bob' dir='ltr' />
</contact>
</from>
<body color='#cc3300'
fontFamily='Verdana'
fontBold='0'
fontItalic='0'
fontUnderline='0'
fontBefore='&lt;font face="Verdana" color="#cc3300"&gt;'
fontAfter='&lt;/font&gt;'
dir='ltr'
>no really</body>
</message>
</messagegroup>
<!--
This is testing the right-to-left support of your chat theme.
The 'dir' attribute indicates whether it's left-to-right (ltr) or right-to-left (rtl).
The name can be right-to-left, or the message, or both.
-->
<message type='incoming' time='10:31:30'>
<from>
<contact contactId='rtl@kmess.org'>
<displayPicture url='' />
<displayName text='right to left name' dir='rtl' />
</contact>
</from>
<body color='#0099cc'
fontFamily='Sans Serif'
fontBold='0'
fontItalic='0'
fontUnderline='0'
fontBefore='&lt;font face="Sans Serif" color="#0099cc"&gt;'
fontAfter='&lt;/font&gt;'
dir='ltr'
>This name is written right-to-left. Next message should be entirely right-to-left.</body>
</message>
<message type='incoming' time='10:31:59'>
<from>
<contact contactId='alice@kmess.org'>
<displayPicture url='' />
<displayName text='הודעות טקסט' dir='rtl' />
</contact>
</from>
<body color='#0033cc'
fontFamily='Sans Serif'
fontBold='0'
fontItalic='0'
fontUnderline='0'
fontBefore='&lt;font face="Sans Serif" color="#0033cc"&gt;'
fontAfter='&lt;/font&gt;'
dir='rtl'
>הודעות טקסט</body>
</message>
<!--
Testing notification messages.
These are used for events (you got a wink, nudge) and invitations.
-->
<message type='notification' date='2006-10-08' time='15:13:12'>
<from>
<contact contactId='alice@kmess.org'>
</contact>
</from>
<body color=''
fontFamily='Verdana'
fontBold='0'
fontItalic='0'
fontUnderline='0'
fontBefore=''
fontAfter=''
dir='ltr'
>&lt;span class="acceptMessage"&gt;Do you want to accept the file: &lt;span class="filename invitedFilename"&gt;desktop.ini&lt;/span&gt; (79 bytes) Do you want to &lt;a href="kmess://accept/alice@kmess.org?976544"&gt;accept&lt;/a&gt; or &lt;a href="kmess://reject/alice@kmess.org?976544"&gt;cancel&lt;/a&gt;?&lt;/span&gt;</body>
</message>
<!--
Testing application messages.
These are informative messages, like "file transfer complete".
-->
<message type='application' date='2006-10-08' time='15:13:25'>
<from>
<contact contactId='alice@kmess.org'>
</contact>
</from>
<body color=''
fontFamily='Verdana'
fontBold='0'
fontItalic='0'
fontUnderline='0'
fontBefore=''
fontAfter=''
dir='ltr'
>Successfully transferred file: &lt;span class="filename completedFilename"&gt;&lt;a href="file:/home/diederik/Desktop/desktop.ini"&gt;desktop.ini&lt;/a&gt;&lt;/span&gt;</body>
</message>
<!--
Just a message in between so it looks more like a chat.
The contact uses a different font here.
-->
<message type='outgoing' date='2006-10-08' time='15:14:00'>
<from>
<contact contactId='bob@kmess.org'>
<displayPicture url='' />
<displayName text='Bob' dir='ltr' />
</contact>
</from>
<body color='#66aa00'
fontFamily='Verdana'
fontBold='0'
fontItalic='0'
fontUnderline='0'
fontBefore='&lt;font face="Verdana" color="#66aa00"&gt;'
fontAfter='&lt;/font&gt;'
dir='ltr'
>Thanks for the file</body>
</message>
<!--
Testing system error messages.
These are used for unsupported things and errors
like "invitation not supported", "contact is offline"
-->
<message type='system' date='2006-10-08' time='15:26:52'>
<from>
<contact contactId='alice@kmess.org'>
</contact>
</from>
<body color=''
fontFamily='Verdana'
fontBold='0'
fontItalic='0'
fontUnderline='0'
fontBefore=''
fontAfter=''
dir='ltr'
>The contact is inviting you for 'Bejeweled', but this is not implemented yet.</body>
</message>
<!--
Offline-IM messages.
These are received when the user gets online.
This is the main reason why each message also has a 'date' attribute.
-->
<message type='offlineIncoming' date='2006-10-08' time='15:26:52'>
<from>
<contact contactId='alice@kmess.org'>
<displayPicture url='' />
<displayName text='Alice' dir='ltr' />
</contact>
</from>
<body color='#0033cc'
fontFamily='Sans Serif'
fontBold='0'
fontItalic='0'
fontUnderline='0'
fontBefore='&lt;font face="Sans Serif" color="#0033cc"&gt;'
fontAfter='&lt;/font&gt;'
dir='ltr'
>This is an offline-IM message.</body>
</message>
</messageRoot>