I save formatted text of RichViewEdit into stream. therefore i want to replace something like "[img]" in text with animated gif logo and then insert it into RichView.
if found a source code that is for replacing text with image in RichViewEdit :
Code: Select all
procedure ReplaceImages;
procedure SearchAndInsertIcon(const Code: String; ImageIndex: Integer);
begin
RVE.SetSelectionBounds(0, RVE.GetOffsBeforeItem(0), 0, RVE.GetOffsBeforeItem(0));
while RVE.SearchText(Code, [rvseoDown]) do
RVE.InsertBullet(ImageIndex, ImageList1);
end;
begin
SearchAndInsertIcon(':)', 0);
SearchAndInsertIcon(':|', 1);
SearchAndInsertIcon(':(', 2);
end;
1- that's for replacing in RichViewEdit not RichView
2- It load images from TImageList so it impossible to insert animated gif images. ImageList just loads bitmap and icons