TCustomRichViewEdit.InsertCheckpoint

<< Click to display table of contents >>

TCustomRichViewEdit.InsertCheckpoint

Inserts checkpoint in the position of caret.

procedure InsertCheckpoint(const ATag: TRVTagconst AName: TRVUnicodeString;

 ARaiseEvent: Boolean);

(introduced in version 10; changed in version 18)

This method is similar to SetCurrentCheckpointInfo, but inserts checkpoint exactly in the position of caret.

If the caret is at the beginning of item, this methods calls SetCheckpointInfoEd to add checkpoint for this item.

If the caret is at the middle of text item, this method splits this item at the position of caret, and calls SetCheckpointInfoEd to add checkpoint for the item to the right.

If the caret is at the end of paragraph, the method moves it to the beginning of the next paragraph, and calls SetCheckpointInfoEd to add checkpoint for the first paragraph item (or the second item, if the first one is list marker).

If the caret is at the end of document, this methods does nothing.

This method is used in conjunction with GetCheckpointAtCaret and RemoveCheckpointAtCaret (GetCurrentCheckpoint and RemoveCurrentCheckpoint cannot be used, because checkpoint added by this method is not necessary belongs to the current item (that is usually the item to the left of the caret).

Parameters.

ATag tag of checkpoint;

AName name of the checkpoint, any string without line break (CR, LF) characters.

ARaiseEvent "raise event" flag; if set, RichView can generate OnCheckpointVisible event for this checkpoint.

 

Method type: editstyle editing-style.

 

See also:

Modifying RichView items;

"Checkpoints";

"Tags".