• 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
NSCell and partial redraw
[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index]

NSCell and partial redraw


  • Subject: NSCell and partial redraw
  • From: Patrick Mau <email@hidden>
  • Date: Tue, 31 Aug 2010 11:59:36 +0200

Hallo everyone

Let's assume I have a custom NSView that will use to custom NSCell instances to render its contents.
Now, if "drawRect:" is called on the NSView, I get the dirty rect that needs to be redrawn.

The NSCell class on the other hands uses:

- (void)drawWithFrame:(NSRect)cellFrame inView:(NSView *)controlView

Where "cellFrame" is the complete frame the NSCell should use to draw itself into.

Should I intersect the dirty region of the NSView and somehow add additional
functionality to the NSCell to maintain the dirty region?

Or should I ask the "controlView" for the region and maintain it there?

How do people implement NSCell subclasses when the goal is to minimize
the redraw code needed when the cell is drawn?

Thanks a lot
Patrick
_______________________________________________

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

  • Follow-Ups:
    • Re: NSCell and partial redraw
      • From: Fritz Anderson <email@hidden>
  • Prev by Date: Re: Need specialized keyboard for iPad app
  • Next by Date: Re: Binding an objects "Enabled" to a button in IB
  • Previous by thread: Re: Need specialized keyboard for iPad app
  • Next by thread: Re: NSCell and partial redraw
  • Index(es):
    • Date
    • Thread