Re: Getting a selection range from a pdfselection...
Re: Getting a selection range from a pdfselection...
- Subject: Re: Getting a selection range from a pdfselection...
- From: Antonio Nunes <email@hidden>
- Date: Thu, 13 Mar 2014 16:57:26 +0000
On 11 Mar 2014, at 17:37, Matthew Weinstein <email@hidden> wrote:
> Trying to figure out how to get a pages selection range (offset and length) for a pdfselection. I've been using the bounding rect, but if I have a selection that is a sentence that crosses lines and terminates half way in the last line, the rect includes everything to the edge (of course). But if I just want the offset and length, how do I extract that?
Matthew, ask the PDFSelection for its “selectionsByLine”. You should get two selections. One for the first line, one for the second. Examine both to exact the data you need.
- António
-----------------------------------------
Perfume is the forgiveness
that the trampled flower casts
upon the heel that crushes it.
-----------------------------------------
_______________________________________________
Cocoa-dev mailing list (email@hidden)
Please do not post admin requests or moderator comments to the list.
Contact the moderators at cocoa-dev-admins(at)lists.apple.com
Help/Unsubscribe/Update your Subscription:
This email sent to email@hidden