How to: Insert Inline Picture
To insert a picture in line with text, use the DocumentImageCollection.Insert method.
Note
A complete sample project is available at https://github.com/DevExpress-Examples/wpf-richedit-document-api-t213968.
DocumentPosition pos = document.Range.Start;
StreamResourceInfo streamResInfo = Application.GetResourceStream(new Uri("beverages.png", UriKind.Relative));
if (streamResInfo != null)
{
using (Stream s = streamResInfo.Stream)
{
document.Images.Insert(pos, DocumentImageSource.FromStream(s));
}
}