Graph

Inheritance: java.lang.Object, com.aspose.pdf.BaseParagraph com.aspose.pdf.drawing.Graph, com.aspose.pdf.BaseParagraph, com.aspose.pdf.drawing.Graph

All Implemented Interfaces: com.aspose.ms.System.ICloneable

public final class Graph extends BaseParagraph

Represents graph - graphics generator paragraph.

Constructors

ConstructorDescription
GraphFor Internal usage only
GraphInitializes a new instance of the {@link Graph} class.
GraphInitializes a new instance of the {@code Graph} class.

Methods

MethodDescription
deepCloneClone the graph.
getBorderGets the border.
getGraphInfoGets a {@code GraphInfo} object that indicates the graph info,such as color, line width,etc.
getHeightGets float value that indicates the graph height. The unit is point. In XML,the default unit is point,but cm and inch are also supported. For example,GraphHeight=“10cm” or GraphHeight=“5inch”.
getLeftGets table left coordinate.
getShapesGets a collection that indicates all shapes in the graph.
getTitleGets string value that indicates the title of the graph.
getTopGets the table top coordinate.
getWidthGets float value that indicates the graph width. The unit is point. In XML,the default unit is point,but cm and inch are also supported. For example,GraphWidth=“10cm” or GraphWidth=“5inch”.
isChangePositionGets change current position after process paragraph.(default true)
setBorderSets the border.
setChangePositionSets change current position after process paragraph.(default true)
setGraphInfoGets or sets a {@code GraphInfo} object that indicates the graph info,such as color, line width,etc.
setHeightSets float value that indicates the graph height. The unit is point. In XML,the default unit is point,but cm and inch are also supported. For example,GraphHeight=“10cm” or GraphHeight=“5inch”.
setLeftSets table left coordinate.
setShapesSets a collection that indicates all shapes in the graph.
setTitleSets string value that indicates the title of the graph.
setTopSets the table top coordinate.
setWidthSets float value that indicates the graph width. The unit is point. In XML,the default unit is point,but cm and inch are also supported. For example,GraphWidth=“10cm” or GraphWidth=“5inch”.

Graph

public Graph()

For Internal usage only

Graph

public Graph(double width, double height)

Initializes a new instance of the {@link Graph} class.

Parameters:

ParameterTypeDescription
widthThe width of the graph.
heightThe height of the graph.

Graph

@Deprecated public Graph(float width, float height)

Initializes a new instance of the {@code Graph} class.

Parameters:

ParameterTypeDescription
widthThe width of the graph.
heightThe height of the graph.

deepClone

public Object deepClone()

Clone the graph.

Returns: The cloned object

getBorder

public BorderInfo getBorder()

Gets the border.

Returns: BorderInfo element

getGraphInfo

public GraphInfo getGraphInfo()

Gets a {@code GraphInfo} object that indicates the graph info,such as color, line width,etc.

Returns: GraphInfo object

getHeight

public double getHeight()

Gets float value that indicates the graph height. The unit is point. In XML,the default unit is point,but cm and inch are also supported. For example,GraphHeight=“10cm” or GraphHeight=“5inch”.

Returns: value that indicates the graph height.

getLeft

public double getLeft()

Gets table left coordinate.

Returns: table left coordinate.

getShapes

public final BoundsCheckableList < Shape > getShapes()

Gets a collection that indicates all shapes in the graph.

Returns: BoundsCheckableList of Shapes.

getTitle

public TextFragment getTitle()

Gets string value that indicates the title of the graph.

Returns: title of the graph.

getTop

public double getTop()

Gets the table top coordinate.

Returns: the table top coordinate.

getWidth

public double getWidth()

Gets float value that indicates the graph width. The unit is point. In XML,the default unit is point,but cm and inch are also supported. For example,GraphWidth=“10cm” or GraphWidth=“5inch”.

Returns: float value that indicates the graph width.

isChangePosition

public boolean isChangePosition()

Gets change current position after process paragraph.(default true)

Returns: boolean value

setBorder

Sets the border.

setChangePosition

public void setChangePosition(boolean value)

Sets change current position after process paragraph.(default true)

Parameters:

ParameterTypeDescription
valueboolean value

setGraphInfo

Gets or sets a {@code GraphInfo} object that indicates the graph info,such as color, line width,etc.

setHeight

public void setHeight(double value)

Sets float value that indicates the graph height. The unit is point. In XML,the default unit is point,but cm and inch are also supported. For example,GraphHeight=“10cm” or GraphHeight=“5inch”.

Parameters:

ParameterTypeDescription
valuethat indicates the graph height.

setLeft

public void setLeft(double value)

Sets table left coordinate.

Parameters:

ParameterTypeDescription
valuetable left coordinate.

setShapes

Sets a collection that indicates all shapes in the graph.

setTitle

Sets string value that indicates the title of the graph.

setTop

public void setTop(double value)

Sets the table top coordinate.

Parameters:

ParameterTypeDescription
valuethe table top coordinate.

setWidth

public void setWidth(double value)

Sets float value that indicates the graph width. The unit is point. In XML,the default unit is point,but cm and inch are also supported. For example,GraphWidth=“10cm” or GraphWidth=“5inch”.

Parameters:

ParameterTypeDescription
valuefloat value that indicates the graph width.