• 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: Basic NSGraphicsContext question
[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index]

Re: Basic NSGraphicsContext question


  • Subject: Re: Basic NSGraphicsContext question
  • From: "Alastair J.Houghton" <email@hidden>
  • Date: Sat, 5 Jul 2003 13:12:06 +0100

On Friday, July 4, 2003, at 11:50 pm, Gerard Iglesias wrote:

On Saturday, July 5, 2003, at 12:22 AM, Alastair J.Houghton wrote:


Try [NSGraphicsContext currentContext] between the lockFocus/unlockFocus.

But why do you need an NSGraphicsContext? You don't normally need to get at the context itself (again, unlike on Win32).

Yes and no, using NSBezierPath to make all drawing is costly, and it is good to be able to make heavy CG function calls for some kinds of drawing...

It's interesting that you say that; from what I've seen of the Core Graphics APIs, it looks like NSBezierPath is just a simple wrapper around them... I wouldn't expect it to be "costly". How much slower is NSBezierPath than the equivalent CG calls?

There are a few reasons I can see that you might need to use Core Graphics APIs (for example, you want to use the CGShading stuff, which doesn't have an AppKit equivalent AFAIK [although if someone does know of one and I'm missing it, please tell me]), but I would have thought that it was generally better to stick to the AppKit in Cocoa programs.

Kind regards,

Alastair.
_______________________________________________
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.

  • Follow-Ups:
    • Re: Basic NSGraphicsContext question
      • From: Gerard Iglesias <email@hidden>
References: 
 >Re: Basic NSGraphicsContext question (From: Gerard Iglesias <email@hidden>)

  • Prev by Date: Re: awakeFromNib and windowWillLoad : basic question
  • Next by Date: Re: Big Binary Files in PB
  • Previous by thread: Re: Basic NSGraphicsContext question
  • Next by thread: Re: Basic NSGraphicsContext question
  • Index(es):
    • Date
    • Thread