Code: Select all
procedure QuoteText(const Prefix: String; MaxLength: Integer; rv: TCustomRichView);
Parameters:
Prefix - text to insert before each line (for example, '>', or 'John>')
MaxLength - length of lines, in pixels. Lines exceeding this width will be separated into smaller lines. Width of Prefix is not taken into account.
This procedure formats document. It is not necessary to format document before calling this procedure.
This is not an editing operation. If it is called for TRichViewEdit, call RichViewEdit.ClearUndo after.
Example:
Code: Select all
QuoteText('>', RichViewEdit1.ClientWidth-50, RichViewEdit1);
RichViewEdit1.ClearUndo;