Legend
Inheritance: java.lang.Object, com.aspose.slides.DomObject
All Implemented Interfaces: com.aspose.slides.ILegend
public class Legend extends DomObject<Chart> implements ILegend
Represents chart’s legend properties.
Methods
Method | Description |
---|---|
getX() | Returns or sets the x coordinate of a legend as a fraction of the width of the chart. |
setX(float value) | Returns or sets the x coordinate of a legend as a fraction of the width of the chart. |
getY() | Returns or sets the y coordinate of a legend as a fraction of the height of the chart. |
setY(float value) | Returns or sets the y coordinate of a legend as a fraction of the height of the chart. |
getWidth() | Returns or sets the width of a legend as a fraction of the width of the chart. |
setWidth(float value) | Returns or sets the width of a legend as a fraction of the width of the chart. |
getHeight() | Returns or sets the height of a legend as a fraction of the height of the chart. |
setHeight(float value) | Returns or sets the height of a legend as a fraction of the height of the chart. |
getRight() | Right. |
getBottom() | Bottom. |
getOverlay() | Determines whether other chart elements shall be allowed to overlap legend. |
setOverlay(boolean value) | Determines whether other chart elements shall be allowed to overlap legend. |
getTextFormat() | Text format. |
getPosition() | Specifies the position of the legend on a chart. |
setPosition(int value) | Specifies the position of the legend on a chart. |
getFormat() | Returns the format of a legend. |
getChart() | Returns the chart. |
getEntries() | Gets legend entries. |
getActualX() | Specifies actual x location (left) of the chart element relative to the left top corner of the chart. |
getActualY() | Specifies actual top of the chart element relative to the left top corner of the chart. |
getActualWidth() | Specifies actual width of the chart element. |
getActualHeight() | Specifies actual height of the chart element. |
getSlide() | Returns the parent slide of a FillFormat. |
getPresentation() | Returns the parent presentation of a FillFormat. |
getX()
public final float getX()
Returns or sets the x coordinate of a legend as a fraction of the width of the chart. Read/write float.
Returns: float
setX(float value)
public final void setX(float value)
Returns or sets the x coordinate of a legend as a fraction of the width of the chart. Read/write float.
Parameters:
Parameter | Type | Description |
---|---|---|
value | float |
getY()
public final float getY()
Returns or sets the y coordinate of a legend as a fraction of the height of the chart. Read/write float.
Returns: float
setY(float value)
public final void setY(float value)
Returns or sets the y coordinate of a legend as a fraction of the height of the chart. Read/write float.
Parameters:
Parameter | Type | Description |
---|---|---|
value | float |
getWidth()
public final float getWidth()
Returns or sets the width of a legend as a fraction of the width of the chart. Read/write float.
Returns: float
setWidth(float value)
public final void setWidth(float value)
Returns or sets the width of a legend as a fraction of the width of the chart. Read/write float.
Parameters:
Parameter | Type | Description |
---|---|---|
value | float |
getHeight()
public final float getHeight()
Returns or sets the height of a legend as a fraction of the height of the chart. Read/write float.
Returns: float
setHeight(float value)
public final void setHeight(float value)
Returns or sets the height of a legend as a fraction of the height of the chart. Read/write float.
Parameters:
Parameter | Type | Description |
---|---|---|
value | float |
getRight()
public final float getRight()
Right. Read-only float.
Returns: float
getBottom()
public final float getBottom()
Bottom. Read-only float.
Returns: float
getOverlay()
public final boolean getOverlay()
Determines whether other chart elements shall be allowed to overlap legend. Read/write boolean.
Returns: boolean
setOverlay(boolean value)
public final void setOverlay(boolean value)
Determines whether other chart elements shall be allowed to overlap legend. Read/write boolean.
Parameters:
Parameter | Type | Description |
---|---|---|
value | boolean |
getTextFormat()
public final IChartTextFormat getTextFormat()
Text format. Read-only IChartTextFormat.
Returns: IChartTextFormat
getPosition()
public final int getPosition()
Specifies the position of the legend on a chart. Non-NaN values of X, Y, Width, Height properties override effect of this property. Read/write LegendPositionType.
Returns: int
setPosition(int value)
public final void setPosition(int value)
Specifies the position of the legend on a chart. Non-NaN values of X, Y, Width, Height properties override effect of this property. Read/write LegendPositionType.
Parameters:
Parameter | Type | Description |
---|---|---|
value | int |
getFormat()
public final IFormat getFormat()
Returns the format of a legend. Read-only IFormat.
Returns: IFormat
getChart()
public final IChart getChart()
Returns the chart. Read-only IChart.
Returns: IChart
getEntries()
public final ILegendEntryCollection getEntries()
Gets legend entries. Read-only ILegendEntryCollection.
Returns: ILegendEntryCollection
getActualX()
public final float getActualX()
Specifies actual x location (left) of the chart element relative to the left top corner of the chart. Call method IChart.validateChartLayout() before to get actual values. Read float.
Returns: float
getActualY()
public final float getActualY()
Specifies actual top of the chart element relative to the left top corner of the chart. Call method IChart.validateChartLayout() before to get actual values. Read float.
Returns: float
getActualWidth()
public final float getActualWidth()
Specifies actual width of the chart element. Call method IChart.validateChartLayout() before to get actual values. Read float.
Returns: float
getActualHeight()
public final float getActualHeight()
Specifies actual height of the chart element. Call method IChart.validateChartLayout() before to get actual values. Read float.
Returns: float
getSlide()
public final IBaseSlide getSlide()
Returns the parent slide of a FillFormat. Read-only BaseSlide.
Returns: IBaseSlide
getPresentation()
public final IPresentation getPresentation()
Returns the parent presentation of a FillFormat. Read-only IPresentation.
Returns: IPresentation