Procedure TParagraph.ParagraphObjAdd(obj:TCustomParagraphObj)
Unit: WPRTEDefs
Class: WPRTEDefs.TParagraph
Parameters
Description
The procedure ParagraphObjAdd attaches a property object to a paragraph. Such an object is automatically freed when the paragraph is destroyed. The objects have to be derived from
// This example creates a property popup which
// displays a panel with enclosed speed button.
var par : TParagraph;
obj : TWPParPopupObj;
begin
par := WPRichText1.FirstPar;
while par<>nil do
begin
par.ParagraphObjClear;
if par.ParagraphType=wpIsTable then
begin
obj := TWPParPopupObj.Create( WPPAROBJ_PopupObjTyp );
obj.Position := wrmBottomRight;
obj.Width := +Panel2.Width; // - for wrmLeft !
obj.Height := Panel2.Height;
obj.aControl := Panel2;
par.ParagraphObjAdd( obj );
end;
par := par.NextPar;
end;