• 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
Refresh problem with right aligned rectangle while resizing anNSOutlineView
[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index]

Refresh problem with right aligned rectangle while resizing anNSOutlineView


  • Subject: Refresh problem with right aligned rectangle while resizing anNSOutlineView
  • From: malcom <email@hidden>
  • Date: Wed, 28 Nov 2007 20:53:30 +0100

Hello guys,
I would to place a simple round rectangle (as Mail.app unread badge) at the
right side of an NSOutlineView.
So this is the code I've used to get an NSBezierPath to draw (
http://developer.apple.com/samplecode/Reducer/listing21.html)
while this is the portions of code inside drawInRect event that draw it.

NSBezierPath *roundRect = [NSBezierPath bezierPathWithRoundedRect:
NSMakeRect(NSWidth(cellFrame)-20,inset.origin.y,20,20) cornerRadius: 4.0];
[controlView lockFocus];
[roundRect stroke];
[roundRect fill];
[controlView unlockFocus];

All works fine but when I try to resize the outlinew view the old rectangle
position still visible with the new one
(look here: http://img66.imageshack.us/img66/7857/picture4cf2.png)
the problem does not append if i try to put an NSImage using
compositeToPoint...
Why? Where the code is wrong?
Thanks
_______________________________________________

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

  • Prev by Date: Re: Adding HUD context pannel to rows within NSOutlineView
  • Next by Date: Sheet Doesn't Attach Itself To Window
  • Previous by thread: Getting modified object in observeValueForKeyPath:ofObject:change:context: for non-simple key paths
  • Next by thread: Re: Refresh problem with right aligned rectangle while resizing anNSOutlineView
  • Index(es):
    • Date
    • Thread