rvico TRichView Reference | How to...

...create a chat window

Top  Previous  Next

You can find the complete demo of a chat window on the support forum: http://www.trichview.com/forums/viewtopic.php?t=63

This demo shows how to implement a chat window with the following features. The user types a plain text message in TEdit. This message can contain special commands, they are processed before displaying in TRichView window.

This demo supports:

text commands;

emoticons;

URL detection.

Examples of text commands:

\b to make text bold (toggle);

\cRRGGBB to change text color.

Emoticons are easily customizable (their codes and graphics are stored in arrays). This demo uses bitmaps, but you can change them to Gif images (see how to use third-party graphic classes), including animations. For additional ideas about emoticons, see the demo in Demos\Delphi\Assorted\Graphics\Emoticons\.

URL detection use RVIsURL and RVIsEmail functions. You can use RVIsCustomURL to define your own types of links.

 


TRichView © trichview.com