• Open Menu Close Menu
  • Apple
  • Shopping Bag
  • Apple
  • Mac
  • iPad
  • iPhone
  • Watch
  • TV
  • Music
  • Support
  • Search apple.com
  • Shopping Bag

Lists

Open Menu Close Menu
  • Terms and Conditions
  • Lists hosted on this site
  • Email the Postmaster
  • Tips for posting to public mailing lists
Re: PDFMarkupAnnotations!?
[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index]

Re: PDFMarkupAnnotations!?


  • Subject: Re: PDFMarkupAnnotations!?
  • From: John Calhoun <email@hidden>
  • Date: Mon, 18 Dec 2006 11:15:37 -0800

On Dec 14, 2006, at 6:54 AM, Alexander Griekspoor wrote:
setQuadrilateralPoints:
Sets the array of quadrilateral points defining the bounds of the markup.


- (void)setQuadrilateralPoints:(NSArray *)points

Discussion
The points defined by each quadrilateral array should encompass a word or a contiguous group of words. The quadrilateral points are ordered counterclockwise, with the first point closest to the origin in page space.


Page space is a 72 dpi coordinate system with the origin at the lower-left corner of the current page.


Besides the terminology, what the f*? How can I make an NSArray of points? Certainly not NSPoints, these are not objects?!


You do need an array of NSPoints.  To get them as objects, call:

[NSValue valueWithPoint: NSMakePoint(x, y)];


But in fact, as a convenience, -[PDFAnnotationMarkup initWithBounds:] will create these points for you based on the bounds passed in so you shouldn't need to call -[setQuadrilateralPoints:].


You also, as a convenience, get a color (yellow I think) with just the init call.

Is it possible you are not redisplaying the page? That is, calling - [PDFView setNeedsDisplay: YES]?

If so, what is the page bounds, what bounds are you using for the annotation?

john calhoun—_______________________________________________

Cocoa-dev mailing list (email@hidden)

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


References: 
 >PDFMarkupAnnotations!? (From: Alexander Griekspoor <email@hidden>)

  • Prev by Date: Re: Using bindings to make an NSPopupButton to assign an array filter predicate
  • Next by Date: Re: PDFKit: PDF version and page labels
  • Previous by thread: PDFMarkupAnnotations!?
  • Next by thread: copying from app bundle
  • Index(es):
    • Date
    • Thread