rvico TRichView Reference | TRichViewEdit


Top  Previous  Next

Inserts Delphi/C++Builder control in the position of caret.

function InsertControl(const Name: TRVAnsiString; ctrl: TControl;

  VAlign: TRVVAlign): Boolean;


Name – name of this control item, any string. Name must not contain CR and LF characters. RichView does not use item names itself, they are for your own use. This is an ANSI string, regardless of Unicode mode of text styles. Do not confuse with ctrl.Name property.

ctrl – control to insert. You should create control but should not destroy it (RichViewEdit will do it for you).

VAlign – vertical align of this control, relative to its line, see TRVVAlign for possible values.


Method type: editstyle editing-style method for insertion.

unicode Unicode note: names of non-text items are ANSI strings.


Return value

True if the insertion was successful (it can fail due to protection, or when inserting in table having multicell selection)

See also methods of TCustomRichView:

AddControlEx and others;

See also:

Inserting items in position of caret;

Item types.

TRichView © trichview.com