public class TextPosition extends Object implements TextSelection
| Constructor and Description |
|---|
TextPosition(String text,
Shape textShape,
double angle,
AffineTransform pageTransform,
int pageNumber,
List<Point2D[]> pdfQuads2) |
| Modifier and Type | Method and Description |
|---|---|
double |
getAngle()
Returns the angle that this text is displayed at on the page.
|
Shape |
getEnclosingShape()
Deprecated.
This method is redundant. Replaced by get by
getViewSelectionShape(). |
int |
getPageNumber()
Indicates on which page of the document the TextPosition's text is
located.
|
Point2D[] |
getPDFQuadrilateral()
Deprecated.
replaced by
getPDFQuadrilaterals(). |
Vector<Point2D[]> |
getPDFQuadrilaterals()
Returns a list of quadrilaterals that will enclose the text elements in
this object.
|
Shape |
getPDFSelectionShape()
Returns the entire shape that encloses all text in this selection.
|
Point2D[] |
getQuadrilateral()
Deprecated.
replaced by
getViewQuadrilaterals(). |
Vector<Point2D[]> |
getQuadrilaterals()
Deprecated.
replaced with
getViewQuadrilaterals(). |
Shape |
getSelectionShape()
Deprecated.
replaced by
getViewSelectionShape(). |
String |
getText()
Returns the text string.
|
String |
getText(boolean lineBreaks)
Returns a string containing all the selected text.
|
Point2D[] |
getViewQuadrilateral()
Deprecated.
replaced by
getViewQuadrilaterals(). |
Vector<Point2D[]> |
getViewQuadrilaterals()
Returns a list of quadrilaterals that will enclose the text elements in
this object.
|
Shape |
getViewSelectionShape()
Returns the entire shape that encloses all text in this selection.
|
public TextPosition(String text, Shape textShape, double angle, AffineTransform pageTransform, int pageNumber, List<Point2D[]> pdfQuads2)
public int getPageNumber()
public Shape getEnclosingShape()
getViewSelectionShape().public String getText()
getText in interface TextSelectionpublic String getText(boolean lineBreaks)
TextSelectiongetText in interface TextSelectionlineBreaks - If set to true, lines within paragraphs will be split into separate lines. If set to false, lines within paragraphs will be separated with spaces.public Point2D[] getQuadrilateral()
getViewQuadrilaterals().public Point2D[] getViewQuadrilateral()
getViewQuadrilaterals().public Point2D[] getPDFQuadrilateral()
getPDFQuadrilaterals().public double getAngle()
public Vector<Point2D[]> getQuadrilaterals()
getViewQuadrilaterals().getQuadrilaterals in interface TextSelectionpublic Vector<Point2D[]> getViewQuadrilaterals()
getViewQuadrilaterals in interface TextSelectiongetViewSelectionShape().public Vector<Point2D[]> getPDFQuadrilaterals()
getPDFQuadrilaterals in interface TextSelection@Deprecated public Shape getSelectionShape()
getViewSelectionShape().TextSelection interface.getSelectionShape in interface TextSelectionpublic Shape getPDFSelectionShape()
getPDFSelectionShape in interface TextSelectiongetPDFQuadrilaterals()public Shape getViewSelectionShape()
getViewSelectionShape in interface TextSelection