SmartArtShape
SmartArtShape class
Represents the smart art.
Properties
| Name | Type | Description |
|---|---|---|
| MacroName | String | Gets and sets the name of macro. |
| IsEquation | boolean | Indicates whether the shape only contains an equation. |
| IsSmartArt | boolean | Indicates whether the shape is a smart art. Only for ooxml file. |
| ZOrderPosition | Number | Returns the position of a shape in the z-order. |
| Name | String | Gets and sets the name of the shape. |
| AlternativeText | String | Returns or sets the descriptive (alternative) text string of the Shape object. |
| Title | String | Specifies the title (caption) of the current shape object. |
| LineFormat | MsoLineFormat | Returns a MsoLineFormat object that contains line formatting properties for the specified shape. NOTE: This member is no |
| FillFormat | MsoFillFormat | Returns a MsoFillFormat object that contains fill formatting properties for the specified shape. NOTE: This member is no |
| Line | LineFormat | Gets line style |
| Fill | FillFormat | Returns a FillFormat object that contains fill formatting properties for the specified shape. |
| ShadowEffect | ShadowEffect | Represents a ShadowEffect object that specifies shadow effect for the chart element or shape. |
| Reflection | ReflectionEffect | Represents a ReflectionEffect object that specifies reflection effect for the chart element or shape. |
| Glow | GlowEffect | Represents a GlowEffect object that specifies glow effect for the chart element or shape. |
| SoftEdges | Number | Gets and sets the radius of blur to apply to the edges, in unit of points. |
| ThreeDFormat | ThreeDFormat | Gets and sets 3d format of the shape. |
| FormatPicture | MsoFormatPicture | Gets and sets the options of the picture format. |
| IsHidden | boolean | Indicates whether the object is visible. |
| IsLockAspectRatio | boolean | True means that aspect ratio of the shape is locked. Only for pictures and Ole Objects. NOTE: This member is now obsolet |
| IsAspectRatioLocked | boolean | True means that aspect ratio of the shape is locked. Only for pictures and Ole Objects. |
| RotationAngle | Number | Gets and sets the rotation of the shape. |
| Hyperlink | Hyperlink | Gets the hyperlink of the shape. |
| Id | Number | Gets the identifier of this shape. |
| Spid | String | Specifies an optional string identifier that an application can use to identify the particular shape. |
| Spt | Number | Specifies an optional number that an application can use to associate the particular shape with a defined shape type. |
| Worksheet | Worksheet | Gets the Worksheet object which contains this shape. |
| IsGroup | boolean | Indicates whether this shape is a group shape. |
| IsInGroup | boolean | Indicates whether the shape is grouped. |
| IsWordArt | boolean | Indicates whether this shape is a word art. Only for the Legacy Shape of xls file. |
| TextEffect | TextEffectFormat | Returns a TextEffectFormat object that contains text-effect formatting properties for the specified shape. Applies to Sh |
| IsLocked | boolean | True means the object can not be modified when the sheet is protected. Note that this value is meaningful only if the wo |
| IsPrintable | boolean | Indicates whether the object is printable. If False, this shape will not be printed when printing. |
| MsoDrawingType | Number | Gets drawing type. The value of the property is MsoDrawingType integer constant. |
| AutoShapeType | Number | Gets and sets the auto shape type. The value of the property is AutoShapeType integer constant. |
| AnchorType | Number | Gets and set the type of the shape anchor placeholder. The value of the property is ShapeAnchorType integer constant. |
| Placement | Number | Represents the way the drawing object is attached to the cells below it. The property controls the placement of an objec |
| UpperLeftRow | Number | Represents the top row index. If the shape is in the shape or in the group , UpperLeftRow will be ignored. |
| UpperDeltaY | Number | Gets or sets the shape’s vertical offset from its upper left corner row. The range of value is 0 to 256. |
| UpperLeftColumn | Number | Represents upper left corner column index. |
| UpperDeltaX | Number | Gets or sets the shape’s horizontal offset from its upper left corner column. The range of value is 0 to 1024. |
| LowerRightRow | Number | Represents lower right corner row index. |
| LowerDeltaY | Number | Gets or sets the shape’s vertical offset from its lower right corner row. The range of value is 0 to 256. |
| LowerRightColumn | Number | Represents lower right corner column index. |
| LowerDeltaX | Number | Gets or sets the shape’s horizontal offset from its lower right corner column. The range of value is 0 to 1024. |
| Right | Number | Represents the width of the shape’s horizontal offset from its lower right corner column, in unit of pixels. |
| Bottom | Number | Represents the width of the shape’s vertical offset from its lower bottom corner row, in unit of pixels. |
| Width | Number | Represents the width of shape, in unit of pixels. |
| WidthInch | Number | Represents the width of the shape, in unit of inch. |
| WidthPt | Number | Represents the width of the shape, in unit of point. |
| WidthCM | Number | Represents the width of the shape, in unit of centimeters. |
| Height | Number | Represents the height of shape, in unit of pixel. |
| HeightInch | Number | Represents the height of the shape, in unit of inches. |
| HeightPt | Number | Represents the height of the shape, in unit of points. |
| HeightCM | Number | Represents the height of the shape, in unit of centimeters. |
| Left | Number | Represents the horizontal offset of shape from its left column, in unit of pixels. |
| LeftInch | Number | Represents the horizontal offset of shape from its left column, in unit of inches. |
| LeftCM | Number | Represents the horizontal offset of shape from its left column, in unit of centimeters. |
| Top | Number | Represents the vertical offset of shape from its top row, in unit of pixels. If the shape is in the chart, represents th |
| TopInch | Number | Represents the vertical offset of shape from its top row, in unit of inches. |
| TopCM | Number | Represents the vertical offset of shape from its top row, in unit of centimeters. |
| TopToCorner | Number | Gets and sets the vertical offset of shape from worksheet top border, in unit of pixels. |
| LeftToCorner | Number | Gets and sets the horizonal offset of shape from worksheet left border. |
| X | Number | Gets and sets the horizontal offset of shape from worksheet left border,in unit of pixels. |
| Y | Number | Gets and sets the vertical offset of shape from worksheet top border,in unit of pixels. |
| WidthScale | Number | Gets and sets the width scale, in unit of percent of the original picture width. If the shape is not picture ,the WidthS |
| HeightScale | Number | Gets and sets the height scale,in unit of percent of the original picture height. If the shape is not picture ,the Heigh |
| TopInShape | Number | Represents the vertical offset of shape from the top border of the parent shape, in unit of 1/4000 of height of the pare |
| LeftInShape | Number | Represents the horizontal offset of shape from the left border of the parent shape, in unit of 1/4000 of width of the pa |
| WidthInShape | Number | Represents the width of the shape, in unit of 1/4000 of the parent shape. Only Applies when this shape in the group or c |
| HeightInShape | Number | Represents the vertical offset of shape from the top border of the parent shape, in unit of 1/4000 of height of the pare |
| Group | GroupShape | Gets the group shape which contains this shape. |
| Type | Number | Gets the auto shape type. The value of the property is AutoShapeType integer constant. |
| HasLine | boolean | Gets and sets the line border of the shape is visible. |
| IsFilled | boolean | Indicates whether the fill format is visible. |
| IsFlippedHorizontally | boolean | Gets and sets whether shape is horizontally flipped . |
| IsFlippedVertically | boolean | Gets and sets whether shape is vertically flipped . |
| ActualLowerRightRow | Number | Get the actual bottom row. |
| RelativeToOriginalPictureSize | boolean | Indicates whether shape is relative to original picture size. |
| LinkedCell | String | Gets or sets the worksheet range linked to the control’s value. |
| InputRange | String | Gets or sets the worksheet range used to fill the specified combo box. |
| TextShapeType | Number | Gets and sets the preset text shape type. The value of the property is AutoShapeType integer constant. |
| TextBody | FontSettingCollection | Gets and sets the setting of the shape’s text. |
| Font | Font | Represents the font of shape. |
| TextOptions | TextOptions | Represents the text options of the shape. |
| Text | String | Gets and sets the text of this shape. |
| IsRichText | boolean | Whether or not the text is rich text. |
| HtmlText | String | Gets and sets the html string which contains data and some formats in this textbox. |
| TextVerticalOverflow | Number | Gets and sets the text vertical overflow type of the shape which contains text. The value of the property is TextOverflo |
| TextHorizontalOverflow | Number | Gets and sets the text horizontal overflow type of the shape which contains text. The value of the property is TextOverf |
| IsTextWrapped | boolean | Gets and sets the text wrapped type of the shape which contains text. |
| TextOrientationType | Number | Gets and sets the text orientation type of the shape. The value of the property is TextOrientationType integer constant. |
| TextHorizontalAlignment | Number | Gets and sets the text horizontal alignment type of the shape. The value of the property is TextAlignmentType integer co |
| TextVerticalAlignment | Number | Gets and sets the text vertical alignment type of the shape. The value of the property is TextAlignmentType integer cons |
| TextDirection | Number | Gets/Sets the direction of the text flow for this object. The value of the property is TextDirectionType integer constan |
| TextBoxOptions | TextBoxOptions | |
| ControlData | byte[] | Gets the data of control. |
| ActiveXControl | ActiveXControl | Gets the ActiveX control. |
| Paths | ShapePathCollection | Gets the paths of a custom geometric shape. |
| Geometry | Geometry | Gets the geometry |
| CreateId | UUID | Gets and sets create id for this shape. |
| IsDecorative | boolean | Indicates whether the object is decorative. |
Methods
| Name | Description |
|---|---|
| getResultOfSmartArt | Converting smart art to grouped shapes. |
| getLinkedCell | Gets the range linked to the control’s value. |
| setLinkedCell | Sets the range linked to the control’s value. |
| getInputRange | Gets the range used to fill the control. |
| setInputRange | Sets the range used to fill the control. |
| updateSelectedValue | Update the selected value by the value of the linked cell. |
| calculateTextSize | Recalculate the text area |
| formatCharacters | Formats some characters with the font setting. |
| characters | Returns a Characters object that represents a range of characters within the text. |
This method only works on shape with | | getCharacters | Returns all Characters objects that represents a range of characters within the text .
NOTE: This method is now obsolet | | getRichFormattings | Returns all Characters objects that represents a range of characters within the text . | | removeActiveXControl | Remove activeX control. | | isSameSetting | Returns whether the shape is same. | | getActualBox | Get the actual position and size of the shape (after applying rotation, flip, etc.)
Note:The interface is not fully fun | | fitToTextSize | | | getConnectionPoints | Get the connection points | | toImage | Creates the shape image and saves it to a stream in the specified format.
The following formats are supported: .bmp, .g | | toFrontOrBack | Brings the shape to the front or sends the shape to back. | | getLockedProperty | Gets the value of locked property. | | setLockedProperty | Set the locked property. | | addHyperlink | Adds a hyperlink to the shape. | | removeHyperlink | Removes the hyperlink of the shape. | | moveToRange | Moves the shape to a specified range. | | alignTopRightCorner | Moves the picture to the top-right corner. |
SmartArtShape.MacroName property
Gets and sets the name of macro.
Type: String
SmartArtShape.IsEquation property
Indicates whether the shape only contains an equation.
Type: boolean
SmartArtShape.IsSmartArt property
Indicates whether the shape is a smart art. Only for ooxml file.
Type: boolean
SmartArtShape.ZOrderPosition property
Returns the position of a shape in the z-order.
Type: Number
SmartArtShape.Name property
Gets and sets the name of the shape.
Type: String
SmartArtShape.AlternativeText property
Returns or sets the descriptive (alternative) text string of the Shape object.
Type: String
SmartArtShape.Title property
Specifies the title (caption) of the current shape object.
Type: String
SmartArtShape.LineFormat property
Returns a MsoLineFormat object that contains line formatting properties for the specified shape. NOTE: This member is now obsolete. Instead, please use Shape.Line property. This property will be removed 12 months later since July 2016. Aspose apologizes for any inconvenience you may have experienced.
Type: MsoLineFormat
SmartArtShape.FillFormat property
Returns a MsoFillFormat object that contains fill formatting properties for the specified shape. NOTE: This member is now obsolete. Instead, please use Shape.Fill property. This property will be removed 12 months later since July 2016. Aspose apologizes for any inconvenience you may have experienced.
Type: MsoFillFormat
SmartArtShape.Line property
Gets line style
Type: LineFormat
SmartArtShape.Fill property
Returns a FillFormat object that contains fill formatting properties for the specified shape.
Type: FillFormat
SmartArtShape.ShadowEffect property
Represents a ShadowEffect object that specifies shadow effect for the chart element or shape.
Type: ShadowEffect
SmartArtShape.Reflection property
Represents a ReflectionEffect object that specifies reflection effect for the chart element or shape.
Type: ReflectionEffect
SmartArtShape.Glow property
Represents a GlowEffect object that specifies glow effect for the chart element or shape.
Type: GlowEffect
SmartArtShape.SoftEdges property
Gets and sets the radius of blur to apply to the edges, in unit of points.
Type: Number
SmartArtShape.ThreeDFormat property
Gets and sets 3d format of the shape.
Type: ThreeDFormat
SmartArtShape.FormatPicture property
Gets and sets the options of the picture format.
Type: MsoFormatPicture
SmartArtShape.IsHidden property
Indicates whether the object is visible.
Type: boolean
SmartArtShape.IsLockAspectRatio property
True means that aspect ratio of the shape is locked. Only for pictures and Ole Objects. NOTE: This member is now obsolete. Instead, please use Shape.IsAspectRatioLocked property. This property will be removed 12 months later since July 2024. Aspose apologizes for any inconvenience you may have experienced.
Type: boolean
SmartArtShape.IsAspectRatioLocked property
True means that aspect ratio of the shape is locked. Only for pictures and Ole Objects.
Type: boolean
SmartArtShape.RotationAngle property
Gets and sets the rotation of the shape.
Type: Number
SmartArtShape.Hyperlink property
Gets the hyperlink of the shape.
Type: Hyperlink
SmartArtShape.Id property
Gets the identifier of this shape.
Type: Number
SmartArtShape.Spid property
Specifies an optional string identifier that an application can use to identify the particular shape.
Type: String
SmartArtShape.Spt property
Specifies an optional number that an application can use to associate the particular shape with a defined shape type.
Type: Number
SmartArtShape.Worksheet property
Gets the Worksheet object which contains this shape.
Type: Worksheet
SmartArtShape.IsGroup property
Indicates whether this shape is a group shape.
Type: boolean
SmartArtShape.IsInGroup property
Indicates whether the shape is grouped.
Type: boolean
SmartArtShape.IsWordArt property
Indicates whether this shape is a word art. Only for the Legacy Shape of xls file.
Type: boolean
SmartArtShape.TextEffect property
Returns a TextEffectFormat object that contains text-effect formatting properties for the specified shape. Applies to Shape objects that represent WordArt.
Type: TextEffectFormat
SmartArtShape.IsLocked property
True means the object can not be modified when the sheet is protected. Note that this value is meaningful only if the worksheet or objects in the worksheet are protected.
Type: boolean
SmartArtShape.IsPrintable property
Indicates whether the object is printable. If False, this shape will not be printed when printing.
Type: boolean
SmartArtShape.MsoDrawingType property
Gets drawing type. The value of the property is MsoDrawingType integer constant.
Type: Number
SmartArtShape.AutoShapeType property
Gets and sets the auto shape type. The value of the property is AutoShapeType integer constant.
Type: Number
SmartArtShape.AnchorType property
Gets and set the type of the shape anchor placeholder. The value of the property is ShapeAnchorType integer constant.
Type: Number
SmartArtShape.Placement property
Represents the way the drawing object is attached to the cells below it. The property controls the placement of an object on a worksheet. The value of the property is PlacementType integer constant.
Type: Number
SmartArtShape.UpperLeftRow property
Represents the top row index. If the shape is in the shape or in the group , UpperLeftRow will be ignored.
Type: Number
SmartArtShape.UpperDeltaY property
Gets or sets the shape’s vertical offset from its upper left corner row. The range of value is 0 to 256.
Type: Number
SmartArtShape.UpperLeftColumn property
Represents upper left corner column index.
Type: Number
SmartArtShape.UpperDeltaX property
Gets or sets the shape’s horizontal offset from its upper left corner column. The range of value is 0 to 1024.
Type: Number
SmartArtShape.LowerRightRow property
Represents lower right corner row index.
Type: Number
SmartArtShape.LowerDeltaY property
Gets or sets the shape’s vertical offset from its lower right corner row. The range of value is 0 to 256.
Type: Number
SmartArtShape.LowerRightColumn property
Represents lower right corner column index.
Type: Number
SmartArtShape.LowerDeltaX property
Gets or sets the shape’s horizontal offset from its lower right corner column. The range of value is 0 to 1024.
Type: Number
SmartArtShape.Right property
Represents the width of the shape’s horizontal offset from its lower right corner column, in unit of pixels.
Type: Number
SmartArtShape.Bottom property
Represents the width of the shape’s vertical offset from its lower bottom corner row, in unit of pixels.
Type: Number
SmartArtShape.Width property
Represents the width of shape, in unit of pixels.
Type: Number
SmartArtShape.WidthInch property
Represents the width of the shape, in unit of inch.
Type: Number
SmartArtShape.WidthPt property
Represents the width of the shape, in unit of point.
Type: Number
SmartArtShape.WidthCM property
Represents the width of the shape, in unit of centimeters.
Type: Number
SmartArtShape.Height property
Represents the height of shape, in unit of pixel.
Type: Number
SmartArtShape.HeightInch property
Represents the height of the shape, in unit of inches.
Type: Number
SmartArtShape.HeightPt property
Represents the height of the shape, in unit of points.
Type: Number
SmartArtShape.HeightCM property
Represents the height of the shape, in unit of centimeters.
Type: Number
SmartArtShape.Left property
Represents the horizontal offset of shape from its left column, in unit of pixels.
Type: Number
SmartArtShape.LeftInch property
Represents the horizontal offset of shape from its left column, in unit of inches.
Type: Number
SmartArtShape.LeftCM property
Represents the horizontal offset of shape from its left column, in unit of centimeters.
Type: Number
SmartArtShape.Top property
Represents the vertical offset of shape from its top row, in unit of pixels. If the shape is in the chart, represents the vertical offset of shape from its top border.
Type: Number
SmartArtShape.TopInch property
Represents the vertical offset of shape from its top row, in unit of inches.
Type: Number
SmartArtShape.TopCM property
Represents the vertical offset of shape from its top row, in unit of centimeters.
Type: Number
SmartArtShape.TopToCorner property
Gets and sets the vertical offset of shape from worksheet top border, in unit of pixels.
Type: Number
SmartArtShape.LeftToCorner property
Gets and sets the horizonal offset of shape from worksheet left border.
Type: Number
SmartArtShape.X property
Gets and sets the horizontal offset of shape from worksheet left border,in unit of pixels.
Type: Number
SmartArtShape.Y property
Gets and sets the vertical offset of shape from worksheet top border,in unit of pixels.
Type: Number
SmartArtShape.WidthScale property
Gets and sets the width scale, in unit of percent of the original picture width. If the shape is not picture ,the WidthScale property only returns 100;
Type: Number
SmartArtShape.HeightScale property
Gets and sets the height scale,in unit of percent of the original picture height. If the shape is not picture ,the HeightScale property only returns 100;
Type: Number
SmartArtShape.TopInShape property
Represents the vertical offset of shape from the top border of the parent shape, in unit of 1/4000 of height of the parent shape. Only Applies when this shape in the group or chart.
Type: Number
SmartArtShape.LeftInShape property
Represents the horizontal offset of shape from the left border of the parent shape, in unit of 1/4000 of width of the parent shape. Only Applies when this shape in the group or chart.
Type: Number
SmartArtShape.WidthInShape property
Represents the width of the shape, in unit of 1/4000 of the parent shape. Only Applies when this shape in the group or chart.
Type: Number
SmartArtShape.HeightInShape property
Represents the vertical offset of shape from the top border of the parent shape, in unit of 1/4000 of height of the parent shape.. Only Applies when this shape in the group or chart.
Type: Number
SmartArtShape.Group property
Gets the group shape which contains this shape.
Type: GroupShape
SmartArtShape.Type property
Gets the auto shape type. The value of the property is AutoShapeType integer constant.
Type: Number
SmartArtShape.HasLine property
Gets and sets the line border of the shape is visible.
Type: boolean
SmartArtShape.IsFilled property
Indicates whether the fill format is visible.
Type: boolean
SmartArtShape.IsFlippedHorizontally property
Gets and sets whether shape is horizontally flipped .
Type: boolean
SmartArtShape.IsFlippedVertically property
Gets and sets whether shape is vertically flipped .
Type: boolean
SmartArtShape.ActualLowerRightRow property
Get the actual bottom row.
Type: Number
SmartArtShape.RelativeToOriginalPictureSize property
Indicates whether shape is relative to original picture size.
Type: boolean
SmartArtShape.LinkedCell property
Gets or sets the worksheet range linked to the control’s value.
Type: String
SmartArtShape.InputRange property
Gets or sets the worksheet range used to fill the specified combo box.
Type: String
SmartArtShape.TextShapeType property
Gets and sets the preset text shape type. The value of the property is AutoShapeType integer constant.
Type: Number
SmartArtShape.TextBody property
Gets and sets the setting of the shape’s text.
Type: FontSettingCollection
SmartArtShape.Font property
Represents the font of shape.
Type: Font
SmartArtShape.TextOptions property
Represents the text options of the shape.
Type: TextOptions
SmartArtShape.Text property
Gets and sets the text of this shape.
Type: String
SmartArtShape.IsRichText property
Whether or not the text is rich text.
Type: boolean
SmartArtShape.HtmlText property
Gets and sets the html string which contains data and some formats in this textbox.
Type: String
SmartArtShape.TextVerticalOverflow property
Gets and sets the text vertical overflow type of the shape which contains text. The value of the property is TextOverflowType integer constant.
Type: Number
SmartArtShape.TextHorizontalOverflow property
Gets and sets the text horizontal overflow type of the shape which contains text. The value of the property is TextOverflowType integer constant.
Type: Number
SmartArtShape.IsTextWrapped property
Gets and sets the text wrapped type of the shape which contains text.
Type: boolean
SmartArtShape.TextOrientationType property
Gets and sets the text orientation type of the shape. The value of the property is TextOrientationType integer constant.
Type: Number
SmartArtShape.TextHorizontalAlignment property
Gets and sets the text horizontal alignment type of the shape. The value of the property is TextAlignmentType integer constant.
Type: Number
SmartArtShape.TextVerticalAlignment property
Gets and sets the text vertical alignment type of the shape. The value of the property is TextAlignmentType integer constant.
Type: Number
SmartArtShape.TextDirection property
Gets/Sets the direction of the text flow for this object. The value of the property is TextDirectionType integer constant.
Type: Number
SmartArtShape.TextBoxOptions property
Type: TextBoxOptions
SmartArtShape.ControlData property
Gets the data of control.
Type: byte[]
SmartArtShape.ActiveXControl property
Gets the ActiveX control.
Type: ActiveXControl
SmartArtShape.Paths property
Gets the paths of a custom geometric shape.
Type: ShapePathCollection
SmartArtShape.Geometry property
Gets the geometry
Type: Geometry
SmartArtShape.CreateId property
Gets and sets create id for this shape.
Type: UUID
SmartArtShape.IsDecorative property
Indicates whether the object is decorative.
Type: boolean
getResultOfSmartArt()
Converting smart art to grouped shapes.
getLinkedCell(isR1C1, isLocal)
Gets the range linked to the control’s value.
| Parameter | Type | Description |
|---|---|---|
| isR1C1 | boolean | Whether the formula needs to be formatted as R1C1. |
| isLocal | boolean | Whether the formula needs to be formatted by locale. |
Returns: The range linked to the control’s value.
setLinkedCell(formula, isR1C1, isLocal)
Sets the range linked to the control’s value.
| Parameter | Type | Description |
|---|---|---|
| formula | String | The range linked to the control’s value. |
| isR1C1 | boolean | Whether the formula needs to be formatted as R1C1. |
| isLocal | boolean | Whether the formula needs to be formatted by locale. |
getInputRange(isR1C1, isLocal)
Gets the range used to fill the control.
| Parameter | Type | Description |
|---|---|---|
| isR1C1 | boolean | Whether the formula needs to be formatted as R1C1. |
| isLocal | boolean | Whether the formula needs to be formatted by locale. |
Returns: The range used to fill the control.
setInputRange(formula, isR1C1, isLocal)
Sets the range used to fill the control.
| Parameter | Type | Description |
|---|---|---|
| formula | String | The range used to fill the control. |
| isR1C1 | boolean | Whether the formula needs to be formatted as R1C1. |
| isLocal | boolean | Whether the formula needs to be formatted by locale. |
updateSelectedValue()
Update the selected value by the value of the linked cell.
calculateTextSize()
Recalculate the text area
Returns: Text’s Size in an array(width and height).
formatCharacters(startIndex, length, font, flag)
Formats some characters with the font setting.
| Parameter | Type | Description |
|---|---|---|
| startIndex | Number | The start index. |
| length | Number | The length. |
| font | Font | The font setting. |
| flag | StyleFlag | The flag of the font setting. |
characters(startIndex, length)
Returns a Characters object that represents a range of characters within the text.
This method only works on shape with title.
| Parameter | Type | Description |
|---|---|---|
| startIndex | Number | The index of the start of the character. |
| length | Number | The number of characters. |
Returns: Characters object.
getCharacters()
Returns all Characters objects that represents a range of characters within the text .
NOTE: This method is now obsolete. Instead, please use Shape.GetRichFormattings() method. This method will be removed 12 months later since November 2023. Aspose apologizes for any inconvenience you may have experienced.
Returns: All Characters objects
getRichFormattings()
Returns all Characters objects that represents a range of characters within the text .
Returns: All Characters objects
removeActiveXControl()
Remove activeX control.
isSameSetting(obj)
Returns whether the shape is same.
| Parameter | Type | Description |
|---|---|---|
| obj | Object |
getActualBox()
Get the actual position and size of the shape (after applying rotation, flip, etc.)
Note:The interface is not fully functional, especially the location information is not correct.It is recommended not to use this interface until the function is complete.
Returns: Return the position and size in the order of x, y, w, h
fitToTextSize()
getConnectionPoints()
Get the connection points
Returns: [X,Y] pairs of the connection point. Every item is a float[2] array, [0] represents x and [1] represents y.
toImage(stream, imageFormat) (1 of 3)
Creates the shape image and saves it to a stream in the specified format.
The following formats are supported: .bmp, .gif, .jpg, .jpeg, .tiff, .emf.
| Parameter | Type | Description |
|---|---|---|
| stream | OutputStream | The output stream. |
| imageFormat | ImageFormat | The format in which to save the image. |
toImage(imageFile, options) (2 of 3)
Saves the shape to a file.
toImage(stream, options) (3 of 3)
Saves the shape to a stream.
toFrontOrBack(orders)
Brings the shape to the front or sends the shape to back.
| Parameter | Type | Description |
|---|---|---|
| orders | Number | If it’s less than zero, sets the shape to back. If it’s greater than zero, brings the shape to front. |
getLockedProperty(type)
Gets the value of locked property.
| Parameter | Type | Description |
|---|---|---|
| type | Number | A ShapeLockType value. The type of the shape locked property. |
Returns: Returns the value of locked property.
setLockedProperty(type, value)
Set the locked property.
| Parameter | Type | Description |
|---|---|---|
| type | Number | A ShapeLockType value. The locked type. |
| value | boolean | The value of the property. |
addHyperlink(address)
Adds a hyperlink to the shape.
| Parameter | Type | Description |
|---|---|---|
| address | String | Address of the hyperlink. |
Returns: Return the new hyperlink object.
removeHyperlink()
Removes the hyperlink of the shape.
moveToRange(topRow, leftColumn, bottomRow, rightColumn)
Moves the shape to a specified range.
| Parameter | Type | Description |
|---|---|---|
| upperLeftRow | Upper left row index. | |
| upperLeftColumn | Upper left column index. | |
| lowerRightRow | Lower right row index | |
| lowerRightColumn | Lower right column index |
alignTopRightCorner(topRow, rightColumn)
Moves the picture to the top-right corner.
| Parameter | Type | Description |
|---|---|---|
| topRow | Number | the row index. |
| rightColumn | Number | the column index. |