pub struct PdfSelection { /* private fields */ }Expand description
Wraps PDFSelection.
Implementations§
Source§impl PdfSelection
impl PdfSelection
Sourcepub fn new(document: &PdfDocument) -> Result<Self>
pub fn new(document: &PdfDocument) -> Result<Self>
Wraps PDFSelection(document:).
Sourcepub fn page_count(&self) -> usize
pub fn page_count(&self) -> usize
Wraps the corresponding PDFSelection API.
Sourcepub fn bounds_for_page(&self, page: &PdfPage) -> PdfRect
pub fn bounds_for_page(&self, page: &PdfPage) -> PdfRect
Wraps the corresponding PDFSelection API.
Sourcepub fn number_of_text_ranges_on_page(&self, page: &PdfPage) -> usize
pub fn number_of_text_ranges_on_page(&self, page: &PdfPage) -> usize
Wraps the corresponding PDFSelection API.
Sourcepub fn text_range(&self, index: usize, page: &PdfPage) -> Option<PdfTextRange>
pub fn text_range(&self, index: usize, page: &PdfPage) -> Option<PdfTextRange>
Wraps the corresponding PDFSelection API.
Sourcepub fn selection_by_line_count(&self) -> usize
pub fn selection_by_line_count(&self) -> usize
Wraps the corresponding PDFSelection API.
Sourcepub fn selection_by_line(&self, index: usize) -> Option<Self>
pub fn selection_by_line(&self, index: usize) -> Option<Self>
Wraps the corresponding PDFSelection API.
Sourcepub fn selections_by_line(&self) -> Vec<Self>
pub fn selections_by_line(&self) -> Vec<Self>
Wraps the corresponding PDFSelection API.
Sourcepub fn add_selection(&self, other: &Self) -> Result<()>
pub fn add_selection(&self, other: &Self) -> Result<()>
Wraps the corresponding PDFSelection API.
Sourcepub fn extend_selection_at_end(&self, amount: isize)
pub fn extend_selection_at_end(&self, amount: isize)
Wraps the corresponding PDFSelection API.
Sourcepub fn extend_selection_at_start(&self, amount: isize)
pub fn extend_selection_at_start(&self, amount: isize)
Wraps the corresponding PDFSelection API.
Sourcepub fn extend_selection_for_line_boundaries(&self)
pub fn extend_selection_for_line_boundaries(&self)
Wraps the corresponding PDFSelection API.
Trait Implementations§
Source§impl Clone for PdfSelection
impl Clone for PdfSelection
Source§fn clone(&self) -> PdfSelection
fn clone(&self) -> PdfSelection
Returns a duplicate of the value. Read more
1.0.0 (const: unstable) · Source§fn clone_from(&mut self, source: &Self)
fn clone_from(&mut self, source: &Self)
Performs copy-assignment from
source. Read moreAuto Trait Implementations§
impl Freeze for PdfSelection
impl RefUnwindSafe for PdfSelection
impl !Send for PdfSelection
impl !Sync for PdfSelection
impl Unpin for PdfSelection
impl UnsafeUnpin for PdfSelection
impl UnwindSafe for PdfSelection
Blanket Implementations§
Source§impl<T> BorrowMut<T> for Twhere
T: ?Sized,
impl<T> BorrowMut<T> for Twhere
T: ?Sized,
Source§fn borrow_mut(&mut self) -> &mut T
fn borrow_mut(&mut self) -> &mut T
Mutably borrows from an owned value. Read more