Class Shape
Represents the shape used by the presentation model.
Implements
Inherited Members
Namespace: DRIT.Presentation.Drawing
Assembly: DRIT.Presentation.dll
Syntax
public class Shape : AbstractShape, IDrawingObject
Properties
FormattedText
Gets or sets the formatted text associated with this object.
Declaration
public virtual FormattedText FormattedText { get; }
Property Value
| Type | Description |
|---|---|
| FormattedText |
Ink
Gets or sets the ink associated with this object.
Declaration
public Ink Ink { get; }
Property Value
| Type | Description |
|---|---|
| Ink |
IsMathShape
Gets or sets whether is math shape is enabled.
Declaration
public override bool IsMathShape { get; }
Property Value
| Type | Description |
|---|---|
| bool |
Overrides
LockAspectRatio
Gets or sets whether the picture retains its original proportions when you resize it.
Declaration
public bool LockAspectRatio { get; set; }
Property Value
| Type | Description |
|---|---|
| bool |
MathParagraph
Gets or sets the math paragraph associated with this object.
Declaration
public MathParagraph MathParagraph { get; set; }
Property Value
| Type | Description |
|---|---|
| MathParagraph |
Outline
Gets the line (outline) properties for this shape.
Declaration
public Line Outline { get; }
Property Value
| Type | Description |
|---|---|
| Line |
Picture
Gets or sets the picture associated with this object.
Declaration
public Picture Picture { get; }
Property Value
| Type | Description |
|---|---|
| Picture |
Methods
GetGeometryPaths()
Gets the geometry paths from this shape.
Declaration
public override IReadOnlyList<GeometryPath> GetGeometryPaths()
Returns
| Type | Description |
|---|---|
| IReadOnlyList<GeometryPath> | The get geometry paths value produced by the operation. |
Overrides
SaveImage(string, ImageFormat, int)
Saves a loaded embedded picture shape to a file in the specified image format.
Declaration
public void SaveImage(string path, ImageFormat format, int quality = 100)
Parameters
| Type | Name | Description |
|---|---|---|
| string | path | The output image path. |
| ImageFormat | format | The output image format. |
| int | quality | The JPEG quality from 0 to 100. |
SetGeometryPath(GeometryPath)
Sets the geometry path for this shape.
Declaration
public Shape SetGeometryPath(GeometryPath geometryPath)
Parameters
| Type | Name | Description |
|---|---|---|
| GeometryPath | geometryPath |
Returns
| Type | Description |
|---|---|
| Shape | The set geometry path value produced by the operation. |
SetGeometryPaths(IEnumerable<GeometryPath>)
Sets the geometry paths for this shape.
Declaration
public Shape SetGeometryPaths(IEnumerable<GeometryPath> geometryPaths)
Parameters
| Type | Name | Description |
|---|---|---|
| IEnumerable<GeometryPath> | geometryPaths |
Returns
| Type | Description |
|---|---|
| Shape | The set geometry paths value produced by the operation. |
SetImage(string)
Sets the image for this shape.
Declaration
public override AbstractShape SetImage(string path)
Parameters
| Type | Name | Description |
|---|---|---|
| string | path | The path supplied to this operation. |
Returns
| Type | Description |
|---|---|
| AbstractShape | The set image value produced by the operation. |
Overrides
SetInk(Ink)
Attaches an Ink annotation to this shape and returns the shape for fluent chaining.
Declaration
public Shape SetInk(Ink ink)
Parameters
| Type | Name | Description |
|---|---|---|
| Ink | ink | The ink annotation to attach, or null to remove. |
Returns
| Type | Description |
|---|---|
| Shape |
SetSmartArt(SmartArtShapeInfo)
Attaches a SmartArt graphic to this shape, or removes it when
info is null.
Declaration
public Shape SetSmartArt(SmartArtShapeInfo info)
Parameters
| Type | Name | Description |
|---|---|---|
| SmartArtShapeInfo | info |
Returns
| Type | Description |
|---|---|
| Shape |