Legend
Source: aspose.
Encapsulates the object that represents the chart legend.
Methods
- characters(startIndex, length)
- getArea()
- getAutoScaleFont()
- getBackground()
- getBackgroundMode()
- getBorder()
- getChart()
- getDefaultHeight()
- getDefaultWidth()
- getDefaultX()
- getDefaultY()
- getDirectionType()
- getFont()
- getHeight()
- getLegendEntries()
- getLegendEntriesLabels()
- getLegendLabels()
- getLinkedSource()
- getPosition()
- getReadingOrder()
- getRotationAngle()
- getShadow()
- getShapeProperties()
- getText()
- getTextDirection()
- getTextFont()
- getTextHorizontalAlignment()
- getTextOptions()
- getTextVerticalAlignment()
- getWidth()
- getX()
- getY()
- isAutoText()
- isAutomaticRotation()
- isAutomaticSize()
- isDefaultPosBeSet()
- isDeleted()
- isInnerMode()
- isOverLay()
- isResizeShapeToFitText()
- isTextWrapped()
- setAutoScaleFont()
- setAutoText()
- setAutomaticSize()
- setBackground()
- setBackgroundMode()
- setDeleted()
- setDirectionType()
- setHeight()
- setInnerMode()
- setLinkedSource()
- setOverLay()
- setPosition()
- setPositionAuto()
- setReadingOrder()
- setResizeShapeToFitText()
- setRotationAngle()
- setShadow()
- setText()
- setTextDirection()
- setTextHorizontalAlignment()
- setTextVerticalAlignment()
- setTextWrapped()
- setWidth()
- setX()
- setY()
Methods
characters(startIndex, length) → FontSetting
Returns a Characters object that represents a range of characters within the text.
Parameters
Name | Type | Optional | Description |
---|---|---|---|
startIndex |
Number |
|
The index of the start of the character. |
length |
Number |
|
The number of characters. |
- Returns
-
FontSetting
Characters object.
getArea()
Gets the area.
getAutoScaleFont()
True if the text in the object changes font size when the object size changes. The default value is True.
getBackground()
Gets and sets the display mode of the background The value of the property is BackgroundMode integer constant.NOTE: This member is now obsolete. Instead, please use ChartFrame.BackgroundMode property. This property will be removed 12 months later since JANUARY 2012. Aspose apologizes for any inconvenience you may have experienced.
getBackgroundMode()
Gets and sets the display mode of the background The value of the property is BackgroundMode integer constant.
getBorder()
Gets the Line.
getChart()
Gets the chart to which this object belongs.
getDefaultHeight()
Represents height of default position
getDefaultWidth()
Represents width of default position
getDefaultX()
Represents x of default position
getDefaultY()
Represents y of default position
getDirectionType()
Gets and sets the direction of text. The value of the property is ChartTextDirectionType integer constant.
getFont()
Gets a Font object of the specified ChartFrame object.
getHeight()
Gets or sets the height of frame in units of 1/4000 of the chart area. How to convert units of 1/4000 to pixels? Height In Pixels = Y * Chart.ChartObject.Height / 4000;
getLegendEntries()
Gets a collection of all the LegendEntry objects in the specified chart legend. Setting the legend entries of the surface chart is not supported. So it will return null if the chart type is surface chart type.
getLegendEntriesLabels()
Gets the labels of the legend entries after call Chart.Calculate() method. NOTE: This member is now obsolete. Instead, please use Legend.GetLegendLabels method. This property will be removed 12 months later since November 2023. Aspose apologizes for any inconvenience you may have experienced.
getLegendLabels()
Gets the labels of the legend entries after call Chart.Calculate() method.
getLinkedSource()
Gets and sets a reference to the worksheet.
getPosition()
Gets or sets the legend position type. The value of the property is LegendPositionType integer constant.Default position is right.If the legend is at left or right side of the chart, setting Legend.X property will not take effect.If the legend is at top or bottom side of the chart, setting Legend.Y property will not take effect.
getReadingOrder()
Represents text reading order. The value of the property is TextDirectionType integer constant.
getRotationAngle()
Represents text rotation angle. 0: Not rotated.255: Top to Bottom.-90: Downward.90: Upward.
getShadow()
True if the frame has a shadow.
getShapeProperties()
Gets the ShapeProperties object.
getText()
Gets or sets the text of a frame's title.
getTextDirection()
Represents text reading order. The value of the property is TextDirectionType integer constant.NOTE: This member is now obsolete. Instead, please use ChartTextFrame.ReadingOrder property. This property will be removed 12 months later since March 2020. Aspose apologizes for any inconvenience you may have experienced.
getTextFont()
Gets a Font object of the specified ChartFrame object. NOTE: This member is now obsolete. Instead, please use ChartFrame.Font property. This property will be removed 12 months later since JANUARY 2012. Aspose apologizes for any inconvenience you may have experienced.
getTextHorizontalAlignment()
Gets and sets the text horizontal alignment. The value of the property is TextAlignmentType integer constant.
getTextOptions()
Gets and sets the options of the text.
getTextVerticalAlignment()
Gets or sets the text vertical alignment of text. The value of the property is TextAlignmentType integer constant.
getWidth()
Gets or sets the width of frame in units of 1/4000 of the chart area. How to convert units of 1/4000 to pixels? Width In Pixels = Width * Chart.ChartObject.Height / 4000;
getX()
Gets or sets the x coordinate of the upper left corner in units of 1/4000 of the chart area. How to convert units of 1/4000 to pixels? X In Pixels = X * Chart.ChartObject.Width / 4000;
getY()
Gets or sets the y coordinate of the upper left corner in units of 1/4000 of the chart area. How to convert units of 1/4000 to pixels? Y In Pixels = Y * Chart.ChartObject.Height / 4000;
isAutoText()
Indicates the text is auto generated.
isAutomaticRotation()
Indicates whether the text of the chart is automatically rotated.
isAutomaticSize()
Indicates whether the chart frame is automatic sized.
isDefaultPosBeSet()
Indicates whether default position(DefaultX, DefaultY, DefaultWidth and DefaultHeight) are set.
isDeleted()
Indicates whether this data labels is deleted.
isInnerMode()
Indicates whether the size of the plot area size includes the tick marks, and the axis labels. False specifies that the size shall determine the size of the plot area, the tick marks, and the axis labels. Only for Xlsx file.
isOverLay()
Gets or sets whether showing the legend without overlapping the chart.
isResizeShapeToFitText()
Gets or sets whether a shape should be auto-fit to fully contain the text described within it. Auto-fitting is when text within a shape is scaled in order to contain all the text inside.
isTextWrapped()
Gets or sets a value indicating whether the text is wrapped.
setAutoScaleFont()
True if the text in the object changes font size when the object size changes. The default value is True.
setAutoText()
Indicates the text is auto generated.
setAutomaticSize()
Indicates whether the chart frame is automatic sized.
setBackground()
Gets and sets the display mode of the background The value of the property is BackgroundMode integer constant.NOTE: This member is now obsolete. Instead, please use ChartFrame.BackgroundMode property. This property will be removed 12 months later since JANUARY 2012. Aspose apologizes for any inconvenience you may have experienced.
setBackgroundMode()
Gets and sets the display mode of the background The value of the property is BackgroundMode integer constant.
setDeleted()
Indicates whether this data labels is deleted.
setDirectionType()
Gets and sets the direction of text. The value of the property is ChartTextDirectionType integer constant.
setHeight()
Gets or sets the height of frame in units of 1/4000 of the chart area. How to convert units of 1/4000 to pixels? Height In Pixels = Y * Chart.ChartObject.Height / 4000;
setInnerMode()
Indicates whether the size of the plot area size includes the tick marks, and the axis labels. False specifies that the size shall determine the size of the plot area, the tick marks, and the axis labels. Only for Xlsx file.
setLinkedSource()
Gets and sets a reference to the worksheet.
setOverLay()
Gets or sets whether showing the legend without overlapping the chart.
setPosition()
Gets or sets the legend position type. The value of the property is LegendPositionType integer constant.Default position is right.If the legend is at left or right side of the chart, setting Legend.X property will not take effect.If the legend is at top or bottom side of the chart, setting Legend.Y property will not take effect.
setPositionAuto()
Set position of the frame to automatic
setReadingOrder()
Represents text reading order. The value of the property is TextDirectionType integer constant.
setResizeShapeToFitText()
Gets or sets whether a shape should be auto-fit to fully contain the text described within it. Auto-fitting is when text within a shape is scaled in order to contain all the text inside.
setRotationAngle()
Represents text rotation angle. 0: Not rotated.255: Top to Bottom.-90: Downward.90: Upward.
setShadow()
True if the frame has a shadow.
setText()
Gets or sets the text of a frame's title.
setTextDirection()
Represents text reading order. The value of the property is TextDirectionType integer constant.NOTE: This member is now obsolete. Instead, please use ChartTextFrame.ReadingOrder property. This property will be removed 12 months later since March 2020. Aspose apologizes for any inconvenience you may have experienced.
setTextHorizontalAlignment()
Gets and sets the text horizontal alignment. The value of the property is TextAlignmentType integer constant.
setTextVerticalAlignment()
Gets or sets the text vertical alignment of text. The value of the property is TextAlignmentType integer constant.
setTextWrapped()
Gets or sets a value indicating whether the text is wrapped.
setWidth()
Gets or sets the width of frame in units of 1/4000 of the chart area. How to convert units of 1/4000 to pixels? Width In Pixels = Width * Chart.ChartObject.Height / 4000;
setX()
Gets or sets the x coordinate of the upper left corner in units of 1/4000 of the chart area. How to convert units of 1/4000 to pixels? X In Pixels = X * Chart.ChartObject.Width / 4000;
setY()
Gets or sets the y coordinate of the upper left corner in units of 1/4000 of the chart area. How to convert units of 1/4000 to pixels? Y In Pixels = Y * Chart.ChartObject.Height / 4000;