TCustomRichView.AddControl

<< Click to display table of contents >>

TCustomRichView.AddControl

These methods add Delphi control to the end of document.

procedure AddControl(const Name: TRVUnicodeString; ctrl: TControl;
  ParaNo: Integer = -1; VAlign: TRVVAlign = rvvaBaseline; 

  const Tag: TRVTag = RVEMPTYTAG);

(changed in version 18)

Parameters:

Name name of this control item, any string. Name must not contain CR and LF characters. TRichView does not use item names itself, they are for your own use. Do not confuse with ctrl.Name property.

ctrl control to insert.

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

If ParaNo=-1, the method adds an item to the end of the last paragraph. If ParaNo>=0, this item starts a new paragraph using attributes defined in Style.ParaStyles[ParaNo].

Tag tag of this control item. Do not confuse with ctrl.Tag property.

Methods type: viewerstyle viewer-style.

See also methods:

Format;

FormatTail;

SetAddParagraphMode.

See also methods of TRichViewEdit:

InsertControl.

See also properties of TRVStyle:

ParaStyles.

See also:

Item types;

Other methods for appending items;

"Tags".


Related deprecated methods:

procedure AddControlExTag(const Name: TRVAnsiString; ctrl: TControl;

  ParaNo: Integer; VAlign: TRVVAlignconst Tag: TRVTag);

procedure AddControlEx(const Name: TRVAnsiString; ctrl: TControl;

  ParaNo: Integer; VAlign: TRVVAlign);

These methods provide subset of functionality of AddControl.