I have the following problem with adding picture to paragraph. When I insert some text and pictures into the paragraph, I want the picture to follow the text, that is, "In line with text", so I set the "wrap" value to agowInLine, but it doesn't seem to work properly. I looked at the "text wrapping" of the picture and found it is "Behind text". Maybe I'm doing something wrong, code show as below:
Code: Select all
var
GrPic: TAXWGraphicPicture;
Pic: TAXWPicture;
Para: TAXWLogPara;
DOCX: TDOCXReadWrite;
begin
...
Para := DOCX.Editor.Paras.AppendPara;
Pic := DOCX.Editor.Pictures.AddPicture('123.jpg');
GrPic := TAXWGraphicPicture.Create(Pic);
GrPic.Wrap := agowInLine;
GrPic.Scale(0.5);
Para.AddGraphic(GrPic);
Para := DOCX.Editor.Paras.AppendPara;
Para.AppendPlainText('Embarcadero Studio');
Para := DOCX.Editor.Paras.AppendPara;
Para.AppendPlainText('TAXWReadWriteVCL');
end;

Thanks!