• 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: Printable region and drawRect
[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index]

Re: Printable region and drawRect


  • Subject: Re: Printable region and drawRect
  • From: Jonathan Jackel <email@hidden>
  • Date: Tue, 29 Oct 2002 23:19:37 -0500

> I've looked at the NSPrintInfo documentation and it provides methods to
> access the page size, margins, orientation, etc. and that gives me the
> rectangle I need. The problem is still that the drawRect method
> receives a tiny little NSRect in which to draw itself rather than the
> full printable region of the page.
>
> I guess my question is - how can I draw into the printable region
> rectangle rather than the one provided to my view's drawRect method?
> Can I do this legally (i.e. without some bizarre side-effects) by
> drawing outside the given rectangle or is there some other "official"
> way to do this?

It sounds like you should look at NSView's printing and pagination methods,
especially knowsPageRange:, rectForPage:, and locationOfPrintRect:.

Jonathan
_______________________________________________
cocoa-dev mailing list | email@hidden
Help/Unsubscribe/Archives: http://www.lists.apple.com/mailman/listinfo/cocoa-dev
Do not post admin requests to the list. They will be ignored.

References: 
 >Re: Printable region and drawRect (From: Michael Ericson <email@hidden>)

  • Prev by Date: Syntax-coloring NSTextView
  • Next by Date: Using file wrappers
  • Previous by thread: Re: Printable region and drawRect
  • Next by thread: Re: Printable region and drawRect
  • Index(es):
    • Date
    • Thread