AnchorType:
AnchorType#DONT_MOVE_AND_RESIZE == absolute top-left coordinates and width/height, no cell references
AnchorType#MOVE_DONT_RESIZE == fixed top-left cell reference, absolute width/height
AnchorType#MOVE_AND_RESIZE == fixed top-left and bottom-right cell references, dynamic width/height
| Modifier and Type | Class and Description |
|---|---|
| public static enum |
| Modifier and Type | Method and Description |
|---|---|
| public ClientAnchor. | Returns: the anchor typeGets the anchor type Changed from returning an int to an enum in POI 3.14 beta 1. |
| public short | Returns: 0-based column of the first cell or -1 if none.Returns the column (0 based) of the first cell, or -1 if there is no top-left anchor cell. |
| public short | Returns: 0-based column of the second cell or -1 if none.Returns the column (0 based) of the second cell, or -1 if there is no bottom-right anchor cell. |
| public int | Returns: the x coordinate within the first cellReturns the x coordinate within the first cell. |
| public int | Returns: the x coordinate within the second cellReturns the x coordinate within the second cell
Note - XSSF and HSSF have a slightly different coordinate
system, values in XSSF are larger by a factor of
|
| public int | Returns: the y coordinate within the first cellReturns the y coordinate within the first cell
Note - XSSF and HSSF have a slightly different coordinate
system, values in XSSF are larger by a factor of
|
| public int | Returns: the y coordinate within the second cellSets the y coordinate within the second cell
Note - XSSF and HSSF have a slightly different coordinate
system, values in XSSF are larger by a factor of
|
| public int | Returns: 0-based row of the first cell or -1 if none.Returns the row (0 based) of the first cell, or -1 if there is no bottom-right anchor cell. |
| public int | Returns: 0-based row of the second cell or -1 if none.Returns the row (0 based) of the second cell, or -1 if there is no bottom-right anchor cell. |
| public void | |
| public void | |
| public void | |
| public void | setDx1(int
the x coordinate within the first cell dx1)Sets the x coordinate within the first cell
Note - XSSF and HSSF have a slightly different coordinate
system, values in XSSF are larger by a factor of
|
| public void | setDx2(int
the x coordinate within the second cell dx2)Sets the x coordinate within the second cell
Note - XSSF and HSSF have a slightly different coordinate
system, values in XSSF are larger by a factor of
|
| public void | setDy1(int
the y coordinate within the first cell dy1)Sets the y coordinate within the first cell
Note - XSSF and HSSF have a slightly different coordinate
system, values in XSSF are larger by a factor of
|
| public void | setDy2(int
the y coordinate within the second cell dy2)Sets the y coordinate within the second cell
Note - XSSF and HSSF have a slightly different coordinate
system, values in XSSF are larger by a factor of
|
| public void | |
| public void |
| getAnchorType | back to summary |
|---|---|
| public ClientAnchor. Gets the anchor type Changed from returning an int to an enum in POI 3.14 beta 1.
| |
| getCol1 | back to summary |
|---|---|
| public short getCol1() Returns the column (0 based) of the first cell, or -1 if there is no top-left anchor cell.
This is the case for absolute positioning
| |
| getCol2 | back to summary |
|---|---|
| public short getCol2() Returns the column (0 based) of the second cell, or -1 if there is no bottom-right anchor cell.
This is the case for absolute positioning (
| |
| getDx1 | back to summary |
|---|---|
| public int getDx1() Returns the x coordinate within the first cell.
Note - XSSF and HSSF have a slightly different coordinate
system, values in XSSF are larger by a factor of
| |
| getDx2 | back to summary |
|---|---|
| public int getDx2() Returns the x coordinate within the second cell
Note - XSSF and HSSF have a slightly different coordinate
system, values in XSSF are larger by a factor of
| |
| getDy1 | back to summary |
|---|---|
| public int getDy1() Returns the y coordinate within the first cell
Note - XSSF and HSSF have a slightly different coordinate
system, values in XSSF are larger by a factor of
| |
| getDy2 | back to summary |
|---|---|
| public int getDy2() Sets the y coordinate within the second cell
Note - XSSF and HSSF have a slightly different coordinate
system, values in XSSF are larger by a factor of
| |
| getRow1 | back to summary |
|---|---|
| public int getRow1() Returns the row (0 based) of the first cell, or -1 if there is no bottom-right anchor cell.
This is the case for absolute positioning (
| |
| getRow2 | back to summary |
|---|---|
| public int getRow2() Returns the row (0 based) of the second cell, or -1 if there is no bottom-right anchor cell.
This is the case for absolute positioning (
| |
| setAnchorType | back to summary |
|---|---|
| public void setAnchorType(ClientAnchor. Sets the anchor type
| |
| setCol1 | back to summary |
|---|---|
| public void setCol1(int col1) Sets the column (0 based) of the first cell.
| |
| setCol2 | back to summary |
|---|---|
| public void setCol2(int col2) Returns the column (0 based) of the second cell.
| |
| setDx1 | back to summary |
|---|---|
| public void setDx1(int dx1) Sets the x coordinate within the first cell
Note - XSSF and HSSF have a slightly different coordinate
system, values in XSSF are larger by a factor of
| |
| setDx2 | back to summary |
|---|---|
| public void setDx2(int dx2) Sets the x coordinate within the second cell
Note - XSSF and HSSF have a slightly different coordinate
system, values in XSSF are larger by a factor of
| |
| setDy1 | back to summary |
|---|---|
| public void setDy1(int dy1) Sets the y coordinate within the first cell
Note - XSSF and HSSF have a slightly different coordinate
system, values in XSSF are larger by a factor of
| |
| setDy2 | back to summary |
|---|---|
| public void setDy2(int dy2) Sets the y coordinate within the second cell
Note - XSSF and HSSF have a slightly different coordinate
system, values in XSSF are larger by a factor of
| |
| setRow1 | back to summary |
|---|---|
| public void setRow1(int row1) Returns the row (0 based) of the first cell.
| |
| setRow2 | back to summary |
|---|---|
| public void setRow2(int row2) Returns the row (0 based) of the first cell.
| |
| Modifier and Type | Field and Description |
|---|---|
| public static final ClientAnchor. | DONT_MOVE_AND_RESIZE
Do Not Move or Resize With Underlying Rows/Columns (3) Specifies that the current start and end positions shall be maintained with respect to the distances from the absolute start point of the worksheet. |
| public static final ClientAnchor. | DONT_MOVE_DO_RESIZE
Don't Move but do Resize With Anchor Cells (1) Specifies that the current drawing shall not move with its row and column, but should be resized. |
| public static final ClientAnchor. | MOVE_AND_RESIZE
Move and Resize With Anchor Cells (0) Specifies that the current drawing shall move and resize to maintain its row and column anchors (i.e. the object is anchored to the actual from and to row and column) |
| public static final ClientAnchor. | MOVE_DONT_RESIZE
Move With Cells but Do Not Resize (2) Specifies that the current drawing shall move with its row and column (i.e. the object is anchored to the actual from row and column), but that the size shall remain absolute. |
| public final short |
| Access | Constructor and Description |
|---|---|
| private |
| Modifier and Type | Method and Description |
|---|---|
| public static ClientAnchor. | Returns: the anchor type enumthe anchor type code value)return the AnchorType corresponding to the code |
| public static ClientAnchor. | |
| public static ClientAnchor. |
| DONT_MOVE_AND_RESIZE | back to summary |
|---|---|
| public static final ClientAnchor. Do Not Move or Resize With Underlying Rows/Columns (3) Specifies that the current start and end positions shall be maintained with respect to the distances from the absolute start point of the worksheet. If additional rows/columns are added before the drawing, the drawing shall move its anchors as needed to maintain this same absolute position. | |
| DONT_MOVE_DO_RESIZE | back to summary |
|---|---|
| public static final ClientAnchor. Don't Move but do Resize With Anchor Cells (1) Specifies that the current drawing shall not move with its row and column, but should be resized. This option is not normally used, but is included for completeness. Note: Excel has no setting for this combination, nor does the ECMA standard. | |
| MOVE_AND_RESIZE | back to summary |
|---|---|
| public static final ClientAnchor. Move and Resize With Anchor Cells (0) Specifies that the current drawing shall move and resize to maintain its row and column anchors (i.e. the object is anchored to the actual from and to row and column) | |
| MOVE_DONT_RESIZE | back to summary |
|---|---|
| public static final ClientAnchor. Move With Cells but Do Not Resize (2) Specifies that the current drawing shall move with its row and column (i.e. the object is anchored to the actual from row and column), but that the size shall remain absolute. If additional rows/columns are added between the from and to locations of the drawing, the drawing shall move its to anchors as needed to maintain this same absolute size. | |
| value | back to summary |
|---|---|
| public final short value | |
| AnchorType | back to summary |
|---|---|
| private AnchorType(int value) | |
| byId | back to summary |
|---|---|
| public static ClientAnchor. return the AnchorType corresponding to the code
| |
| valueOf | back to summary |
|---|---|
| public static ClientAnchor. | |
| values | back to summary |
|---|---|
| public static ClientAnchor. | |