IdxRichEditShape Interface
Exposes a floating shape within the document’s shape collection.
Declaration
IdxRichEditShape = interface(IInterface)
Remarks
Floating shapes are pictures or text boxes positioned absolutely or relatively in a rich text document, without binding them to specific character positions in text. You can place shapes in front of the document’s “text” layer, behind, or within it by choosing one of the text wrapping options that the IdxRichEditShape interface provides.
The IdxRichEditShape interface provides the properties and methods that allow you to:
Specify the shape’s background fill settings (Fill and GetFill);
Specify the margins between the shape’s bounding rectangle and text for the shape positioned within the document’s “text” layer (MarginBottom, MarginLeft, MarginRight, MarginTop, GetMarginBottom, GetMarginLeft, GetMarginRight, GetMarginTop, SetMarginBottom, SetMarginLeft, SetMarginRight, and SetMarginTop);
Obtain the original shape’s dimensions (OriginalSize and GetOriginalSize);
Resize the shape (ScaleX, ScaleY, Size, SetScaleX, SetScaleY, SetSize);
Access a text box or Office Image container hosted within the shape (TextBox and GetTextBox, or Picture and GetPicture, respectively);
Specify a reference to an external image hosted in the floating picture (PictureUri, SetPictureUri, and GetPictureUri);
Change the floating shape’s z-order within the current document layer (ZOrder);
Forbid or allow end-users to change the shape’s dimensions independently by using the corner sizing handles or the Layout dialog (LockAspectRatio);
Obtain the document range to which the floating shape is anchored (Range, GetRange);
Position the shape within a document (Offset, HorizontalAlignment, VerticalAlignment, RelativeHorizontalPosition, RelativeVerticalPosition, SetOffset, SetHorizontalAlignment, SetVerticalAlignment, SetRelativeHorizontalPosition, SetRelativeVerticalPosition, GetOffset, GetHorizontalAlignment, GetVerticalAlignment, GetRelativeHorizontalPosition, and GetRelativeVerticalPosition);
Rotate the shape clockwise or counter-clockwise (RotationAngle);
Specify a text wrapping type for the shape or place it in front of the document’s “text” layer or behind it (TextWrapping, SetTextWrapping, and GetTextWrapping).
The Rich Edit control’s Document.Shapes.Items property references the IdxRichEditShape interface. Use the Picture and TextBox properties to identify if the floating shape is a text box or picture.