public class Tile extends Object
The Tile class represents a drawing region in the GroupDocs.Viewer component. It is used to define a specific area or region within a document that needs to be rendered or processed separately. For details, see the documentation.
Example usage:
Tile tile = new Tile(100, 100, 200, 200);
PngViewOptions pngViewOptions = new PngViewOptions();
pngViewOptions.getCadOptions().setTiles(Arrays.asList(tile));
try (Viewer viewer = new Viewer("document.docx")) {
viewer.view(pngViewOptions);
// Use the viewer object for further operations
}
Viewer,
PngViewOptions,
CadOptions| Constructor and Description |
|---|
Tile(int startPointX,
int startPointY,
int width,
int height)
Initializes a new instance of the
Tile class. |
| Modifier and Type | Method and Description |
|---|---|
int |
getEndPointX()
Returns the X coordinate of the highest right point on the drawing where the tile ends.
|
int |
getEndPointY()
Returns the Y coordinate of the highest right point on the drawing where the tile ends.
|
int |
getHeight()
Gets the height of the tile in pixels.
|
int |
getStartPointX()
Gets the X coordinate of the lowest left point on the drawing where the tile begins.
|
int |
getStartPointY()
Gets the Y coordinate of the lowest left point on the drawing where the tile begins.
|
int |
getWidth()
Gets the width of the tile in pixels.
|
public Tile(int startPointX,
int startPointY,
int width,
int height)
Initializes a new instance of the Tile class.
This constructor creates a new tile object with the specified starting point, width, and height. For details, see the documentation.
startPointX - The X coordinate of the lowest left point on the drawing where the tile begins.startPointY - The Y coordinate of the lowest left point on the drawing where the tile begins.width - The width of the tile in pixels.height - The height of the tile in pixels.IllegalArgumentException - when startPointX or startPointY is less than 0IllegalArgumentException - when width or height is less than 1public final int getEndPointX()
Returns the X coordinate of the highest right point on the drawing where the tile ends.
public final int getEndPointY()
Returns the Y coordinate of the highest right point on the drawing where the tile ends.
public final int getHeight()
Gets the height of the tile in pixels.
For details, see the documentation.public final int getStartPointX()
Gets the X coordinate of the lowest left point on the drawing where the tile begins.
For details, see the documentation.public final int getStartPointY()
Gets the Y coordinate of the lowest left point on the drawing where the tile begins.
For details, see the documentation.public final int getWidth()
Gets the width of the tile in pixels.
For details, see the documentation.Copyright © 2024. All rights reserved.