public class HSSFClientAnchor extends HSSFAnchor
Modifier and Type | Field and Description |
---|---|
(package private) int |
anchorType |
(package private) short |
col1 |
(package private) short |
col2 |
(package private) int |
row1 |
(package private) int |
row2 |
dx1, dx2, dy1, dy2
Constructor and Description |
---|
HSSFClientAnchor()
Creates a new client anchor and defaults all the anchor positions to 0.
|
HSSFClientAnchor(int dx1,
int dy1,
int dx2,
int dy2,
short col1,
int row1,
short col2,
int row2)
Creates a new client anchor and sets the top-left and bottom-right
coordinates of the anchor.
|
Modifier and Type | Method and Description |
---|---|
private void |
checkRange(int value,
int minRange,
int maxRange,
String varName) |
float |
getAnchorHeightInPoints(HSSFSheet sheet)
Calculates the height of a client anchor in points.
|
int |
getAnchorType()
Gets the anchor type
|
short |
getCol1() |
short |
getCol2() |
int |
getRow1() |
int |
getRow2() |
private float |
getRowHeightInPoints(HSSFSheet sheet,
int rowNum) |
boolean |
isHorizontallyFlipped() |
boolean |
isVerticallyFlipped() |
void |
setAnchor(short col1,
int row1,
int x1,
int y1,
short col2,
int row2,
int x2,
int y2)
Dets the top-left and bottom-right
coordinates of the anchor.
|
void |
setAnchorType(int anchorType)
Sets the anchor type
|
void |
setCol1(short col1) |
void |
setCol2(short col2) |
void |
setRow1(int row1) |
void |
setRow2(int row2) |
public HSSFClientAnchor()
public HSSFClientAnchor(int dx1, int dy1, int dx2, int dy2, short col1, int row1, short col2, int row2)
dx1
- the x coordinate within the first cell.dy1
- the y coordinate within the first cell.dx2
- the x coordinate within the second cell.dy2
- the y coordinate within the second cell.col1
- the column (0 based) of the first cell.row1
- the row (0 based) of the first cell.col2
- the column (0 based) of the second cell.row2
- the row (0 based) of the second cell.public float getAnchorHeightInPoints(HSSFSheet sheet)
sheet
- the sheet the anchor will be attached toprivate float getRowHeightInPoints(HSSFSheet sheet, int rowNum)
public short getCol1()
public void setCol1(short col1)
public short getCol2()
public void setCol2(short col2)
public int getRow1()
public void setRow1(int row1)
public int getRow2()
public void setRow2(int row2)
public void setAnchor(short col1, int row1, int x1, int y1, short col2, int row2, int x2, int y2)
x1
- the x coordinate within the first cell.y1
- the y coordinate within the first cell.x2
- the x coordinate within the second cell.y2
- the y coordinate within the second cell.col1
- the column (0 based) of the first cell.row1
- the row (0 based) of the first cell.col2
- the column (0 based) of the second cell.row2
- the row (0 based) of the second cell.public boolean isHorizontallyFlipped()
isHorizontallyFlipped
in class HSSFAnchor
public boolean isVerticallyFlipped()
isVerticallyFlipped
in class HSSFAnchor
public int getAnchorType()
0 = Move and size with Cells, 2 = Move but don't size with cells, 3 = Don't move or size with cells.
public void setAnchorType(int anchorType)
0 = Move and size with Cells, 2 = Move but don't size with cells, 3 = Don't move or size with cells.
private void checkRange(int value, int minRange, int maxRange, String varName)
Copyright © 2015 Open Microscopy Environment