Back to Paragraph
AddImageMethod
Definition
- Namespace
- DOM.Elements.TextElements
- Assembly
- DOM.dll
Adds an image to the paragraph's content flow.
AddImage(IImage image)Parameters
- image
- The image element to add.
Returns
The same instance, enabling fluent usage patterns. image
Remarks
The image is appended as a child element of the paragraph. Depending on its wrapping style (), the image may participate in the inline layout (inline) or float (square, through, behind/in front of text). SetWrappingStyle(WrappingStyle)
Examples
csharp
1var p = doc.AddParagraph();
2p.AddImage("icon.png")
3 .SetDimensions(16, 16, Units.pt);
4