Package com.pspdfkit.datastructures
Class TextSelection
-
- All Implemented Interfaces:
-
android.os.Parcelable
public class TextSelection implements Parcelable
TextSelection represents a selection of text on a document page. This class is not meant to be generated manually, but should be retrieved by calling getTextSelection or by registering a OnTextSelectionModeChangeListener.
-
-
Field Summary
Fields Modifier and Type Field Description public final static Parcelable.Creator<TextSelection>
CREATOR
public final Range
textRange
public final String
text
public final int
pageIndex
public final List<RectF>
textBlocks
-
Method Summary
Modifier and Type Method Description static TextSelection
fromTextRange(@NonNull() PdfDocument document, @IntRange(from = 0) int pageIndex, @NonNull() Range textRange)
Factory method. static TextSelection
fromTextRects(@NonNull() PdfDocument document, @IntRange(from = 0) int pageIndex, @NonNull() TextSelectionRectangles touchedTextRects)
Factory method. int
hashCode()
boolean
equals(Object o)
int
describeContents()
void
writeToParcel(@NonNull() Parcel dest, int flags)
-
-
Method Detail
-
fromTextRange
static TextSelection fromTextRange(@NonNull() PdfDocument document, @IntRange(from = 0) int pageIndex, @NonNull() Range textRange)
Factory method. Not meant to be used manually.
-
fromTextRects
static TextSelection fromTextRects(@NonNull() PdfDocument document, @IntRange(from = 0) int pageIndex, @NonNull() TextSelectionRectangles touchedTextRects)
Factory method. Not meant to be used manually.
-
hashCode
int hashCode()
-
describeContents
int describeContents()
-
writeToParcel
void writeToParcel(@NonNull() Parcel dest, int flags)
-
-
-
-