TCustomRichViewEdit.OnItemTextEdit

<< Click to display table of contents >>

TCustomRichViewEdit.OnItemTextEdit

Occurs when text item's text is changed as a result of editing operation.

type

  TRVItemTextEditEvent = procedure (Sender: TCustomRichViewEdit; 

    const OldText: TRVUnicodeString; RVData: TCustomRVData;

    ItemNo: Integer; var NewTag: TRVTagvar NewStyleNo: Integer)

    of object;

property OnItemTextEdit: TRVItemTextEditEvent;

(introduced in version 10; changed in version 18)

This event is designed to update tags of hyperlinks.

This event is called when document is not completely formatted, so do not use any methods for changing document or methods requiring formatted document in this event.

Input Parameters:

OldText the item text before the editing operation.

RVData, ItemNo identify the item. RVData document containing this item; it can be Sender.RVData, table cell, or RVData of cell inplace-editor. ItemNo index of this item inside RVData. You can get text after the editing operation using RVData.GetItemTextW(ItemNo).

NewTag the item tag, the same as RVData.GetItemTag(ItemNo)

NewStyleNo the item style, index in the collection Style.TextStyles, the same as RVData.GetItemStyle(ItemNo)

Output Parameters:

NewTag value of tag to assign to this item.

NewStyleNo style index to assign to this item.